LoginSignup
6
5

More than 5 years have passed since last update.

Macのlocalにgitのリモートリポジトリを構築する

Posted at

Macで自分自身にssh接続出来るようにしておく

jobeet プロジェクトディレクトリ
jobeet.git 空のディレクトリ

$ pwd
/Users/本名/Sites/php/symfony
$ ls
jobeet     jobeet.git
$ cd jobeet.git
$ git init --bare
# リモートリポジトリが作られる
$ cd ..
$ cd jobeet
$ git init
$ git add .
$ git ci
$ git remote add origin localhost:Sites/php/symfony/jobeet.git
$ git push origin master
$ git push
$ git show
$ cd ..
$ cd jobeet.git/
$ git show
6
5
1

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
6
5