1
2

More than 1 year has passed since last update.

Githubと新しいレポジトリの連携(恥ずかし)[Github]

Last updated at Posted at 2021-11-23

追記

なお本来はgit cloneにて、Github上で作成したリポジトリをローカルに入れ込む管理の方が良い。

目的

久しぶりにGithubに新しいリポジトリを作成しました。が、色々忘れていて少し調べたので、次はスムーズに進められるようまとめておきます。

Github連携

# 1. Githubにディレクトリ作成

# 2. ローカルのgitを初期化
cd ~/repository/repository2 # 該当のディレクトリへ
git init
git add. 
git commit -m 'initialize'

# 3. リモートのリポジトリを登録(SSH接続)
git remote add origin git@github.com:useer_name/repository_name

# 4. リモートにpush
git push origin master

おわり

初歩的すぎて、、

1
2
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
1
2