0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

pushでデプロイ

Last updated at Posted at 2022-11-24
サーバ
git init --bare ~/example.git
cat <<'EOL' > ~/example.git/hooks/post-receive
#!/bin/sh
if [ -e ~//example ]
then
  cd ~/example
  git --git-dir=.git pull
else
  git clone ~/example.git ~/example
fi
EOL
chmod 755 ~/example.git/hooks/post-receive
開発機
git init
git remote add origin ユーザ名@ホスト名:~/example.git
git add -A; git commit -m "`date '+%Y-%m-%d %H:%M:%S'`"
git push -u origin master
アンインストール
rm -rf ~/example
rm -rf ~/example.git
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?