root用戶下,使用git pull文件時候,文件權限強制自動變動

在 .git/hooks/ 目錄下 新建一個名爲 post-checkout 的文件git 將下列內容保存web #!/bin/sh pwd echo "This is post-checkout hook" chmod -R 755 ./* && chown -R www:www ./* 使post-checkout能夠被調用 chmod +x post-checkoutbash
相關文章
相關標籤/搜索