Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use '~' for $HOME in fish_plugins file rather than resolving path #792

Merged
merged 1 commit into from
Sep 10, 2024

Conversation

mattmc3
Copy link
Contributor

@mattmc3 mattmc3 commented Sep 9, 2024

The fish_plugins file isn't portable across machines for local plugins because it stores the path to $HOME, which could be different on a different machine. This PR fixes this.

Steps to reproduce with Fisher 4.4.4:

$ fisher install $__fish_config_dir/plugins/foo
fisher install version 4.4.4
Installing /Users/mattmc3/.config/fish/plugins/foo
           /Users/mattmc3/.config/fish/.fisher/functions/foo.fish
Updated 1 plugin/s
$ cat $__fish_config_dir/fish_plugins
jorgebucaran/fisher
/Users/mattmc3/.config/fish/plugins/foo

This PR for Fisher 4.4.5, which makes fish_plugins more portable across machines with alternative user names:

$ fisher install $__fish_config_dir/plugins/foo
fisher install version 4.4.5
Installing /Users/matt/.config/fish/plugins/foo
           /Users/matt/.config/fish/.fisher/functions/foo.fish
Updated 1 plugin/s
$ cat $__fish_config_dir/fish_plugins
jorgebucaran/fisher
~/.config/fish/plugins/foo

Copy link
Owner

@jorgebucaran jorgebucaran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We missed this when we did the same for universal variables, so I really appreciate it. Thanks!

Copy link
Owner

@jorgebucaran jorgebucaran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one more little thing! 🙏

@jorgebucaran jorgebucaran added the enhancement New feature or bug fix label Sep 10, 2024
@jorgebucaran jorgebucaran merged commit 63c1818 into jorgebucaran:main Sep 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or bug fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants