On Sun, Mar 27, 2011 at 10:48:34AM +0200, Richard Levitte wrote:
> In message <[email protected]> on Sat, 26 Mar 2011 
> 20:49:09 -0400, Hendrik Boom <[email protected]> said:
> 
> hendrik> pattern "com.pooq.hendrik.write*"
> hendrik> 
> hendrik> doesn't work, but
> hendrik> 
> hendrik> pattern "com.pooq.hendrik.write.*"
> hendrik> 
> hendrik> does when I'm trying to sync branches
> hendrik> 
> hendrik> com.pooq.hendrik.write.melinda
> 
> Please show the exact command, that might tell us more.

OK.  Here goes:

Every time the serve command is

mtn --db ~/monotone/write.db -k [email protected] serve

and the client-side sync command is

mtn sync

And I did remember to restart the server for each run, after changing 
read-permissions.


When on the server the read-permissions reads as follows

hendrik@april:~/monotone$ cat ~/.monotone/read-permissions
pattern "com.pooq.hendrik.write*"
allow "[email protected]"
allow "[email protected]"
allow "[email protected]


hendrik@april:~/monotone$ 


thee output from sync is:

hendrik@notlookedfor:~/write/Melinda$ mtn sync
mtn: connecting to mtn://topoi.pooq.com
mtn: finding items to synchronize:
mtn: certificates | keys | revisions
mtn:          192 |    3 |        64
mtn: warning: protocol error while processing peer mtn://topoi.pooq.com: 
'received network error: denied 'ad968be7244234e8d653201ab1ddd33b53ffa04d' read 
permission for '*' excluding '' because of branch 
'com.pooq.hendrik.write.melinda''
mtn:  bytes in | bytes out | revs in
mtn:       167 |       328 |       0
mtn: error: processing failure while talking to peer mtn://topoi.pooq.com, 
disconnecting
hendrik@notlookedfor:~/write/Melinda$ 


whereas with this read-permissions file on the server

hendrik@april:~/.monotone$ cat read-permissions
pattern "com.pooq.hendrik.write.*"
allow "[email protected]"
allow "[email protected]"
allow "[email protected]"
hendrik@april:~/.monotone$ 

sync produces:

hendrik@notlookedfor:~/write/Melinda$ mtn sync
mtn: connecting to mtn://topoi.pooq.com
mtn: finding items to synchronize:
mtn: certificates | keys | revisions
mtn:          192 |    3 |        64
mtn:  bytes in | bytes out | revs in | revs out
mtn:     1.1 k |     1.4 k |     0/0 |      0/0
mtn: successful exchange with mtn://topoi.pooq.com
mtn: note: your workspace has not been updated
hendrik@notlookedfor:~/write/Melinda$ 



> 
> hendrik> Why?  What are the rules for '*' and '.' in patterns?
> 
> The same as bash globs.

So "." should match a period, and "*" matches zero or more characters.
That's what I thought.  Bash has some special rules about filenames 
starting with a dot.  Could they be tripping me up?

-- hendrik

_______________________________________________
Monotone-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/monotone-devel

Reply via email to