forked from rrrgh/exercise
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gtcmd
70 lines (49 loc) · 1.62 KB
/
gtcmd
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
69
~/.oh-my-zsh/plugins/git/git.plugin.zsh
git config -l | grep proxy
#git add <filename>
#git commit -m "Commit message"
#git push origin master
touch README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/dmbwkslwltstrtr/dmbprmtv.git
git push -u origin master
…or push an existing repository from the command line
git remote add origin https://github.com/dmbwkslwltstrtr/dmbprmtv.git
git push -u origin master
GIT_ASKPASS
If this environment variable is set, then Git commands which need to acquire passwords or passphrases (e.g. for HTTP or IMAP
authentication) will call this program with a suitable prompt as command-line argument and read the password from its STDOUT. See also
the core.askpass option in git-config(1).
unset SSH_ASKPASS
echo $SSH_ASKPASS
$HOME/.gitconfig
git config -l
git config remote.origin.url https://rrrv@github.com/rrrv/exercise.git
gitconfig sample example
git clone from bitbucket.org is not working by https
#diff
#diff file in local and remote repo
git diff origin/master -- <file>
#accidentally deleted
git checkout -- strt.sh
#git empty file bad file descriptor
git fsck --full
git hash-object -w <file>
git gc --aggressive --prune=now
#.gitignore
git config --global core.excludesfile /mnt/0/.gitignore_global
#add new/modified/deleted files in the current directory
ga -A .
git checkout -b newbranch
git remote -v
#git branch
git merge master
git add -A
git commit
git push --set-upstream origin newbranch
git show --pretty=fuller
git log -S<search_str> --pretty=oneline --abbrev-commit <file>
git diff --cached
gitk