Score:0

no such file or directory when setting up alias

cn flag
Kay

I am following a guide to setup dotfiles - https://www.paultman.com/git-for-dotfile-configs/

There is a command to set an alias for git and target it using a git dir. However when running this command i get the following error:

zsh: no such file or directory: alias dotfiles=/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME

I can confirm both dir do exists. What am i doing wrong?

enter image description here

Arnaud Valmary avatar
my flag
If you made a copy-paste from https://www.paultman.com/git-for-dotfile-configs/, warning to unvisible and non-breaking spaces. Unvisible for your in your navigator AND in your terminal, but very different for zsh or bash. Try `echo "alias config='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME'" | cat -vet` to see them.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.