Fossil SCM

update/revert don't set permissions

Fixed

baf9b6b11e08c1d… · opened 15 years, 2 months ago

Type
Code_Defect
Priority
Severity
Severe
Resolution
Fixed
Subsystem
Created
Feb. 8, 2011 4:33 p.m.

In reading through update.c, it doesn't look as though updates or reverts will set the permissions of files when recreating them. Unlike checkout's code path, update/revert doesn't call checkout.c:checkout_set_all_exe() to set the permissions of files. At first glance, it looks like the best place to check to see if permissions need to be updated is via vfile.c:vfile_check_signature() (in the call path for revert) or in vfile.c:vfile_compare_repository_to_disk() (not used other than in checkin).

To reproduce:

# In a test repository with `alias fs fossil`
printf '#\!/bin/sh\necho test script perms\n' > test.sh
chmod 755 test.sh
fs add test.sh
fs ci -m "Adding a test script"
rm -f test.sh
fs revert test.sh
# test.sh will be mode 644

anonymous added on 2011-02-15 00:06:57 UTC: This is a real pain for me. I guess the work-around is a clean checkout ....


anonymous claiming to be rkeene added on 2011-02-27 20:45:10 UTC: We are also having this issue in Tcl.



Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button