File: BASICSGIT.TXT

package info (click to toggle)
gmtsar 6.5%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 17,072 kB
  • sloc: ansic: 36,233; csh: 10,720; sh: 3,413; xml: 1,764; makefile: 1,075; perl: 725; python: 145
file content (51 lines) | stat: -rw-r--r-- 1,234 bytes parent folder | download | duplicates (2)
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
#
#  clone the master or a branch
#
#  Github will soon start two-factor authentification for use from a terminal. 
#  After setting up 2FA, the old username/passward will fail when you run git push, etc.
#  Then you have to set up a token on your github_account/Settings/Developer_Settings/Personal_access_tokens
#  After setting the token, save it, then use that as the password when running git push, etc.
#
cd /usr/local
git clone https://github.com/gmtsar/gmtsar GMTSAR_master
#
git clone --branch 5.7 https://github.com/gmtsar/gmtsar GMTSAR_5.7
#
#  update your repository before making any changes
#
git pull
#
#   make changes to an existing repository 
#
cd /usr/local/gmtsar
vi README.md
git add README.md
git commit -m"changed README.md file"
git push 
#
#  delete a file from an existing repository
#
git rm BASICSVN.txt
git commit -m"removed the SVN instructions"
git push 
#
#  clone a repository from GMT6
#
cd /usr/local
sudo mkdir gmt
sudo chown -r sandwell gmt
git clone https://github.com/GenericMappingTools/gmt
#
# switch to a specific branch
#
git checkout 5.7
#
# show current branches
#
git branch
# undo the committed
git revert
# create a new branch
git checkout -b fix_bugs
# show current status
git status