Search code examples
gitcygwintortoisegit

Adding files recursively using TortoiseGit


I have a folder with files in my woring directory, not yet under version control. If I right click on the folder and go to TortoiseGit -> Add I get the message:

There is nothing to add. All the files and folders are either under version control, have been ignored or the global ignore configuration setting.

When I go into the folder and select the individual files I can add them. And if I start a command line and use git add --all it does what I want TortoiseGit to do and adds recursively.

According to the TortoiseGit Manual it should be able to do this:

Many Adds: You can also use the Add command on folders. In that case, the add dialog will show you all unversioned files inside that versioned folder. This helps if you have many new files and need to add them all at once.

What am I missing?


Solution

  • Cygwin Git requires a special HACK to be enabled in TortoiseGit in order to enable some workarounds (cf. https://tortoisegit.org/docs/tortoisegit/tgit-dug-settings.html and search for "Cygwin"). With this flag enabled, the issue you are talking about is solved.

    PS: Please note that Cygwin Git is kinda broken on Windows as it doesn't even pass the whole test suite. Therefore it is not fully supported by TortoiseGit. Git for Windows is recommended (cf. https://stackoverflow.com/a/32427897/3906760)