Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

hg update error

Tags:

mercurial

I am getting the following error when trying to run hg update:

abort: Operation not permitted:
/var/www/simira/web/public/images/nominations/13/big/4f196667cf5a2.jpg

Here is some info:

$ cd /var/www/simira/web/public/images/nominations/13/big/
$ ll ./4f196667cf5a2.jpg 
-rw-rw-r-- 1 martin portadesign 15356 Feb  2 22:10 4f196667cf5a2.jpg
$ ll -d ./
drwxrwxr-x 2 martin portadesign 4096 Feb  2 22:10 ./
$ id
uid=5004(clime) gid=5007(portadesign) groups=5007(portadesign),10(wheel),48(apache)

Tell me what is wrong, please...

like image 426
clime Avatar asked Feb 02 '12 21:02

clime


1 Answers

The problem was caused by hg attempting to change the permissions of the file:

$ sudo hg update
$ ll ./4f196667cf5a2.jpg
./ -rwxrwxr-x 1 martin portadesign 15356 Feb  2 22:10 4f196667cf5a2.jpg

As can be seen, it added executable bit to the image. That is the only bit that hg acually tracks and there does not seem to be a "switch-off" option. The problem is that only an owner of the file can change its permissions.

like image 114
clime Avatar answered Nov 14 '22 18:11

clime