Permalink
Browse files

Allow user to define ~ as an alias for home directory

  • Loading branch information...
1 parent a5c343e commit 9caae2fc78c033483ac91626581a5e8533b7c4b1 @jammycakes committed Feb 3, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 go.ps1
View
4 go.ps1
@@ -49,8 +49,8 @@ function Get-GoTarget($targetName) {
if ($target) {
if (-not $found) {
$found = $TRUE
- if ([System.IO.Path]::IsPathRooted($target) -or $target.StartsWith('http://') -or $target.StartsWith('https://')) {
- return $target
+ if ([System.IO.Path]::IsPathRooted($target) -or $target.StartsWith('http://') -or $target.StartsWith('https://') -or ($target -eq '~')) {
+ return $target
}
else {
return Join-Path (Split-Path -parent $_) $target

0 comments on commit 9caae2f

Please sign in to comment.