My description was a bit off. The developer who initially checked in the
file without write permission is the one who cannot do the update. The
problem is not that fossil is storing or handling the perms wrong. The issue
is that a controlled file with no write permission causes fossil to barf on
an update.

It would have been fine if only the initial message was displayed:

"fossil: unable to open file "/tmp/mrwellan/testing/test/foo.txt" for
writing"

The remainder of the message confused the developer (and me for that
matter).

Matt
-=-
On Wed, Oct 5, 2011 at 1:25 PM, Dmitry Chestnykh <dmi...@codingrobots.com>wrote:

> > A developer accidentally (and naively) checked in a file with no write
> permissions.
> >
> > On changing the file and checking it in others could not do an update and
> would get something like this:
> >
> > > fossil update
> > UPDATE foo.txt
> > fossil: unable to open file "/tmp/mrwellan/testing/test/foo.txt" for
> writing
> > Rolling back prior filesystem changes...
> > UNDO foo.txt
> > fossil: SQLITE_ERROR: near "redoflag": syntax error
> > fossil: near "redoflag": syntax error
> > UPDATE undo SET content=:c, existsflag=1, isExe=0, isLink=0 redoflag=NOT
> redoflag WHERE pathname='foo.txt'
>
> Fossil doesn't track permissions apart from executable bit (and symlink bit
> in trunk), so I'm not sure how it's even possible to get a file from the
> repo without write permissions:
>
> "The optional 3rd argument defines any special access permissions
> associated with the file. The only special code currently defined is "x"
> which means that the file is executable. All files are always readable and
> writable. This can be expressed by "w" permission if desired but is
> optional."
>
> http://www.fossil-scm.org/index.html/doc/trunk/www/fileformat.wiki
>
> --
> Dmitry Chestnykh
>
> _______________________________________________
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to