Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

set alias for directory in powershell

#For Windows PowerShell
function <alias_name> {cd "C:Users..."}
#We use `function` and not 
set-alias -name <new_alias> -value <command>
#because cmdlets(cd) don't work in set-alias -value.
#NB: this is temporal and will not work when powershell is rebooted.
#To make it permanent, add it to PowerShell Profile.ps1 file.
Source by www.tutorialspoint.com #
 
PREVIOUS NEXT
Tagged: #set #alias #directory #powershell
ADD COMMENT
Topic
Name
8+2 =