Reputation: 208
I'm trying to upload to github from a program that has svn commit commands. This is possible through github's official subversion bridge to translate svn commands to git.
The peculiarity with the program is that in order to not commit everything in a single folder, it will first attempt to commit an empty folder, and then selectively fill it with the necessary files.
The error happens when this newly created empty folder is checked in - git doesn't support empty directories.
Committing everything in a folder would eliminate the problem and the upload would be successful, but some files are machine specific, so that would not be a good solution.
Additionally, we do not have access to the source code of this program to modify the first step of trying to add an empty directory.
On a linux machine, I could install git-svn and use the --preserve-empty-dirs flag. However, I am on a windows machine and I can't seem to do anything like that with git bash.
Is there any way to perhaps change any configurations of github's subversion bridge? (We are using github enterprise, which does have the subversion bridge)
Upvotes: 0
Views: 124
Reputation: 18833
The common convention for checking an empty directory in to Git is to add an empty .keep
file to it, which you can remove once you add a real file.
Upvotes: 0