How to Load Secret Environment Variables in Fish Shell

Often you want to load environment variables that are secrets, and you don’t want them in your shell history. Such as your GitHub Access Token or API Token when making requests with curl. One easy solution is to load environment variables from a file, say an .env file. Now, since I am using fish shell, loading env variables from a file like we do in bash and zsh won’t work, i. ...

 2024-02-28 281 words 2 min

How Can You Export Your Atuin History to Fish History?

I have made an post in the past about how you can set up Atuin to sync share history across multiple devices. Whilst this works great and does the job, fish shell doesn’t have the same history that Atuin does. Sometimes we want to have better suggestions in Fish. For example, when you start to type fish shell will suggest the last command in your history that best matches what you are typing (see example below). ...

TIL: How to Use fzf.fish History Search

TIL: How to Use fzf.fish History Search I use Fish Shell with fzf and fish fzf plugin. I installed fzf using nix and home-manager: { programs.fzf = { enable = true; enableFishIntegration = false; }; } It adds fzf-history-widget script, which is bound to ctrl+r, shell reverse history search. Which we can see when we run this: bind | grep -e fzf-history-widget -e fzf-file-widget Whereas I wanted to use the _fzf_search_history which is made available by that fish fzf plugin. ...

TIL: How to Add Vim Navigation FZF

TIL: How to Add Vim Navigation FZF FZF is an amazing fuzzy finder tool, that is super flexible and you can create some cool cli one-liners with it. For example, I use it with the fish shell plugin to search through my command history (CTRL + R). In this post, I will show you how vim style navigation to the FZF pop-up preview. All we need to do is add the following to the relevant file i. ...

 2023-05-30 101 words 1 min

TIL: How to change the fish greeter

TIL: How to change the fish greeter In this post I will show you how you can change your fish shell greeter from the default Welcome to fish, the friendly interactive shell Type `help` for instructions on how to use fish To something custom, this will run every time you open a new shell! To do this, go to your fish_greeter.fish file which can usually be found at ~/.config/fish/functions/fish_greeting.fish. Where mine looks like: ...

My Development Workflow With Alacritty Fish Tmux Nvim

Workflows Change This post is accurate as of date of publish. But likely will go stale, if I update my workflows I will likely publish another post. In this blog post, I will go over my current development workflow using the above tools namely, fish shell tmux and neovim. I’ll be using the dotfiles found here. I aim to move away from using my mouse as much as possible as it just slows me down when my hands are away from my keyboard. ...