# \[Subversion module\] Bug when using repositories with svn:externals

**URL:** <https://forum.ansible.com/t/subversion-module-bug-when-using-repositories-with-svn-externals/17512>\
**Category:** Ansible Project\
**Created:** [February 13, 2015, 2:50pm UTC](https://forum.ansible.com/t/subversion-module-bug-when-using-repositories-with-svn-externals/17512 "2015-02-13T14:50:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sylvain.guglielmi](https://avatars.discourse-cdn.com/v4/letter/s/f1d935/32.png) [@sylvain.guglielmi](https://forum.ansible.com/u/sylvain.guglielmi)\
**Post date:** [February 13, 2015, 2:50pm UTC](https://forum.ansible.com/t/subversion-module-bug-when-using-repositories-with-svn-externals/17512/1 "2015-02-13T14:50:51Z")

</div>

Hello everyone,

I’ve noticed that the subversion module always reports changes when updating, even though my repo (with svn:externals) has not changed.  
It was linked to the way the module detects local modifications. The call to “svn status” has no formatting options, and a regexp tries to  
detect lines that correspond to a real local modifications (actually, all it does is discard ‘?’ lines, non-versioned files). But there are others  
“svn status” codes that should be discarded ( ‘X’ and ‘I’ see {1} ).

More over, when a repo has externals, “svn status” output will no be easily parsed, because some text lines appear :  
“Performing status on external item at …”.

The solution I propose is to use the --quiet option for svn status, it makes the output parsing-friendly, and only output anything if there are  
local changes, which is exactly what is wanted here.  
As a consequence, there is no more need for a regexp, only test if the output is empty.

Here’s a pull request that fixes this {2}.

Thanks in advance.

{1} [http://svnbook.red-bean.com/en/1.7/svn.ref.svn.c.status.html](http://svnbook.red-bean.com/en/1.7/svn.ref.svn.c.status.html)  
{2} [https://github.com/ansible/ansible-modules-core/pull/783](https://github.com/ansible/ansible-modules-core/pull/783)
