Skip to content

Add su command#50

Open
PRO-2684 wants to merge 3 commits intolukesampson:masterfrom
PRO-2684:master
Open

Add su command#50
PRO-2684 wants to merge 3 commits intolukesampson:masterfrom
PRO-2684:master

Conversation

@PRO-2684
Copy link

@PRO-2684 PRO-2684 commented Jan 13, 2024

This implementation of su simply runs sudo powershell. It would be better if the elevated shell remains consistent with original shell, but I lack necessary knowledge of Powershell programming to implement that.

su.ps1 Outdated
@@ -0,0 +1,3 @@
Set-StrictMode -Off;

sudo powershell
Copy link

@ntpeters ntpeters Mar 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@PRO-2684, to use the current PowerShell flavor:

sudo $(Get-Process -Id $PID).ProcessName

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments