oh-my-fish: fatal: Not a git repository (or any parent up to mount point /)
I just installed (and re-installed just in case) OMF and I am getting these error message every time I start fish or enter any commands:
; exec fish
Welcome to fish, the friendly interactive shell
Type help for instructions on how to use fish
fatal: Not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
fatal: Not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
⋊> ~ on ls / 09:46:28
1 boot/ etc/ lib@ media/ opt/ root/ sbin@ srv/ tmp/ var/
bin@ dev/ home/ lib64@ mnt/ proc/ run/ some/ sys/ usr/
fatal: Not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
fatal: Not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
If I enter a directory hosting a git repo, I do get the correct prompt and the error message disappears.
No themes selected, no tweaking of fish, and setting GIT_DISCOVERY_ACROSS_FILESYSTEM only makes that line vanish:
⋊> ~ on export GIT_DISCOVERY_ACROSS_FILESYSTEM=yes 09:50:04
fatal: Not a git repository (or any of the parent directories): .git
fatal: Not a git repository (or any of the parent directories): .git
About this issue
- Original URL
- State: open
- Created 7 years ago
- Comments: 35 (8 by maintainers)
Commits related to this issue
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/theme-sushi by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/omf-plugin-autojump by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/theme-dmorrell by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/plugin-fonts by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/omf-plugin-fzf-autojump by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/theme-gentoo by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/theme-harleen by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/fish-theme-lavender by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/lolfish by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/plugin-mix by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/omf-theme-one by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/theme-PastFish by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/randomrussel by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/sashimi by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/omf-theme-slavic-cat by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/tmux-zen by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/touchrunner by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/theme-tweetjay by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/vish by scorphus 3 years ago
- Replace disabled stderr redirection char ^ with 2> Since [Fish 3.3.0][1], redirection to standard error with the `^` character has been disabled by default. Ref [oh-my-fish/oh-my-fish#585][2] [1]: ... — committed to scorphus/fish-shell-1 by scorphus 3 years ago
I suddenly got this when upgrading to fish, version 3.3.0 updation omf didn’t work Thanks
In my case the fix was to remove manually omf, and reinstall.
I think i had a very very old version, and both the
updateand thedestroycommands were failing.I got the same issue and found it was related to Redirection to standard error with the ^ character I had a method in
fish_prompt.fishwhich is using^to redirect stderr.Changed
^to2>solved my problem.For folks still looking for a solution: as per https://github.com/fish-shell/fish-shell/issues/8105#issuecomment-873448774, the shortcut to redirect to
stderrno longer works (was deprecated a while back). So replacing^with2>should work in some cases. I’m using Nai and it has worked there.This helped me ^
Downgrading from Fish 3.3.1 to 3.2.2 via Homebrew did the trick for me of solving
fatal: Not a git repository (or any of the parent directories): .gitwhen dealing with themes (sushiin my case).As reference, I did it like…
I rather have it named
...@3.2.2to distinguish it from official formulae’s latest.Same problem here, after updating to fish 3.3.0. I was using the
Acidhubprompt and theTomorrow Night Brighttheme. Changing the prompt back to default and from there back to Acidhub fixed it for me.Same issue for me:
Welcome to fish, the friendly interactive shell fatal: Not a git repository (or any of the parent directories): .git fatal: Not a git repository (or any of the parent directories): .git
It makes oh-my-fish unusable at the moment.
I had the same issue. Tried all what’s mentioned in this thread with no luck.
Finally, I found the reason: I had some cache files in
~/.cache/omf. I removed them and the error disappeared.Hope this helps someone
Same issue here with fish version 3.3.0. See https://github.com/fish-shell/fish-shell/issues/5497 on how to downgrade fish (with https://github.com/Homebrew/homebrew-core/commit/fd94b1e4582a9ae9d1466122e3d837ae9c18739d as commit for 3.2.2_1).
Had the same problem with my own theme Zen, since upgrading fish to 3.3.0 and had to add a check if the current folder is a git folder to fix it.
@a-p-o thank you for running that.
I suppose the removal of the
.gitdirectory is sufficient..gitis treated as a special directory in regards togit, regardless of if you usedgit initto create it. I don’t know the specifics but that will definitely create conflicts with most other software if you have$HOME/.git.If you want to store custom Git configurations then I recommend you put it in a directory like
$HOME/.config/gitor something similar. Note the removal of the.in.git.I had a
.git/directory (but not git repository) in my home directory..git/contained some git configuration. I moved the configuration and removed the.git/directory and this removed the error message. Hope this helps!I’m seeing this on a brand new install of omf as well. Any idea what I could do to track down the cause of this error?