GNU Stow: How to stow only selected files/folders

stow

Let's assume the following structure of a folder called scripts.

├── scripts
│   └── .scripts
│       ├── script1
│       ├── script2
│       └── script3
│   └── .config
│       ├── script4
│       ├── script5
│       └── script6

When using stow scripts, both folders within scripts will be symlinked to ~/.scripts and ~/.config.

Can I use stow to only symlink .scripts without having to remove .config from the folder but just basically ignoring it?

Best Answer

stow has ignore lists which let you put a file called .stow-local-ignore at the top of your source tree. In that, you could put \.scripts to have stow ignore that directory and not link it into the target tree.