Вы не можете выбрать более 25 тем
Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
1574 строки
61 KiB
Plaintext
1574 строки
61 KiB
Plaintext
Last login: Sun Mar 24 13:32:14 on ttys000
|
|
dmitrijantonov@MacBook-Air-Dmitrij ~ % cd desktop
|
|
dmitrijantonov@MacBook-Air-Dmitrij desktop % cd lab02
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % ls
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % mkdir alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % mkdir bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % mkdir project
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git init
|
|
Initialized empty Git repository in /Users/dmitrijantonov/Desktop/lab02/alice/project/.git/
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ls -A
|
|
.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git config user.name 'Alice (AntonovDA)'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git config user.email 'AntonovDAn@mpei.ru'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
|
|
No commits yet
|
|
|
|
Changes to be committed:
|
|
(use "git rm --cached <file>..." to unstage)
|
|
new file: main2.cpp
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m 'code: çàãîòîâêà ïðîãðàììû'
|
|
[main (root-commit) 9896924] code: çàãîòîâêà ïðîãðàììû
|
|
1 file changed, 9 insertions(+)
|
|
create mode 100644 main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add project.cbp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m 'build: add projecct file'
|
|
[main bad78bc] build: add projecct file
|
|
1 file changed, 9 insertions(+)
|
|
create mode 100644 project.cbp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
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: main2.cpp
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
no changes added to commit (use "git add" and/or "git commit -a")
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "..."
|
|
[main 9f6cd71] ...
|
|
1 file changed, 3 insertions(+), 3 deletions(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "..."
|
|
[main 6d4ba94] ...
|
|
1 file changed, 4 insertions(+)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -a -m "code: add sum of a,b"
|
|
[main 051a5a1] code: add sum of a,b
|
|
1 file changed, 3 insertions(+), 1 deletion(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
.gitignore
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
.gitignore
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
.gitignore
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
.gitignore
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ls
|
|
main2 main2.cpp main2.dSYM project.cbp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ls -A
|
|
.DS_Store .gitignore main2.cpp project.cbp
|
|
.git main2 main2.dSYM
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
.gitignore
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
.gitignore
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add .gitignore
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m 'git: ignoreted files'
|
|
[main ae9e215] git: ignoreted files
|
|
1 file changed, 1 insertion(+)
|
|
create mode 100644 .gitignore
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
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: .gitignore
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
no changes added to commit (use "git add" and/or "git commit -a")
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log
|
|
commit ae9e215dfc2d2d4b7293756374f86a6a98d96f85 (HEAD -> main)
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 15:11:41 2024 +0300
|
|
|
|
git: ignoreted files
|
|
|
|
commit 051a5a1ec2613fa76bdebad3c00859fe09a98a30
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:57:23 2024 +0300
|
|
|
|
code: add sum of a,b
|
|
|
|
commit 6d4ba94206e098876de23f7957beb100a3bb1a41
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:50:50 2024 +0300
|
|
|
|
...
|
|
|
|
commit 9f6cd71ea75501bc4bd6456090797c24484cac6a
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:49:31 2024 +0300
|
|
|
|
...
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --stat
|
|
commit ae9e215dfc2d2d4b7293756374f86a6a98d96f85 (HEAD -> main)
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 15:11:41 2024 +0300
|
|
|
|
git: ignoreted files
|
|
|
|
.gitignore | 1 +
|
|
1 file changed, 1 insertion(+)
|
|
|
|
commit 051a5a1ec2613fa76bdebad3c00859fe09a98a30
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:57:23 2024 +0300
|
|
|
|
code: add sum of a,b
|
|
|
|
main2.cpp | 4 +++-
|
|
1 file changed, 3 insertions(+), 1 deletion(-)
|
|
|
|
commit 6d4ba94206e098876de23f7957beb100a3bb1a41
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:50:50 2024 +0300
|
|
|
|
...
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate
|
|
ae9e215 (HEAD -> main) git: ignoreted files
|
|
051a5a1 code: add sum of a,b
|
|
6d4ba94 ...
|
|
9f6cd71 ...
|
|
bad78bc build: add projecct file
|
|
9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* ae9e215 (HEAD -> main) git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log -- main2.cpp
|
|
commit 051a5a1ec2613fa76bdebad3c00859fe09a98a30
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:57:23 2024 +0300
|
|
|
|
code: add sum of a,b
|
|
|
|
commit 6d4ba94206e098876de23f7957beb100a3bb1a41
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:50:50 2024 +0300
|
|
|
|
...
|
|
|
|
commit 9f6cd71ea75501bc4bd6456090797c24484cac6a
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:49:31 2024 +0300
|
|
|
|
...
|
|
|
|
commit 9896924a35ca5fdd52939beef46d8e0a885b0993
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:44:52 2024 +0300
|
|
|
|
code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --grep "code:"
|
|
commit 051a5a1ec2613fa76bdebad3c00859fe09a98a30
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:57:23 2024 +0300
|
|
|
|
code: add sum of a,b
|
|
|
|
commit 9896924a35ca5fdd52939beef46d8e0a885b0993
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:44:52 2024 +0300
|
|
|
|
code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --grep "build:"
|
|
commit bad78bcf10ad96e53ec091c998e9e9c7957d725b
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:47:54 2024 +0300
|
|
|
|
build: add projecct file
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log -- project.cbp
|
|
commit bad78bcf10ad96e53ec091c998e9e9c7957d725b
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:47:54 2024 +0300
|
|
|
|
build: add projecct file
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show <HEAD>
|
|
zsh: parse error near `\n'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show main
|
|
commit ae9e215dfc2d2d4b7293756374f86a6a98d96f85 (HEAD -> main)
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 15:11:41 2024 +0300
|
|
|
|
git: ignoreted files
|
|
|
|
diff --git a/.gitignore b/.gitignore
|
|
new file mode 100644
|
|
index 0000000..5a12c2a
|
|
--- /dev/null
|
|
+++ b/.gitignore
|
|
@@ -0,0 +1 @@
|
|
+.exe
|
|
\ No newline at end of file
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show HEAD
|
|
commit ae9e215dfc2d2d4b7293756374f86a6a98d96f85 (HEAD -> main)
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 15:11:41 2024 +0300
|
|
|
|
git: ignoreted files
|
|
|
|
diff --git a/.gitignore b/.gitignore
|
|
new file mode 100644
|
|
index 0000000..5a12c2a
|
|
--- /dev/null
|
|
+++ b/.gitignore
|
|
@@ -0,0 +1 @@
|
|
+.exe
|
|
\ No newline at end of file
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show d2e8af
|
|
fatal: ambiguous argument 'd2e8af': unknown revision or path not in the working tree.
|
|
Use '--' to separate paths from revisions, like this:
|
|
'git <command> [<revision>...] -- [<file>...]'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show 5a12c2a
|
|
.exe
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show HEAD~1
|
|
commit 051a5a1ec2613fa76bdebad3c00859fe09a98a30
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:57:23 2024 +0300
|
|
|
|
code: add sum of a,b
|
|
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 9e875c9..0400acb 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -6,7 +6,9 @@ int main()
|
|
cout << "Enter A and B: ";
|
|
int a, b;
|
|
cin >> a >> b;
|
|
- cout << "A + B = " << a + b << '\n';
|
|
+ cout << "A + B = " << a + b << '\n'
|
|
+ << "A - B = " << a - b << '\n';
|
|
+
|
|
|
|
return 0;
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git show main~1
|
|
commit 051a5a1ec2613fa76bdebad3c00859fe09a98a30
|
|
Author: Alice (AntonovDA) <AntonovDAn@mpei.ru>
|
|
Date: Sun Mar 24 14:57:23 2024 +0300
|
|
|
|
code: add sum of a,b
|
|
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 9e875c9..0400acb 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -6,7 +6,9 @@ int main()
|
|
cout << "Enter A and B: ";
|
|
int a, b;
|
|
cin >> a >> b;
|
|
- cout << "A + B = " << a + b << '\n';
|
|
+ cout << "A + B = " << a + b << '\n'
|
|
+ << "A - B = " << a - b << '\n';
|
|
+
|
|
|
|
return 0;
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff
|
|
diff --git a/.gitignore b/.gitignore
|
|
index 5a12c2a..a0a0033 100644
|
|
--- a/.gitignore
|
|
+++ b/.gitignore
|
|
@@ -1 +1,2 @@
|
|
-.exe
|
|
\ No newline at end of file
|
|
+.exe
|
|
+.dSYM/
|
|
\ No newline at end of file
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 0400acb..987e7c5 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -7,7 +7,8 @@ int main()
|
|
int a, b;
|
|
cin >> a >> b;
|
|
cout << "A + B = " << a + b << '\n'
|
|
- << "A - B = " << a - b << '\n';
|
|
+ << "A - B = " << a - b << '\n'
|
|
+ << "A * B = " << a * b ;
|
|
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff HEAD~2
|
|
diff --git a/.gitignore b/.gitignore
|
|
new file mode 100644
|
|
index 0000000..a0a0033
|
|
--- /dev/null
|
|
+++ b/.gitignore
|
|
@@ -0,0 +1,2 @@
|
|
+.exe
|
|
+.dSYM/
|
|
\ No newline at end of file
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 9e875c9..987e7c5 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -6,7 +6,10 @@ int main()
|
|
cout << "Enter A and B: ";
|
|
int a, b;
|
|
cin >> a >> b;
|
|
- cout << "A + B = " << a + b << '\n';
|
|
+ cout << "A + B = " << a + b << '\n'
|
|
+ << "A - B = " << a - b << '\n'
|
|
+ << "A * B = " << a * b ;
|
|
+
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff HEAD~2 HEAD
|
|
diff --git a/.gitignore b/.gitignore
|
|
new file mode 100644
|
|
index 0000000..5a12c2a
|
|
--- /dev/null
|
|
+++ b/.gitignore
|
|
@@ -0,0 +1 @@
|
|
+.exe
|
|
\ No newline at end of file
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 9e875c9..0400acb 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -6,7 +6,9 @@ int main()
|
|
cout << "Enter A and B: ";
|
|
int a, b;
|
|
cin >> a >> b;
|
|
- cout << "A + B = " << a + b << '\n';
|
|
+ cout << "A + B = " << a + b << '\n'
|
|
+ << "A - B = " << a - b << '\n';
|
|
+
|
|
|
|
return 0;
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff HEAD~1 HEAD
|
|
diff --git a/.gitignore b/.gitignore
|
|
new file mode 100644
|
|
index 0000000..5a12c2a
|
|
--- /dev/null
|
|
+++ b/.gitignore
|
|
@@ -0,0 +1 @@
|
|
+.exe
|
|
\ No newline at end of file
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff HEAD~1 HEAD~3
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 0400acb..e76b1a2 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -6,10 +6,4 @@ int main()
|
|
cout << "Enter A and B: ";
|
|
int a, b;
|
|
cin >> a >> b;
|
|
- cout << "A + B = " << a + b << '\n'
|
|
- << "A - B = " << a - b << '\n';
|
|
-
|
|
-
|
|
- return 0;
|
|
-
|
|
}
|
|
\ No newline at end of file
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -a -m "code: cout product'
|
|
dquote> "
|
|
[main 294564d] code: cout product'
|
|
2 files changed, 4 insertions(+), 2 deletions(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git status
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -a -m "code: cout product"
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commut -m " code: cout product"
|
|
git: 'commut' is not a git command. See 'git --help'.
|
|
|
|
The most similar command is
|
|
commit
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m " code: cout prouct"
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m " code: cout prouct"
|
|
|
|
On branch main
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git reset --hard HEAD~1
|
|
HEAD is now at ae9e215 git: ignoreted files
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout HEAD -- main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ssh-keygen
|
|
Generating public/private rsa key pair.
|
|
Enter file in which to save the key (/Users/dmitrijantonov/.ssh/id_rsa):
|
|
/Users/dmitrijantonov/.ssh/id_rsa already exists.
|
|
Overwrite (y/n)? y
|
|
Enter passphrase (empty for no passphrase):
|
|
Enter same passphrase again:
|
|
Passphrases do not match. Try again.
|
|
Enter passphrase (empty for no passphrase):
|
|
Enter same passphrase again:
|
|
Your identification has been saved in /Users/dmitrijantonov/.ssh/id_rsa
|
|
Your public key has been saved in /Users/dmitrijantonov/.ssh/id_rsa.pub
|
|
The key fingerprint is:
|
|
SHA256:D8bRn2Has25uBbojMbkCu5fgl+WVthPH8MCh65P6+OI dmitrijantonov@MacBook-Air-Dmitrij.local
|
|
The key's randomart image is:
|
|
+---[RSA 3072]----+
|
|
| |
|
|
| .. |
|
|
| .o..o |
|
|
| ...+=.o |
|
|
| So.B=. |
|
|
| o .*o* +o. |
|
|
| . + * B.=.. |
|
|
| o B.B =.o |
|
|
| .=E*oo *o |
|
|
+----[SHA256]-----+
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % eval $ (ssh-agent -s)
|
|
zsh: unknown file attribute: h
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % eval $(ssh-agent -s)
|
|
Agent pid 11202
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ssh-add
|
|
Enter passphrase for /Users/dmitrijantonov/.ssh/id_rsa:
|
|
Identity added: /Users/dmitrijantonov/.ssh/id_rsa (dmitrijantonov@MacBook-Air-Dmitrij.local)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cat ~/.ssh/id_ed25519.pub
|
|
cat: /Users/dmitrijantonov/.ssh/id_ed25519.pub: No such file or directory
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cat ~/.ssh/id_ed25519.pub
|
|
cat: /Users/dmitrijantonov/.ssh/id_ed25519.pub: No such file or directory
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ssh-add
|
|
Enter passphrase for /Users/dmitrijantonov/.ssh/id_rsa:
|
|
Identity added: /Users/dmitrijantonov/.ssh/id_rsa (dmitrijantonov@MacBook-Air-Dmitrij.local)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cat ~/.ssh/id_25519.pub
|
|
cat: /Users/dmitrijantonov/.ssh/id_25519.pub: No such file or directory
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cat ~/.ssh/id_rsa.pub
|
|
ssh-rsa
|
|
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDPxaVsyW3e2l1H9OeKsLDbnwAMsXdoHZKT/oCkQz2Y6l731yNQFqY5SO6FShPGPrXNDj5EpoNmb2XWK+dksaWsTNQOmkXbIlk8ld08jJdAFPpgm+IOEYT/mTGjzB912bkQnhvZrTIuYM7b33Y2VPdVLEK/W4hu1jZiHRZqGzdS0yX2pZFiDjso5jDHYXZNMMkjeGeWCo3dHEH176qJW2zxEiv47yvNJDbvWpGxlfzGYK9hjBBa6wF/BhmlZUA+kBvySOQTNTQaoduEozSnWm+0nx6+7yYZnxjIQ6hkO2DiYCCdhb18TM1uWOp9Gt8j7/kV8EO/9H7BNWjvE30HjjojZj1pCaOIf9kQFMxaviYOZYBCAS6lq7Qe0M15rc7o20os6drIe0Lo1txaXnemxBKrlt1rXMu+4gMuSruQiYWQvxuiYwYBoQ/CNCrfK7pcwmHKAdRuRRD/99yWrArkcUSUhCvKN3ygEPjZLmvDY3cpf+0I0rYaX1JKM57GfIeNv0U= dmitrijantonov@MacBook-Air-Dmitrij.local
|
|
zsh: command not found: ssh-rsa
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
ssh: connect to host uit.mpei.ru port 22: Operation timed out
|
|
fatal: Could not read from remote repository.
|
|
|
|
Please make sure you have the correct access rights
|
|
and the repository exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
^[[B^[[Dssh: connect to host uit.mpei.ru port 22: Operation timed out
|
|
fatal: Could not read from remote repository.
|
|
|
|
Please make sure you have the correct access rights
|
|
and the repository exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
|
|
q
|
|
q
|
|
q
|
|
q
|
|
q
|
|
q
|
|
q
|
|
q
|
|
qcc
|
|
git push -u origin main
|
|
git push -u origin main
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
pa[fldv
|
|
stop
|
|
dd
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.gitgit remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:Assh: connect to host uit.mpei.ru port 22: Operation timed out
|
|
fatal: Could not read from remote repository.
|
|
|
|
Please make sure you have the correct access rights
|
|
and the repository exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project %
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % q
|
|
zsh: command not found: q
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % qcc
|
|
zsh: command not found: qcc
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
git push -u origin main
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
pa[fldv
|
|
stop
|
|
dd
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.gitgit remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab002.git
|
|
git remote add origin git@uit.mpei.ru:AntonovDAn/cs-
|
|
git remote add origin
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/////Last login: Sun Mar 24 16:22:56 on ttys000
|
|
dmitrijantonov@MacBook-Air-Dmitrij ~ % cd desktop
|
|
dmitrijantonov@MacBook-Air-Dmitrij desktop % cd lab02
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab02.gigit remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab2.gitt
|
|
usage: git remote add [<options>] <name> <url>
|
|
|
|
-f, --fetch fetch the remote branches
|
|
--tags import all tags and associated objects when fetching
|
|
or do not fetch any tag at all (--no-tags)
|
|
-t, --track <branch> branch(es) to track
|
|
-m, --master <branch>
|
|
master branch
|
|
--mirror[=(push|fetch)]
|
|
set up remote as a mirror to push to or fetch from
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main2
|
|
error: src refspec main2 does not match any
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin git@uit.mpei.ru:AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main2
|
|
error: src refspec main2 does not match any
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main2
|
|
error: src refspec main2 does not match any
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main2
|
|
error: src refspec main2 does not match any
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin mainw
|
|
error: src refspec mainw does not match any
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main2
|
|
error: src refspec main2 does not match any
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
Enumerating objects: 17, done.
|
|
Counting objects: 100% (17/17), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (15/15), done.
|
|
Writing objects: 100% (17/17), 1.74 KiB | 445.00 KiB/s, done.
|
|
Total 17 (delta 2), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
* [new branch] main -> main
|
|
branch 'main' set up to track 'origin/main'.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote -v
|
|
origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git (fetch)
|
|
origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git (push)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git clone
|
|
fatal: You must specify a repository to clone.
|
|
|
|
usage: git clone [<options>] [--] <repo> [<dir>]
|
|
|
|
-v, --verbose be more verbose
|
|
-q, --quiet be more quiet
|
|
--progress force progress reporting
|
|
--reject-shallow don't clone shallow repository
|
|
-n, --no-checkout don't create a checkout
|
|
--bare create a bare repository
|
|
--mirror create a mirror repository (implies bare)
|
|
-l, --local to clone from a local repository
|
|
--no-hardlinks don't use local hardlinks, always copy
|
|
-s, --shared setup as shared repository
|
|
--recurse-submodules[=<pathspec>]
|
|
initialize submodules in the clone
|
|
--recursive ... alias of --recurse-submodules
|
|
-j, --jobs <n> number of submodules cloned in parallel
|
|
--template <template-directory>
|
|
directory from which templates will be used
|
|
--reference <repo> reference repository
|
|
--reference-if-able <repo>
|
|
reference repository
|
|
--dissociate use --reference only while cloning
|
|
-o, --origin <name> use <name> instead of 'origin' to track upstream
|
|
-b, --branch <branch>
|
|
checkout <branch> instead of the remote's HEAD
|
|
-u, --upload-pack <path>
|
|
path to git-upload-pack on the remote
|
|
--depth <depth> create a shallow clone of that depth
|
|
--shallow-since <time>
|
|
create a shallow clone since a specific time
|
|
--shallow-exclude <revision>
|
|
deepen history of shallow clone, excluding rev
|
|
--single-branch clone only one branch, HEAD or --branch
|
|
--no-tags don't clone any tags, and make later fetches not to follow them
|
|
--shallow-submodules any cloned submodules will be shallow
|
|
--separate-git-dir <gitdir>
|
|
separate git dir from working tree
|
|
-c, --config <key=value>
|
|
set config inside the new repository
|
|
--server-option <server-specific>
|
|
option to transmit
|
|
-4, --ipv4 use IPv4 addresses only
|
|
-6, --ipv6 use IPv6 addresses only
|
|
--filter <args> object filtering
|
|
--also-filter-submodules
|
|
apply partial clone filters to submodules
|
|
--remote-submodules any cloned submodules will use their remote-tracking branch
|
|
--sparse initialize sparse-checkout file to include only files at root
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % git clone http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git project
|
|
Cloning into 'project'...
|
|
remote: Enumerating objects: 17, done.
|
|
remote: Counting objects: 100% (17/17), done.
|
|
remote: Compressing objects: 100% (15/15), done.
|
|
remote: Total 17 (delta 2), reused 0 (delta 0), pack-reused 0
|
|
Receiving objects: 100% (17/17), done.
|
|
Resolving deltas: 100% (2/2), done.
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git config user.name 'Bob (AntonovDA)'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git config user.email 'AntonovDAn@mpei.ru'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m 'code: óìíîæåíèå'
|
|
On branch main
|
|
Your branch is up to date with 'origin/main'.
|
|
|
|
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: main2.cpp
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
|
|
no changes added to commit (use "git add" and/or "git commit -a")
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 0400acb..987e7c5 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -7,7 +7,8 @@ int main()
|
|
int a, b;
|
|
cin >> a >> b;
|
|
cout << "A + B = " << a + b << '\n'
|
|
- << "A - B = " << a - b << '\n';
|
|
+ << "A - B = " << a - b << '\n'
|
|
+ << "A * B = " << a * b ;
|
|
|
|
|
|
return 0;
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git diff HEAD~2
|
|
diff --git a/.gitignore b/.gitignore
|
|
new file mode 100644
|
|
index 0000000..5a12c2a
|
|
--- /dev/null
|
|
+++ b/.gitignore
|
|
@@ -0,0 +1 @@
|
|
+.exe
|
|
\ No newline at end of file
|
|
diff --git a/main2.cpp b/main2.cpp
|
|
index 9e875c9..987e7c5 100644
|
|
--- a/main2.cpp
|
|
+++ b/main2.cpp
|
|
@@ -6,7 +6,10 @@ int main()
|
|
cout << "Enter A and B: ";
|
|
int a, b;
|
|
cin >> a >> b;
|
|
- cout << "A + B = " << a + b << '\n';
|
|
+ cout << "A + B = " << a + b << '\n'
|
|
+ << "A - B = " << a - b << '\n'
|
|
+ << "A * B = " << a * b ;
|
|
+
|
|
|
|
return 0;
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % ls
|
|
main2.cpp project.cbp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd..
|
|
zsh: command not found: cd..
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "code: óìíîæåíèå"
|
|
[main 1b53cb5] code: óìíîæåíèå
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Enumerating objects: 5, done.
|
|
Counting objects: 100% (5/5), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (3/3), done.
|
|
Writing objects: 100% (3/3), 401 bytes | 401.00 KiB/s, done.
|
|
Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
ae9e215..1b53cb5 main -> main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
remote: Enumerating objects: 5, done.
|
|
remote: Counting objects: 100% (5/5), done.
|
|
remote: Compressing objects: 100% (3/3), done.
|
|
remote: Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
Unpacking objects: 100% (3/3), 381 bytes | 127.00 KiB/s, done.
|
|
From http://uit.mpei.ru/git/AntonovDAn/cs-lab2
|
|
ae9e215..1b53cb5 main -> origin/main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* 1b53cb5 (origin/main) code: óìíîæåíèå
|
|
* ae9e215 (HEAD -> main) git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git pull --ff-only
|
|
Updating ae9e215..1b53cb5
|
|
Fast-forward
|
|
main2.cpp | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "code: äåëåíèå"
|
|
[main 7e0afec] code: äåëåíèå
|
|
1 file changed, 2 insertions(+), 3 deletions(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Enumerating objects: 5, done.
|
|
Counting objects: 100% (5/5), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (3/3), done.
|
|
Writing objects: 100% (3/3), 400 bytes | 400.00 KiB/s, done.
|
|
Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
1b53cb5..7e0afec main -> main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
remote: Enumerating objects: 5, done.
|
|
remote: Counting objects: 100% (5/5), done.
|
|
remote: Compressing objects: 100% (3/3), done.
|
|
remote: Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
Unpacking objects: 100% (3/3), 380 bytes | 76.00 KiB/s, done.
|
|
From http://uit.mpei.ru/git/AntonovDAn/cs-lab2
|
|
1b53cb5..7e0afec main -> origin/main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* 7e0afec (origin/main, origin/HEAD) code: äåëåíèå
|
|
* 1b53cb5 (HEAD -> main) code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git pull --ff-only
|
|
Updating 1b53cb5..7e0afec
|
|
Fast-forward
|
|
main2.cpp | 5 ++---
|
|
1 file changed, 2 insertions(+), 3 deletions(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "code: ìàêñ ÷èñëî"
|
|
[main 9f3601a] code: ìàêñ ÷èñëî
|
|
1 file changed, 8 insertions(+)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Enumerating objects: 5, done.
|
|
Counting objects: 100% (5/5), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (3/3), done.
|
|
Writing objects: 100% (3/3), 447 bytes | 447.00 KiB/s, done.
|
|
Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
7e0afec..9f3601a main -> main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "code: ìèí ÷èñëî"
|
|
[main eeecda7] code: ìèí ÷èñëî
|
|
1 file changed, 8 insertions(+)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
! [rejected] main -> main (fetch first)
|
|
error: failed to push some refs to 'http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
hint: Updates were rejected because the remote contains work that you do
|
|
hint: not have locally. This is usually caused by another repository pushing
|
|
hint: to the same ref. You may want to first integrate the remote changes
|
|
hint: (e.g., 'git pull ...') before pushing again.
|
|
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
remote: Enumerating objects: 5, done.
|
|
remote: Counting objects: 100% (5/5), done.
|
|
remote: Compressing objects: 100% (3/3), done.
|
|
remote: Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
Unpacking objects: 100% (3/3), 427 bytes | 85.00 KiB/s, done.
|
|
From http://uit.mpei.ru/git/AntonovDAn/cs-lab2
|
|
7e0afec..9f3601a main -> origin/main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* eeecda7 (HEAD -> main) code: ìèí ÷èñëî
|
|
| * 9f3601a (origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
|/
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase origin/main
|
|
Auto-merging main2.cpp
|
|
CONFLICT (content): Merge conflict in main2.cpp
|
|
error: could not apply eeecda7... code: ìèí ÷èñëî
|
|
hint: Resolve all conflicts manually, mark them as resolved with
|
|
hint: "git add/rm <conflicted_files>", then run "git rebase --continue".
|
|
hint: You can instead skip this commit: run "git rebase --skip".
|
|
hint: To abort and get back to the state before "git rebase", run "git rebase --abort".
|
|
Could not apply eeecda7... code: ìèí ÷èñëî
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --continue
|
|
hint: Waiting for your editor to close the file... error: There was a problem with the editor 'vi'.
|
|
Please supply the message using either -m or -F option.
|
|
error: could not commit staged changes.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* eeecda7 (main) code: ìèí ÷èñëî
|
|
| * 9f3601a (HEAD, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
|/
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
fatal: You are not currently on a branch.
|
|
To push the history leading to the current (detached HEAD)
|
|
state now, use
|
|
|
|
git push origin HEAD:<name-of-remote-branch>
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
fatal: You are not currently on a branch.
|
|
To push the history leading to the current (detached HEAD)
|
|
state now, use
|
|
|
|
git push origin HEAD:<name-of-remote-branch>
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push origin HEAD:http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
fatal: invalid refspec 'HEAD:http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push main2.cpp
|
|
fatal: You are not currently on a branch.
|
|
To push the history leading to the current (detached HEAD)
|
|
state now, use
|
|
|
|
git push main2.cpp HEAD:<name-of-remote-branch>
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push HEAD: main2.cpp
|
|
error: src refspec main2.cpp does not match any
|
|
error: failed to push some refs to 'HEAD:'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --continue
|
|
hint: Waiting for your editor to close the file...
|
|
Last login: Sun Mar 24 17:39:52 on ttys013
|
|
dmitrijantonov@MacBook-Air-Dmitrij ~ % cd desktop
|
|
dmitrijantonov@MacBook-Air-Dmitrij desktop % cd lab02
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* eeecda7 (main) code: ìèí ÷èñëî
|
|
| * 9f3601a (HEAD, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
|/
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase origin/main
|
|
fatal: It seems that there is already a rebase-merge directory, and
|
|
I wonder if you are in the middle of another rebase. If that is the
|
|
case, please try
|
|
git rebase (--continue | --abort | --skip)
|
|
If that is not the case, please
|
|
rm -fr ".git/rebase-merge"
|
|
and run me again. I am stopping in case you still have something
|
|
valuable there.
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --skip
|
|
Successfully rebased and updated refs/heads/main.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* 9f3601a (HEAD -> main, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git pull --ff-only
|
|
Already up to date.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
branch 'main' set up to track 'origin/main'.
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project %
|
|
Last login: Sun Mar 24 17:39:52 on ttys013
|
|
dmitrijantonov@MacBook-Air-Dmitrij ~ % cd desktop
|
|
dmitrijantonov@MacBook-Air-Dmitrij desktop % cd lab02
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* eeecda7 (main) code: ìèí ÷èñëî
|
|
| * 9f3601a (HEAD, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
|/
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase origin/main
|
|
fatal: It seems that there is already a rebase-merge directory, and
|
|
I wonder if you are in the middle of another rebase. If that is the
|
|
case, please try
|
|
git rebase (--continue | --abort | --skip)
|
|
If that is not the case, please
|
|
rm -fr ".git/rebase-merge"
|
|
and run me again. I am stopping in case you still have something
|
|
valuable there.
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --skip
|
|
Successfully rebased and updated refs/heads/main.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* 9f3601a (HEAD -> main, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git pull --ff-only
|
|
Already up to date.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
branch 'main' set up to track 'origin/main'.
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --skip
|
|
fatal: No rebase in progress?
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase origin/main
|
|
error: cannot rebase: Your index contains uncommitted changes.
|
|
error: Please commit or stash them.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -a -m "code: after rebase"
|
|
[main 571e6ae] code: after rebase
|
|
1 file changed, 8 insertions(+)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Enumerating objects: 5, done.
|
|
Counting objects: 100% (5/5), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (3/3), done.
|
|
Writing objects: 100% (3/3), 389 bytes | 389.00 KiB/s, done.
|
|
Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
9f3601a..571e6ae main -> main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project %
|
|
Last login: Sun Mar 24 17:39:52 on ttys013
|
|
dmitrijantonov@MacBook-Air-Dmitrij ~ % cd desktop
|
|
dmitrijantonov@MacBook-Air-Dmitrij desktop % cd lab02
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* eeecda7 (main) code: ìèí ÷èñëî
|
|
| * 9f3601a (HEAD, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
|/
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase origin/main
|
|
fatal: It seems that there is already a rebase-merge directory, and
|
|
I wonder if you are in the middle of another rebase. If that is the
|
|
case, please try
|
|
git rebase (--continue | --abort | --skip)
|
|
If that is not the case, please
|
|
rm -fr ".git/rebase-merge"
|
|
and run me again. I am stopping in case you still have something
|
|
valuable there.
|
|
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --skip
|
|
Successfully rebased and updated refs/heads/main.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* 9f3601a (HEAD -> main, origin/main, origin/HEAD) code: ìàêñ ÷èñëî
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git pull --ff-only
|
|
Already up to date.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote set-url origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote add origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
error: remote origin already exists.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push -u origin main
|
|
branch 'main' set up to track 'origin/main'.
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add main2.cpp
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase --skip
|
|
fatal: No rebase in progress?
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git rebase origin/main
|
|
error: cannot rebase: Your index contains uncommitted changes.
|
|
error: Please commit or stash them.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -a -m "code: after rebase"
|
|
[main 571e6ae] code: after rebase
|
|
1 file changed, 8 insertions(+)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Enumerating objects: 5, done.
|
|
Counting objects: 100% (5/5), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (3/3), done.
|
|
Writing objects: 100% (3/3), 389 bytes | 389.00 KiB/s, done.
|
|
Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
9f3601a..571e6ae main -> main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git branch double
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git chechout double
|
|
git: 'chechout' is not a git command. See 'git --help'.
|
|
|
|
The most similar command is
|
|
checkout
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout double
|
|
M main2.cpp
|
|
Switched to branch 'double'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "changes: int~double"
|
|
[double 3b6d97f] changes: int~double
|
|
1 file changed, 5 insertions(+), 4 deletions(-)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout main
|
|
Switched to branch 'main'
|
|
Your branch is up to date with 'origin/main'.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
remote: Enumerating objects: 5, done.
|
|
remote: Counting objects: 100% (5/5), done.
|
|
remote: Compressing objects: 100% (3/3), done.
|
|
remote: Total 3 (delta 1), reused 0 (delta 0), pack-reused 0
|
|
Unpacking objects: 100% (3/3), 369 bytes | 92.00 KiB/s, done.
|
|
From http://uit.mpei.ru/git/AntonovDAn/cs-lab2
|
|
9f3601a..571e6ae main -> origin/main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git remote -v
|
|
origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git (fetch)
|
|
origin http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git (push)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git clone http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git project
|
|
Cloning into 'project'...
|
|
remote: Enumerating objects: 29, done.
|
|
remote: Counting objects: 100% (29/29), done.
|
|
remote: Compressing objects: 100% (27/27), done.
|
|
remote: Total 29 (delta 6), reused 0 (delta 0), pack-reused 0
|
|
Receiving objects: 100% (29/29), done.
|
|
Resolving deltas: 100% (6/6), done.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* 3b6d97f (double) changes: int~double
|
|
| * 571e6ae (origin/main) code: after rebase
|
|
|/
|
|
* 9f3601a (HEAD -> main) code: ìàêñ ÷èñëî
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git pull --ff-only
|
|
Updating 9f3601a..571e6ae
|
|
Fast-forward
|
|
main2.cpp | 8 ++++++++
|
|
1 file changed, 8 insertions(+)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd bob
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "..."
|
|
On branch main
|
|
Your branch is up to date with 'origin/main'.
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij bob % cd ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git clone http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git project
|
|
fatal: destination path 'project' already exists and is not an empty directory.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "."
|
|
On branch main
|
|
Your branch is up to date with 'origin/main'.
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
project/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git merge double
|
|
Auto-merging main2.cpp
|
|
CONFLICT (content): Merge conflict in main2.cpp
|
|
Automatic merge failed; fix conflicts and then commit the result.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git merge double
|
|
error: Merging is not possible because you have unmerged files.
|
|
hint: Fix them up in the work tree, and then use 'git add/rm <file>'
|
|
hint: as appropriate to mark resolution and make a commit.
|
|
fatal: Exiting because of an unresolved conflict.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout doible
|
|
error: pathspec 'doible' did not match any file(s) known to git
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout double
|
|
main2.cpp: needs merge
|
|
error: you need to resolve your current index first
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout double
|
|
error: Your local changes to the following files would be overwritten by checkout:
|
|
main2.cpp
|
|
Please commit your changes or stash them before you switch branches.
|
|
Aborting
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -u
|
|
hint: Waiting for your editor to close the file...
|
|
Merge branch 'double'
|
|
|
|
# Conflicts:
|
|
# main2.cpp
|
|
#
|
|
# It looks like you may be committing a merge.
|
|
# If this is not correct, please run
|
|
# git update-ref -d MERGE_HEAD
|
|
# and try again.
|
|
|
|
|
|
# Please enter the commit message for your changes. Lines starting
|
|
# with '#' will be ignored, and an empty message aborts the commit.
|
|
#
|
|
# On branch main
|
|
# Your branch is up to date with 'origin/main'.
|
|
#
|
|
# All conflicts fixed but you are still merging.
|
|
#
|
|
# Changes to be committed:
|
|
# modified: main2.cpp
|
|
#
|
|
# Untracked files:
|
|
|
|
Last login: Sun Mar 24 19:03:00 on ttys000
|
|
dmitrijantonov@MacBook-Air-Dmitrij ~ % cd desktop
|
|
dmitrijantonov@MacBook-Air-Dmitrij desktop % cd lab02
|
|
dmitrijantonov@MacBook-Air-Dmitrij lab02 % cd alice
|
|
dmitrijantonov@MacBook-Air-Dmitrij alice % cd project
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git branch double
|
|
fatal: a branch named 'double' already exists
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout double
|
|
error: Your local changes to the following files would be overwritten by checkout:
|
|
main2.cpp
|
|
Please commit your changes or stash them before you switch branches.
|
|
Aborting
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout double
|
|
error: Your local changes to the following files would be overwritten by checkout:
|
|
main2.cpp
|
|
Please commit your changes or stash them before you switch branches.
|
|
Aborting
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -a -m ".."
|
|
[main e95cd44] ..
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout double
|
|
Switched to branch 'double'
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git checkout main
|
|
Switched to branch 'main'
|
|
Your branch is ahead of 'origin/main' by 2 commits.
|
|
(use "git push" to publish your local commits)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git fetch
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* e95cd44 (HEAD -> main) ..
|
|
|\
|
|
| * 3b6d97f (double) changes: int~double
|
|
* | 571e6ae (origin/main) code: after rebase
|
|
|/
|
|
* 9f3601a code: ìàêñ ÷èñëî
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git merge double
|
|
Already up to date.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Enumerating objects: 10, done.
|
|
Counting objects: 100% (10/10), done.
|
|
Delta compression using up to 4 threads
|
|
Compressing objects: 100% (6/6), done.
|
|
Writing objects: 100% (6/6), 698 bytes | 698.00 KiB/s, done.
|
|
Total 6 (delta 2), reused 0 (delta 0), pack-reused 0
|
|
remote: . Processing 1 references
|
|
remote: Processed 1 references in total
|
|
To http://uit.mpei.ru/git/AntonovDAn/cs-lab2.git
|
|
571e6ae..e95cd44 main -> main
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git add -u
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git commit -m "code: merge commit"
|
|
On branch main
|
|
Your branch is up to date with 'origin/main'.
|
|
|
|
Untracked files:
|
|
(use "git add <file>..." to include in what will be committed)
|
|
.DS_Store
|
|
main2
|
|
main2.dSYM/
|
|
project/
|
|
|
|
nothing added to commit but untracked files present (use "git add" to track)
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git push
|
|
Everything up-to-date
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git merge duble
|
|
merge: duble - not something we can merge
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git merge double
|
|
Already up to date.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % git log --oneline --decorate --all --graph
|
|
* e95cd44 (HEAD -> main, origin/main) ..
|
|
|\
|
|
| * 3b6d97f (double) changes: int~double
|
|
* | 571e6ae code: after rebase
|
|
|/
|
|
* 9f3601a code: ìàêñ ÷èñëî
|
|
* 7e0afec code: äåëåíèå
|
|
* 1b53cb5 code: óìíîæåíèå
|
|
* ae9e215 git: ignoreted files
|
|
* 051a5a1 code: add sum of a,b
|
|
* 6d4ba94 ...
|
|
* 9f6cd71 ...
|
|
* bad78bc build: add projecct file
|
|
* 9896924 code: çàãîòîâêà ïðîãðàììû
|
|
dmitrijantonov@MacBook-Air-Dmitrij project % EDITOR=nano git merge double
|
|
Already up to date.
|
|
dmitrijantonov@MacBook-Air-Dmitrij project %
|
|
|