1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
|
## 报错解决
### git checkout -b xxx origin/xxx 报错
```bash [root@ningan dubhe]# git checkout -b dev_230109 origin/dev_230109 fatal: 'origin/dev_230109' is not a commit and a branch 'dev_230109' cannot be created from it
[root@ningan dubhe]# git branch * anwy-dev anwy-test master rc1 rc2 rc2-0.1.4 rc2-testable rc2-testable2
## 解决办法 [root@ningan dubhe]# git pull remote: Enumerating objects: 39, done. remote: Counting objects: 100% (39/39), done. remote: Compressing objects: 100% (35/35), done. remote: Total 39 (delta 12), reused 0 (delta 0), pack-reused 0 Unpacking objects: 100% (39/39), done. From http: * [new branch] dev_230109 -> origin/dev_230109 Already up to date. [root@ningan dubhe]# [root@ningan dubhe]# git branch * anwy-dev anwy-test master rc1 rc2 rc2-0.1.4 rc2-testable rc2-testable2 [root@ningan dubhe]# [root@ningan dubhe]# git checkout -b dev_230109 origin/dev_230109 M Makefile M config/cuk-config.cue D config/kubeconfig-n2 M config/regionConfig.yaml M go.mod M go.sum M pkg/utils/common_vars_insert.go M pkg/utils/common_vars_insert_test.go Branch 'dev_230109' set up to track remote branch 'dev_230109' from 'origin'. Switched to a new branch 'dev_230109' [root@ningan dubhe]#
[root@ningan dubhe]# git branch anwy-dev anwy-test * dev_230109 master rc1 rc2 rc2-0.1.4 rc2-testable rc2-testable2
|