git
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git branch -vv
* master 79e65b6 [origin/master: ahead 1] Optimize web pages
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git pull origin
Already up to date.
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
g
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git status
On branch master
Your branch is ahead of 'origin/master' by 1 commit.
(use "git push" to publish your local commits)
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: ReadMe.md
Untracked files:
(use "git add <file>..." to include in what will be committed)
.idea/
min.css
min.js
no changes added to commit (use "git add" and/or "git commit -a")
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git add ReadMe.md
warning: LF will be replaced by CRLF in ReadMe.md.
The file will have its original line endings in your working directory
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git status
On branch master
Your branch is ahead of 'origin/master' by 1 commit.
(use "git push" to publish your local commits)
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
modified: ReadMe.md
Untracked files:
(use "git add <file>..." to include in what will be committed)
.idea/
min.css
min.js
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git commit -m "update"
[master 8ffb6bb] update
1 file changed, 4 insertions(+), 2 deletions(-)
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git push origin
Enumerating objects: 52, done.
Counting objects: 100% (52/52), done.
Delta compression using up to 6 threads
Compressing objects: 100% (28/28), done.
Writing objects: 100% (28/28), 11.92 KiB | 872.00 KiB/s, done.
Total 28 (delta 18), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (18/18)
remote: Processing changes: done
To https://git.woa.com/cbs.tce/cbsinspection.git
! [remote rejected] master -> master (prohibited by Git: Git:You are not allowed to push code to a protected branch on this project.)
error: failed to push some refs to 'https://git.woa.com/cbs.tce/cbsinspection.git'
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git status
On branch master
Your branch is ahead of 'origin/master' by 2 commits.
(use "git push" to publish your local commits)
Untracked files:
(use "git add <file>..." to include in what will be committed)
.idea/
min.css
min.js
nothing added to commit but untracked files present (use "git add" to track)
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
gi
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
t
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git push origin master:dev_pzpzzhang
Enumerating objects: 52, done.
Counting objects: 100% (52/52), done.
Delta compression using up to 6 threads
Compressing objects: 100% (28/28), done.
Writing objects: 100% (28/28), 11.92 KiB | 872.00 KiB/s, done.
Total 28 (delta 18), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (18/18)
remote: Processing changes: done
remote: Updating references: 100% (1/1)
remote:
remote: +----------------------------------------------------------------------------------------------------------------+
remote: | To create a merge request for dev_pzpzzhang, visit: |
remote: | http://git.woa.com/cbs.tce/cbsinspection/merge_requests/new?merge_request%5Bsource_branch%5D=dev_pzpzzhang |
remote: +----------------------------------------------------------------------------------------------------------------+
remote:
To https://git.woa.com/cbs.tce/cbsinspection.git
* [new branch] master -> dev_pzpzzhang
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
g
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
it
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
ba
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git branch -a
* master
remotes/origin/HEAD -> origin/master
remotes/origin/dev_pzpzzhang
remotes/origin/master
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git checkout -b origin/dev_pzpzzhang
Switched to a new branch 'origin/dev_pzpzzhang'
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (origin/dev_pzpzzhang)
$
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (origin/dev_pzpzzhang)
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (origin/dev_pzpzzhang)
$ git branch -a
master
* origin/dev_pzpzzhang
remotes/origin/HEAD -> origin/master
remotes/origin/dev_pzpzzhang
remotes/origin/master
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (origin/dev_pzpzzhang)
$ git status
On branch origin/dev_pzpzzhang
Untracked files:
(use "git add <file>..." to include in what will be committed)
.idea/
min.css
min.js
nothing added to commit but untracked files present (use "git add" to track)
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (origin/dev_pzpzzhang)
$
$ git push
To https://git.woa.com/cbs.tce/cbsinspection.git
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to 'https://git.woa.com/cbs.tce/cbsinspection.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git push origin master:dev_pzpzzhang
Everything up-to-date
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git status
On branch master
Your branch is behind 'origin/master' by 1 commit, and can be fast-forwarded.
(use "git pull" to update your local branch)
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
new file: .idea/workspace.xml
new file: Preview_Test.png
new file: min.css
new file: min.js
modified: node_cell.sh.j2
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git branch -a
* master
origin/dev_pzpzzhang
remotes/origin/HEAD -> origin/master
remotes/origin/dev_pzpzzhang
remotes/origin/master
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git commit -m "add js"
[master 08f4a5f] add js
5 files changed, 63 insertions(+), 5 deletions(-)
create mode 100644 .idea/workspace.xml
create mode 100644 Preview_Test.png
create mode 100644 min.css
create mode 100644 min.js
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git push origin master:dev_pzpzzhang
Enumerating objects: 10, done.
Counting objects: 100% (10/10), done.
Delta compression using up to 6 threads
Compressing objects: 100% (7/7), done.
Writing objects: 100% (8/8), 91.27 KiB | 6.08 MiB/s, done.
Total 8 (delta 2), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (2/2)
remote: Processing changes: done
remote: Updating references: 100% (1/1)
remote:
remote: +----------------------------------------------------------------------------------------------------------------+
remote: | To create a merge request for dev_pzpzzhang, visit: |
remote: | http://git.woa.com/cbs.tce/cbsinspection/merge_requests/new?merge_request%5Bsource_branch%5D=dev_pzpzzhang |
remote: +----------------------------------------------------------------------------------------------------------------+
remote:
To https://git.woa.com/cbs.tce/cbsinspection.git
8ffb6bb..08f4a5f master -> dev_pzpzzhang
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$ git status
On branch master
Your branch and 'origin/master' have diverged,
and have 1 and 1 different commits each, respectively.
(use "git pull" to merge the remote branch into yours)
nothing to commit, working tree clean
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/GoProject/cbsinspection (master)
$
$ git push
fatal: The current branch origin/dev_pzpzzhang has no upstream branch.
To push the current branch and set the remote as upstream, use
git push --set-upstream origin origin/dev_pzpzzhang
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cbsinspection (origin/dev_pzpzzhang)
$ git push origin origin/dev_pzpzzhang
Enumerating objects: 14, done.
Counting objects: 100% (14/14), done.
Delta compression using up to 6 threads
Compressing objects: 100% (12/12), done.
Writing objects: 100% (12/12), 1.06 KiB | 543.00 KiB/s, done.
Total 12 (delta 8), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (8/8)
remote: Processing changes: done
remote: Updating references: 100% (1/1)
remote:
remote: +-------------------------------------------------------------------------------------------------------------------------+
remote: | To create a merge request for origin/dev_pzpzzhang, visit: |
remote: | http://git.woa.com/cbs.tce/cbsinspection/merge_requests/new?merge_request%5Bsource_branch%5D=origin%2Fdev_pzpzzhang |
remote: +-------------------------------------------------------------------------------------------------------------------------+
remote:
To git.woa.com:cbs.tce/cbsinspection.git
* [new branch] origin/dev_pzpzzhang -> origin/dev_pzpzzhang
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cbsinspection (origin/dev_pzpzzhang)
$
现有的文件夹或者git版本库
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cfs_precheck
$ git init
Initialized empty Git repository in D:/Projects/cfs_precheck/.git/
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cfs_precheck (master)
$ git remote add origin git@git.woa.com:p_pzpzzhang/cfs_precheck.git
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cfs_precheck (master)
$ git add .
warning: LF will be replaced by CRLF in cluster_agent.sh.j2.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in cluster_master.sh.j2.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in include/main.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in inspection.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/cluster.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/dirty.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/fail.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/ha.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/index.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/notify.sh.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in plugin/server.sh.
The file will have its original line endings in your working directory
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cfs_precheck (master)
$ git commit -m "init"
[master (root-commit) 36cd5db] init
18 files changed, 1302 insertions(+)
create mode 100644 README.md
create mode 100644 cfs.css
create mode 100644 cluster.yaml
create mode 100644 cluster_agent.sh
create mode 100644 cluster_agent.sh.j2
create mode 100644 cluster_master.sh.j2
create mode 100644 include/main.sh
create mode 100644 inspection.sh
create mode 100644 min.css
create mode 100644 min.js
create mode 100644 plugin/cluster.sh
create mode 100644 plugin/dirty.sh
create mode 100644 plugin/fail.sh
create mode 100644 plugin/ha.sh
create mode 100644 plugin/index.sh
create mode 100644 plugin/notify.sh
create mode 100644 plugin/server.sh
create mode 100644 server.yaml
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cfs_precheck (master)
$ git push -u origin master
Enumerating objects: 22, done.
Counting objects: 100% (22/22), done.
Delta compression using up to 6 threads
Compressing objects: 100% (21/21), done.
Writing objects: 100% (22/22), 56.89 KiB | 1.63 MiB/s, done.
Total 22 (delta 6), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (6/6)
remote: Processing pre-receive: done
To git.woa.com:p_pzpzzhang/cfs_precheck.git
* [new branch] master -> master
Branch 'master' set up to track remote branch 'master' from 'origin'.
p_pzpzzhan-NB2+MarsZhang@p_pzpzzhan-NB2 MINGW64 /d/Projects/cfs_precheck (master)
$