git hooks 执行 git命令

1
2
3
4
#!/bin/sh
cd /path/to/working-copy/
unset GIT_DIR
git pull repo branch

当git hooks脚本执行git命令时

[重要]在执行git命令之前,执行

unset GIT_DIR

centos 安装 ruby

Step 1: Upgrade Packages

It is the best practice to keep your system up to date with latest packages. Before running below command make sure that update will not affect to your running apps ( if any )on server else skip it

1
# yum update