fschulze/mr.developer — Issue #77: mercurial matches check
Author: lugensa
Created: 2012-01-11 14:07:16+00:00
State: open

"hg showconfig paths.default" prints a lot more than just a string, maybe we can use just "hg paths". But the problem we have is the checking in def matches with "==" insteed of "in".

```bash
#OLD
% hg showconfig paths.default
alias 'debugconfig' shadows command 'showconfig'
read config from: /usr/etc/mercurial/hgrc
read config from: /etc/mercurial/hgrc
read config from: /etc/mercurial/hgrc.d/cacerts.rc
read config from: /etc/mercurial/hgrc.d/hgext.rc
read config from: /etc/mercurial/hgrc.d/mergetools.rc
read config from: /home/jo/.hgrc
none: https://jo@lu1.foo.net/hg/bo_bar
```

```bash
#NEW
% hg paths
default = https://jo@lu1.foo.net/hg/bo_bar
```

```python
def matches(self):
...
#OLD
#return (self.source['url'] + '\n' == stdout)
#NEW
return (self.source['url'] in stdout)
```

Cya Josip