<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Subversion &#8211; My Shitty Code</title>
	<atom:link href="https://myshittycode.com/tag/subversion/feed/" rel="self" type="application/rss+xml" />
	<link>https://myshittycode.com</link>
	<description>Embracing the Messiness in Search of Epic Solutions</description>
	<lastBuildDate>Fri, 06 Jan 2023 17:18:28 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.1</generator>

<image>
	<url>https://myshittycode.com/wp-content/uploads/2022/04/cropped-icon-32x32.png</url>
	<title>Subversion &#8211; My Shitty Code</title>
	<link>https://myshittycode.com</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">205304208</site>	<item>
		<title>IntelliJ: Handling SVN Global Ignore List</title>
		<link>https://myshittycode.com/2014/08/05/intellij-handling-svn-global-ignore-list/</link>
					<comments>https://myshittycode.com/2014/08/05/intellij-handling-svn-global-ignore-list/#comments</comments>
		
		<dc:creator><![CDATA[Shitty Author]]></dc:creator>
		<pubDate>Tue, 05 Aug 2014 19:07:58 +0000</pubDate>
				<category><![CDATA[Development Tools]]></category>
		<category><![CDATA[IntelliJ IDEA]]></category>
		<category><![CDATA[Subversion]]></category>
		<guid isPermaLink="false">http://myshittycode.com/?p=534</guid>

					<description><![CDATA[<p>PROBLEM Every time we check out a project from SVN for the first time, we always have to remember to set the SVN ignore list in IntelliJ. SOLUTION NOTE: We only need to perform these steps just once per development machine. To do so, we configure the SVN global ignore list and have IntelliJ to [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2014/08/05/intellij-handling-svn-global-ignore-list/">IntelliJ: Handling SVN Global Ignore List</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h2 class="wp-block-heading">PROBLEM</h2>



<p>Every time we check out a project from SVN for the first time, we always have to <strong>remember</strong> to set the SVN ignore list in IntelliJ.</p>



<h2 class="wp-block-heading">SOLUTION</h2>



<p><strong>NOTE: We only need to perform these steps just once per development machine.</strong></p>



<p>To do so, we configure the SVN global ignore list and have IntelliJ to conform to that rule.</p>



<p>In Mac, go to <b>IntelliJ IDEA -&gt; Preferences</b>. In Windows, go to <b>File -&gt; Settings</b>.</p>



<figure class="wp-block-image aligncenter"><img fetchpriority="high" decoding="async" width="952" height="312" src="https://myshittycode.com/wp-content/uploads/2014/08/screen_shot_2014-08-05_at_1_22_38_pm-1.png?x45560" alt="" class="wp-image-535" srcset="https://myshittycode.com/wp-content/uploads/2014/08/screen_shot_2014-08-05_at_1_22_38_pm-1.png 952w, https://myshittycode.com/wp-content/uploads/2014/08/screen_shot_2014-08-05_at_1_22_38_pm-1-300x98.png 300w, https://myshittycode.com/wp-content/uploads/2014/08/screen_shot_2014-08-05_at_1_22_38_pm-1-768x252.png 768w" sizes="(max-width: 952px) 100vw, 952px" /></figure>



<p>In the preference dialog, go to <b>Version Control -&gt; Subversion</b>.<br></p>



<p>Check <b>Use system default Subversion configuration directory</b>.</p>



<p>Note down Subversion configuration directory.</p>



<p>Close preference dialog.</p>



<p>Open <b>[SVN_CONFIG_DIR]/config</b> in a text editor.</p>



<p>Scroll to the <b>[miscellany]</b> section that looks something like this:-</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
...
&#x5B;miscellany]
### Set global-ignores to a set of whitespace-delimited globs
### which Subversion will ignore in its &#039;status&#039; output, and
### while importing or adding files and directories.
### &#039;*&#039; matches leading dots, e.g. &#039;*.rej&#039; matches &#039;.foo.rej&#039;.
# global-ignores = *.o *.lo *.la *.al .libs *.so *.so.&#x5B;0-9]* *.a *.pyc *.pyo
#   *.rej *~ #*# .#* .*.swp .DS_Store
### Set log-encoding to the default encoding for log messages
# log-encoding = latin1
...
</pre></div>


<p>Uncomment <b>global-ignores</b> statement by removing <b>#</b>:-</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; highlight: [7,8]; title: ; notranslate">
...
&#x5B;miscellany]
### Set global-ignores to a set of whitespace-delimited globs
### which Subversion will ignore in its &#039;status&#039; output, and
### while importing or adding files and directories.
### &#039;*&#039; matches leading dots, e.g. &#039;*.rej&#039; matches &#039;.foo.rej&#039;.
global-ignores = *.o *.lo *.la *.al .libs *.so *.so.&#x5B;0-9]* *.a *.pyc *.pyo
   *.rej *~ #*# .#* .*.swp .DS_Store
### Set log-encoding to the default encoding for log messages
# log-encoding = latin1
...
</pre></div>


<p>Add the following patterns:-<b><b><br></b></b></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; highlight: [9,10]; title: ; notranslate">
...
&#x5B;miscellany]
### Set global-ignores to a set of whitespace-delimited globs
### which Subversion will ignore in its &#039;status&#039; output, and
### while importing or adding files and directories.
### &#039;*&#039; matches leading dots, e.g. &#039;*.rej&#039; matches &#039;.foo.rej&#039;.
global-ignores = *.o *.lo *.la *.al .libs *.so *.so.&#x5B;0-9]* *.a *.pyc *.pyo
   *.rej *~ #*# .#* .*.swp .DS_Store
   .idea target .git .classpath .project .settings *.iml *.log *.bak *.class *.jar *.war *.ear
   node_modules pom.xml.versionsBackup
### Set log-encoding to the default encoding for log messages
# log-encoding = latin1
...
</pre></div>


<p>Save and close this config file.</p>



<p>Now, all the unnecessary files will not appear under &#8220;Changes&#8221; section in IntelliJ and they will not be committed into SVN.</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2014/08/05/intellij-handling-svn-global-ignore-list/">IntelliJ: Handling SVN Global Ignore List</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://myshittycode.com/2014/08/05/intellij-handling-svn-global-ignore-list/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">534</post-id>	</item>
		<item>
		<title>IntelliJ: Configuring SVN Ignored Files</title>
		<link>https://myshittycode.com/2013/12/02/intellij-configuring-svn-ignored-files/</link>
					<comments>https://myshittycode.com/2013/12/02/intellij-configuring-svn-ignored-files/#respond</comments>
		
		<dc:creator><![CDATA[Shitty Author]]></dc:creator>
		<pubDate>Mon, 02 Dec 2013 20:22:46 +0000</pubDate>
				<category><![CDATA[Development Tools]]></category>
		<category><![CDATA[IntelliJ IDEA]]></category>
		<category><![CDATA[Subversion]]></category>
		<guid isPermaLink="false">http://myshittycode.com/?p=248</guid>

					<description><![CDATA[<p>OVERVIEW Whenever we share a project in SVN or checks out a project from SVN, we have to perform a one-time configuration on the project to ignore selected files from being committed into SVN. That said, this configuration will only work if the files are not already in SVN. PROBLEM Let&#8217;s assume we have a [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2013/12/02/intellij-configuring-svn-ignored-files/">IntelliJ: Configuring SVN Ignored Files</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h2 class="wp-block-heading">OVERVIEW</h2>



<p>Whenever we share a project in SVN or checks out a project from SVN, we have to perform a one-time configuration on the project to ignore selected files from being committed into SVN. That said, this configuration will <strong>only work if the files are not already in SVN</strong>.</p>



<h2 class="wp-block-heading">PROBLEM</h2>



<p>Let&#8217;s assume we have a Maven project that contains an EAR module and a WAR module:-</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; highlight: [2,3,4,6,11]; title: ; notranslate">
EpicApp
├── .idea
│   └── ...
├── EpicApp.iml
├── epicapp-ear
│   ├── epicapp-ear.iml
│   ├── pom.xml
│   └── src
│       └── ...
├── epicapp-war
│   ├── epicapp-war.iml
│   ├── pom.xml
│   └── src
│       └── ...
└── pom.xml
</pre></div>


<p>IntelliJ generates <b>.idea</b> folder and <b>*.iml</b> files to store our project settings and module configuration.</p>



<p>When we run <b>mvn clean compile</b>, the <b>target</b> folders are created:-</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; highlight: [10,11,17,18,20,21]; title: ; notranslate">
EpicApp
├── .idea
│   └── ...
├── EpicApp.iml
├── epicapp-ear
│   ├── epicapp-ear.iml
│   ├── pom.xml
│   ├── src
│   │   └── ...
│   └── target
│       └── ...
├── epicapp-war
│   ├── epicapp-war.iml
│   ├── pom.xml
│   ├── src
│   │   └── ...
│   └── target
│       └── ...
├── pom.xml
└── target # Depending on how the root pom.xml is configured, this folder may or may not appear.
    └── ...
</pre></div>


<p>If we look at the overall project structure, there are tons of generated files that are not created by us:-</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; highlight: [2,3,4,6,10,11,13,17,18,20,21]; title: ; notranslate">
EpicApp
├── .idea
│   └── ...
├── EpicApp.iml
├── epicapp-ear
│   ├── epicapp-ear.iml
│   ├── pom.xml
│   ├── src
│   │   └── ...
│   └── target
│       └── ...
├── epicapp-war
│   ├── epicapp-war.iml
│   ├── pom.xml
│   ├── src
│   │   └── ...
│   └── target
│       └── ...
├── pom.xml
└── target # Depending on how the root pom.xml is configured, this folder may or may not appear.
    └── ...
</pre></div>


<p>First, we definitely want to ignore <b>target</b> folders from being committed into SVN.</p>



<p>Now, regarding whether to ignore <b>.idea</b> folder and <b>*.iml</b> files, there are two camps out there:-</p>



<ul class="wp-block-list">
<li>Camp <strong style="color: #eeb4b4;">PINK</strong> will commit the IntelliJ generated files into SVN so that the project configuration is shared among team members.</li>



<li>Camp <strong style="color: #4f94cd;">BLUE</strong> will <strong>NOT</strong> commit files that are not created by them.</li>
</ul>



<p>What&#8217;s my take? I&#8217;m with Camp <strong style="color: #4f94cd;">BLUE</strong> because I don&#8217;t like pink in the first place. In the past, I tend to commit all IntelliJ generated files into SVN. However, it was a nightmare working in a team environment because every team member kept overwriting these files from one other, resulting endless SVN conflicts. Since we encourage folks to <strong>only commit the files they modify (or create)</strong>, I see no absolute reason to commit these IntelliJ generated files. We saw more cons than pros based on our past experience.</p>



<h2 class="wp-block-heading">SOLUTION 1: Add Ignored Files Using IntelliJ</h2>



<p>Based on the example above, there are 5 things we need to ignore:-</p>



<ul class="wp-block-list">
<li><b>epicapp-ear/target/</b> directory</li>



<li><b>epicapp-war/target/</b> directory</li>



<li><b>target/</b> directory</li>



<li><b>.idea/</b> directory</li>



<li><b>*.iml</b> files</li>
</ul>



<p>So, in IntelliJ&#8230;</p>



<ol class="wp-block-list">
<li>Select &#8220;Changes&#8221; tab at the bottom.</li>



<li>Select &#8220;Local&#8221; subtab.</li>



<li>Click on &#8220;Configure Ignored Files&#8221; button.<br><a href="https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-09-42_pm-11-1.png?x45560"><img decoding="async" class="aligncenter size-full wp-image-260" src="https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-09-42_pm-11-1.png?x45560" alt="&quot;Changes&quot; tab " width="537" height="311" srcset="https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-09-42_pm-11-1.png 537w, https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-09-42_pm-11-1-300x174.png 300w" sizes="(max-width: 537px) 100vw, 537px" /></a></li>



<li>In &#8220;Configure Ignored Files&#8221; dialog, click on the &#8220;+&#8221; button.</li>



<li>Add the ignored file (or directory).<br><a href="https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-15-19_pm-10-1.png?x45560"><img decoding="async" class="aligncenter size-full wp-image-261" src="https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-15-19_pm-10-1.png?x45560" alt="&quot;Configure Ignored Files&quot; dialog" width="452" height="346" srcset="https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-15-19_pm-10-1.png 452w, https://myshittycode.com/wp-content/uploads/2013/12/screen_shot_2013-12-02_at_1-15-19_pm-10-1-300x230.png 300w" sizes="(max-width: 452px) 100vw, 452px" /></a></li>



<li>Repeat step 4 and 5 until all ignored files are added.</li>
</ol>



<h2 class="wp-block-heading">SOLUTION 2: Add Ignored Files Directly in <b>.idea/workspace.xml</b></h2>



<p>If you have quite a few files and directories to ignore, the above solution can be rather tedious.</p>



<p>So, an alternative solution is to &#8220;hack&#8221; <b>.idea/workspace.xml</b> by entering all the ignored paths under &#8220;ChangeListManager&#8221; component:-</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: xml; highlight: [5,6,7,8,9,10,11,12,13,14,15,16,17]; title: ; notranslate">
&lt;!--?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?--&gt;
&lt;project&gt;
    &lt;component name=&quot;ChangeListManager&quot;&gt;
        ...
        &lt;ignored path=&quot;epicapp-war/target/&quot;&gt;
        &lt;ignored path=&quot;epicapp-ear/target/&quot;&gt;
        &lt;ignored path=&quot;.idea/&quot;&gt;
        &lt;ignored path=&quot;.settings/&quot;&gt;
        &lt;ignored path=&quot;target/&quot;&gt;
        &lt;ignored path=&quot;.DS_Store&quot;&gt;
        &lt;ignored path=&quot;.classpath&quot;&gt;
        &lt;ignored path=&quot;.project&quot;&gt;
        &lt;ignored mask=&quot;*.iws&quot;&gt;
        &lt;ignored mask=&quot;*~&quot;&gt;
        &lt;ignored mask=&quot;*.bak&quot;&gt;
        &lt;ignored mask=&quot;*.log&quot;&gt;
        &lt;ignored mask=&quot;*.iml&quot;&gt;
    &lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/ignored&gt;&lt;/component&gt;
    ...
&lt;/project&gt;
</pre></div>


<p>In this example, we ignore all <b>target</b> folders, all IntelliJ generated files, all Eclipse generated files, all OS-specific generated files and some useless files.</p>



<p>When we save <b>.idea/workspace.xml</b>, IntelliJ immediately detects a change made to this file (because it is intelligent) and it will prompt us to reload the project. Once reloaded, the &#8220;Configure Ignored Files&#8221; dialog will reflect the changes made.</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2013/12/02/intellij-configuring-svn-ignored-files/">IntelliJ: Configuring SVN Ignored Files</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://myshittycode.com/2013/12/02/intellij-configuring-svn-ignored-files/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">248</post-id>	</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Lazy Loading (feed)
Database Caching 52/74 queries in 0.115 seconds using Disk

Served from: myshittycode.com @ 2026-02-21 15:11:21 by W3 Total Cache
-->