Powershell #
Run multiple commands in one line #
ipconfig /release; ipconfig /renew
Set environment variables #
$env:DEBUG=‘website:*’
$env:MY_VAR=‘just something’
View all environment variables #
get-childitem env:*
Sorted #
get-childitem env:* | sort-object name
Starting with prefix and sorted #
get-childitem env:WIN* | sort-object name
Get specific environment variable #
Get-ChildItem -Path Env:\NODE_OPTIONS
Remove environment variable #
Remove-Item Env:\VAR
Redirect stderr and stdout to separate files #
Test.cmd >stdout.txt 2>stderr.txt