質問するログイン新規登録

質問編集履歴

3

誤解を与える表現の修正

2019/07/03 06:04

投稿

muyon134
muyon134

スコア10

title CHANGED
File without changes
body CHANGED
@@ -24,5 +24,5 @@
24
24
 
25
25
  ##注意点
26
26
 
27
- 同一ホスト内の単なるディレクトリ操作で完結させたいので、
27
+ 同一ホスト内のgitコマンド操作で完結させたいので、
28
28
  git@github.comやhttps://hostnameのようなネットワーク処理が関連する方法は除外します

2

注意点追加

2019/07/03 06:04

投稿

muyon134
muyon134

スコア10

title CHANGED
File without changes
body CHANGED
@@ -1,6 +1,6 @@
1
1
  .gitを持たない通常のフォルダ「non-git」からローカル内にベアレポジトリを作成する。
2
2
 
3
- やったこと
3
+ ## やったこと
4
4
 
5
5
  まず、non-bareをbareに切り替える。[参照](https://qnighy.hatenablog.com/entry/2017/02/25/154752)
6
6
 
@@ -20,4 +20,9 @@
20
20
  ```
21
21
  生成されたremote-git.gitをnon-bare cloneしても、
22
22
  「warning: You appear to have cloned an empty repository. 」
23
- とでて、non-bareリポジトリを作成できない
23
+ とでて、non-bareリポジトリを作成できない
24
+
25
+ ##注意点
26
+
27
+ 同一ホスト内の単なるディレクトリ操作で完結させたいので、
28
+ git@github.comやhttps://hostnameのようなネットワーク処理が関連する方法は除外します

1

rootディレクトリ追加

2019/07/03 04:25

投稿

muyon134
muyon134

スコア10

title CHANGED
File without changes
body CHANGED
@@ -5,15 +5,18 @@
5
5
  まず、non-bareをbareに切り替える。[参照](https://qnighy.hatenablog.com/entry/2017/02/25/154752)
6
6
 
7
7
  ```
8
+ #以下rootを~とする。
8
9
  cp -pr non-git non-git.bak
9
10
  mv non-git remote-git
10
11
  cd remote-git
11
12
  git init
12
13
  git config core.bare true
13
14
  mv .git ../remote-git.git
15
+ cd ..
16
+ rm -r remote-git
17
+ mkdir local
18
+ cd local
14
- cd ../remote-git.git
19
+ git clone ~/remote-git.git
15
- rm -r ../remote-git
16
-
17
20
  ```
18
21
  生成されたremote-git.gitをnon-bare cloneしても、
19
22
  「warning: You appear to have cloned an empty repository. 」