Equivalent to .gitignore file with Subversion

I have to work with Subversion in the current project.

Without a hint, someone added the bin and obj folders to the repository.

Besides deleting them and fixing the deletion, is there an equivalent to the .gitignore file that I can add to the repository to make the culprit in the development team no longer add them again?

I know that I can change my own global ignore pattern, but ideally I would like the entire development team to share this at the project level.

+46
svn
Jul 02 2018-12-12T00:
source share
5 answers

This is accomplished using the svn: ignore property in SVN. This property can be added to the folder. Imagine the following:

  +-- root +-- bin +-- ... 

To ignore the bin folder, you must set the svn: ignore property to the root folder. First go to the root folder and follow these steps on the command line:

 svn propset svn:ignore "bin" . 

Or you can do it through TortoiseSVN on Windows (file-> properties-> Subversion tab). Further reading in the Subversion book .

+21
Jul 02 '12 at 12:20
source share

I just started with Android Studio and I finished editing the svn: ignore property in the GUI. I used the "Edit Properties" properties in the "Subversion" menu and added a whole bunch of ignore that were mentioned in other posts.

enter image description here

Below, I ignored it, and Android Studio marked them visually with a different color after I edited the property.

 # built application files *.apk *.ap_ # files for the dex VM *.dex # Java class files *.class # generated files bin gen gradle # Local configuration file (sdk path, etc) local.properties # Eclipse project files .classpath .project # Android Studio .idea .gradle local.properties out build production *.iml *.iws *.ipr *~ *.swp 
+10
Dec 31 '14 at 3:52
source share

Using:

 svn propset svn:ignore 'file you want to ignore' 

See Properties .

Also check the global ignore configuration parameter .

+5
Jul 02 2018-12-12T00:
source share

If you are working with TortoiseSVN, this can be done:

  • Right-click directory → TortoiseSVN → add to ignore list → bin

When committed, the root or trunk directory will be highlighted. You can also ignore multiple files at once by selecting them, then

  • Right click -> TortoiseSVN -> add to ignore list -> ignore X elements by name.
+2
Apr 7 '15 at 19:04
source share

I prefer to hide status items instead of using svn:ignore . To do this, I created a .svnignore file with templates that I want to ignore, and this alias:

 alias svn-status='svn st * 2>&1 | grep -v "$(cat .svnignore)"' 
0
Apr 13 '15 at 16:25
source share



All Articles