Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8714057
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T05:29:52+00:00 2026-06-13T05:29:52+00:00

I am using gitolite git server on a ubuntu linux server. I used a

  • 0

I am using gitolite git server on a ubuntu linux server. I used a hook that will be called on every push and will update a server’s directory(which include live site’s source code).

Now, whenever I change something on my local pc and push the changes to server, the hook is being called and the pull request are being executed fine. But, problem is, the files which were updated, are now having changed permission. Like:

rwxrwxr_x (before)
rwx_____x (After)

After few searches, I did came up with this solution . I did tried it with both my global git config and repository specific config settings. after setting the config, whenever I am trying to push from my local pc, the same issue is happening again like above, thus seems, for some reason, the solution isn’t working.

Does anybody have any idea, what can be the reason plz? Do I have to do anything additionally besides the config settings? Any suggestions are welcome. Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T05:29:53+00:00Added an answer on June 13, 2026 at 5:29 am

    As the OP Rana confirms in the comments, if the hook starts with:

    umask 002
    

    It will generate files with the right protection.


    Alan Thompson mentions:

    core.filemode only affects diffs against your working dir, not diffs between 2 commits in the repo.
    So, if you have already committed the different file modes, you’ll have to use filter-branch, as in “Can I make git diff ignore permission changes“.

    git filter-branch -f --tree-filter 'find * -type f | xargs chmod 644 ' -- --all
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

using Gitolite on a Ubuntu server. Have a project im working on that i
I'm trying to install my own git server with these instructions. http://cisight.com/how-to-setup-git-server-using-gitolite-in-ubuntu-11-10-oneiric/ But I
I am using gitolite as git server. It was working fine earlier . but
I'm currently using gitolite, and in my post-receive hook I'm pushing to a (local)
I tried to install git + gitolite following this manual - using root instalation
We have a self hosted git server (Gitolite) on a VPS account (CPU:2.68GHz RAM:1824MB).
Using emacs on Ubuntu 11.10. I want to connect to a SQL Server database
I have two issues. I have Ubuntu 10.10 and I have installed git server
I'm using post-receive-email hook from the Git distribution to send e-mails to certain users
Is it possible to run a git server over ssh, using authorized_keys and command=

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.