-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace go-homedir with stdlib calls
The purpose of github.com/mitchellh/go-homedir was to expand the user home directory without CGO. Recent versions of `os/user` can retrieve the user home directory without CGO and thus enable cross-compilation. This change does not add the missing functionality of expanding non-current-user home directories in a path (e.g. `~user2/dir/subdir`). The reason for this is that the input of `pathOrContents` could be a blob and parsing every byte slice matching `^~.*\/.*` as a path considerably increases the chances that a binary blob is mistakenly parsed as a path.
- Loading branch information
1 parent
f67ecca
commit 3d15577
Showing
3 changed files
with
9 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters