I'm using GNU stow to manage my dotfiles, on a Mac.
I tried creating a .stow-local-ignore file in the root stow directory, with the contents:
\.DS_Store
But I still get errors:
WARNING! stowing bin would cause conflicts:
* existing target is neither a link nor a directory: .DS_Store
All operations aborted.
How do I configure stow to always ignore all .DS_Store files?
To ignore all .DS_Store files,
you need to add
\.DS_Store
to ~/.stow-global-ignore (under your home directory).
.stow-local-ignore only applies
to specific packages (subfolders) in your root stow directory.
From the docs:
If you put Perl regular expressions, one per line, in a .stow-local-ignore file within any top level package directory, in which case any file or directory within that package matching any of these regular expressions will be ignored.
For example,
say you have two packages,
foo and bar, in your root stow directory.
You run stow foo and stow bar.
root-dir
|-- .stow-local-ignore # STOW ignores this file since it's not associated with any package.
|-- foo
| └-- .stow-local-ignore # STOW uses this file since it's in a package.
└-- bar
Note that .stow-local-ignore overwrites .stow-global-ignore,
so if you use a local ignore file,
make sure to add
\.DS_Store
to it as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With