Search code examples
mercurial

I am failing to commit to mercurial repo


I tried committing to a local hg repo and it refuses:

trouble committing plot.py!
note: commit message saved in .hg/last-message.txt
abort: Permission denied: /home/md/md_perf/.hg/store/data/plot.py.i

Solution

  • Your file permissions are messed up inside the local repository -- probably someone else pushed or committed to that repository without making sure they were leaving the permissions in a state usable by your whole group. Try these, with the appropriate substitutions, and sudo if necessary:

    chgrp -R yourgroup /home/md/md_perf
    chmod -R g+rwX /home/md/md_perf
    find /home/md/md_perf -type d -print0 | xargs -0 chmod g+s