Update list-workdir.ps1

This commit is contained in:
Markus Fleschutz 2022-12-28 15:16:30 +01:00
parent ac6ec19bfd
commit 1cca88c32b

View File

@ -2,9 +2,10 @@
.SYNOPSIS
Lists the current working directory
.DESCRIPTION
This PowerShell script lists the current working directory (but not the content itself!)
This PowerShell script lists the path to current working directory (but not the content itself).
.EXAMPLE
PS> ./list-workdir
📂C:\Users\Markus\source\repos\PowerShell\Scripts
.LINK
https://github.com/fleschutz/PowerShell
.NOTES
@ -12,8 +13,8 @@
#>
try {
$CWD = Resolve-Path "$PWD"
"📂$CWD"
$Path = Resolve-Path "$PWD"
"📂$Path"
exit 0 # success
} catch {
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"