-
Notifications
You must be signed in to change notification settings - Fork 471
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
chezmoi add mishandles cases where entry or parent is external #1574
Comments
@twpayne I would like to point out something here: In issue #2006 I had chezmoi: mkdir /home/ds/.local/share/chezmoi/dot_config/direnv: no such file or directory But here in this case, chezmoi: stat /home/ds/.local/share/chezmoi/https:/github.com/ohmyzsh/ohmyzsh/archive/master.tar.gz: no such file or directory I tried few test and it seems that workaround only works if |
When this issue is fixed, we should also update the docs to include Felipe's neat trick in this comment. |
See twpayne/chezmoi#2006 and twpayne/chezmoi#1574. Basically, a workaround is required if using chezmoi on a directory otherwise managed by a chezmoi external.
This also applies to files. See #3559 (comment). |
Adding the workaround reference here, as this issue seems more prominent. Mentioned in #2006 (comment)
In addition to this you'll need to make your externals [".oh-my-zsh"]
type = "archive"
url = "https://github.com/ohmyzsh/ohmyzsh/archive/master.tar.gz"
exact = false
stripComponents = 1 |
Describe the bug
As reported by @dhruvinsh in #1205,
chezmoi add
fails if the path is in a directory implicitly created by an external.To reproduce
Expected behavior
chezmoi add
adds the file.The text was updated successfully, but these errors were encountered: