/
View dependency graph
Depends on
- dh-golang (dh-golang)
- golang-defaults (golang-any)
- debhelper-compat
Used by
- amazon-ecr-credential-helper 0.12.0-1
- amfora 1.11.0-1
- bettercap 2.33.0-2
- deck 1.4.0-2
- fever 1.4.0-1
- golang-github-azure-go-autorest 14.2.0+git20220726.711dde1-1
- golang-github-charmbracelet-keygen 0.1.2-2
- golang-github-chrismellard-docker-credential-acr-env 0.7.0-2
- golang-github-containerd-stargz-snapshotter 0.14.3-5
- golang-github-gophercloud-utils 0.0~git20231010.80377ec-2
- golang-github-hashicorp-go-cty-funcs 0.1.0-1
- golang-github-hashicorp-go-discover 0.0+git20190905.34a6505-3
- golang-github-in-toto-go-witness 0.10.0-2
- golang-github-minio-minio-go 6.0.53-1
- golang-github-mitch000001-go-hbci 0.4.0-2
- golang-github-muesli-go-app-paths 0.2.1-2
- golang-github-muesli-sasquatch 0.0~git20210519.30aff9d-2
- golang-github-sigstore-sigstore 1.10.8-1
- golang-github-sigstore-timestamp-authority 2.1.2-1
- golang-gopkg-src-d-go-git.v4 4.11.0-3
Show 10 more
- invidtui 0.4.6-1.1
- micro 2.0.15-2
- mockery 2.15.0-1
- rdap 0.9.1-3.1
- bettercap 2.33.0-4
- golang-github-mitch000001-go-hbci 0.4.0-3
- golang-github-azure-go-autorest 14.2.0+git20220726.711dde1-2
- golang-github-containerd-stargz-snapshotter 0.14.3-6
- golang-github-sigstore-sigstore 1.10.9-1
- golang-github-sigstore-timestamp-authority 2.1.3-2
README (full)
go-homedir
This is a Go library for detecting the user's home directory without the use of cgo, so the library can be used in cross-compilation environments.
Usage is incredibly simple, just call homedir.Dir() to get the home directory
for a user, and homedir.Expand() to expand the ~ in a path to the home
directory.
Why not just use os/user? The built-in os/user package requires
cgo on Darwin systems. This means that any Go code that uses that package
cannot cross compile. But 99% of the time the use for os/user is just to
retrieve the home directory, which we can do for the current user without
cgo. This library does that, enabling cross-compilation.
| dir | debian/ |
| file | LICENSE |
| file | README.md |
| file | go.mod |
| file | homedir.go |
| file | homedir_test.go |