Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

set alias in powershell

#For Windows PowerShell
set-alias -name <alias_name> -value <command>
#<alias_name> is the new alias name you want to set.
#<command> is the command you want to alias.
#NB: this is temporal and will not work when powershell is reboot.
#To make it permanent, add it to PowerShell Profile.ps1 file.
Comment

powershell alias

# On your profile.ps1 file
# if you don't have it yet, just run code $PROFILE to create and edit it (with vscode)

function NpmRunDev {  
  npm run dev
}

Set-Alias nrd NpmRunDev
Comment

create alias in powershell permanently

// create a profile.ps1 file to set aliases
notepad $((Split-Path $profile -Parent) + "profile.ps1")

// example aliases (opens notepad when you type `edit` in console)
Set-Alias edit notepad.exe

// example aliases (opens notepad when you type `edit` in console)
Set-Alias edit1 "C:Program FilesWindows NTAccessorieswordpad.exe"
Comment

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.
Comment

powershell alias setting

set-theme [some themes]
Comment

PREVIOUS NEXT
Code Example
Shell :: universal command to get operating system 
Shell :: install terminator ubuntu 
Shell :: linux signals 
Shell :: how to upgrade docker-compose version 
Shell :: how to merge git branch to master 
Shell :: specific branch clone git 
Shell :: git clone the certificate chain was issued by an authority that is not trusted 
Shell :: kubernetes /bin/bash 
Shell :: Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:783 (propagating) 
Shell :: install tmux fedora 
Shell :: set wsl version to 1 
Shell :: test redis connection 
Shell :: grep search text in folder 
Shell :: ubuntu install filebeat 
Shell :: revert all local changes git 
Shell :: install xcode terminal 
Shell :: heroku buildpacks 
Shell :: osx kill process on port 
Shell :: add remote branch git 
Shell :: shell command read first lines 
Shell :: install eclipse in fedora 
Shell :: list all files by size 
Shell :: display group of username mac 
Shell :: ionic capacitor splash screen generator 
Shell :: could not find driver postgres laravel 
Shell :: deleting remote branch in GitHub 
Shell :: docker ftp client 
Shell :: geopandas install windows 
Shell :: restore deleted commits 
Shell :: install entityframeworkcore nuget in asp.net core 3.0 
ADD CONTENT
Topic
Content
Source link
Name
7+6 =