0
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-09-19 04:01:21 +02:00
Commit graph

263 commits

Author SHA1 Message Date
Marc Cornellà
4ad4a81657 git: clean up plugin file and delete current_repository function
Closes #6329
2019-05-21 11:04:01 +02:00
Marc Cornellà
f8d5fdce3a git: move documentation from wiki to README 2019-05-21 11:04:01 +02:00
Marc Cornellà
7824dc637d
git: use is-at-least to test for git version
Fixes #7754
2019-04-10 11:47:29 +02:00
Marc Cornellà
b31106b341
git: minor syntax fix 2019-04-09 18:35:09 +02:00
Marc Cornellà
35dc26a2c0
git: use stash 'push' instead of the deprecated 'save' (#7486)
* Use stash 'push' or 'save' depending on Git version

A utility function now parses the output of git --version and set the
alias for git stash to 'git stash push' iff the current version of Git
is 2.13 or greater; it falls back to 'git stash save' otherwise.
2019-04-09 18:33:15 +02:00
Marc Cornellà
1bd72f588c
Update to inline conditional syntax 2019-04-09 18:29:18 +02:00
Asatur Meltonyan
046d49f782 git: add 'gtl' alias to list tags matching a pattern (#7629)
1. List the tags that match the pattern(s) passed through the argument.
2. Displays the first line of the annotation message along with the tag, or the line of the first commit message if the tag is not annotated.
3. Sorts and displays tags in descending order.
2019-04-07 14:17:22 +02:00
Marc Cornellà
831fba4ee4
Revert "git: delete branches in gbda only if there are any (#6079)" (#7724)
This reverts commit 0e0789fb7a.
2019-04-02 19:05:52 +02:00
Marc Cornellà
93cbc1614c
git: use interactive mode in gclean
Fixes #7716
2019-03-31 15:56:35 +02:00
Simen Bekkhus
4b82b86064 git: add --no-gpg-sign to gwip (#6031) 2019-03-29 22:59:37 +01:00
Jakub Chábek
0e0789fb7a git: delete branches in gbda only if there are any (#6079)
It doesn't make sense to run `git branch -d $BRANCH` if the `$BRANCH` is empty.
2019-03-29 22:56:59 +01:00
Marc Cornellà
f6a9a0a498
git: fix grt on path with spaces
Fixes #7682
2019-03-25 18:46:18 +01:00
Tieme van Veen
9509fd6a91 Add git reset to origin alias to git plugin (#7630) 2019-03-10 09:38:06 -07:00
Bartlomiej Tartanus
932d611c90 git: properly indent ggfl function (#7556)
Fixes (probably MacOS) issue:
> ggfl
zsh: command not found: ggfl
2019-01-30 16:22:14 +01:00
Gianluca Recchia
308b046875
Use stash 'push' or 'save' depending on Git version
A utility function now parses the output of git --version and set the
alias for git stash to 'git stash push' iff the current version of Git
is greater than 2.13; it falls back to 'git stash save' otherwise.
2019-01-29 04:11:02 +01:00
neeasade
3c16466a14 git: quote branch name in ggpull and ggpush (#7472) 2019-01-20 20:19:07 +01:00
Max Gautier
509a554900 git: use color auto for ref names in git log (#5729)
Allow the ref names to have differents colors if they are remote refs
or local refs, and another color for HEAD
(use the same coloring scheme as --decorate option)
2018-09-12 19:35:10 +02:00
Luis Ferrer-Labarca
5ee93f4f15 git: add git rm aliases (#5433)
* grm for 'git rm'
* grmc for 'git rm --cached'
2018-09-12 19:08:12 +02:00
Yago Nobre
0db7da0cd5 git: add push force aliases (#6297)
* gpf to --force-with-lease
* gpf! to --force
2018-09-12 19:05:57 +02:00
Simen Bekkhus
a3afeca3eb git: add gbD alias to force-delete branch (#5844) 2018-09-12 18:38:21 +02:00
Jefferson F. Pires
d5f0a0a413 git: add glols alias for glol --stat (#5871) 2018-09-12 16:57:48 +02:00
Gant Laborde
69ba6e4359 git: add alias to git stash --all (#5511)
Stash tracked, ignored and untracked files. Leaves the working directory absolutely clean.
2018-09-12 16:28:59 +02:00
Poyoman
3d2542f41b git: add pull rebase --autostash aliases (#6791) 2018-09-12 15:52:42 +02:00
Kris Kalavantavanich
e93378aacd [plugins/git] Updated git clone alias (#6893)
* Updated git clone alias

`git clone --recursive` has been deprecated in favor of `--recurse-submodules`.  
See: https://stackoverflow.com/questions/3796927
2018-08-29 15:18:20 +02:00
Joel Wallis Jucá
652356b9b9 git: add the git show alias gsh (#5591) 2018-08-23 22:04:42 +02:00
Peter Bittner
035d78120c Add Git alias for git diff --staged (#7064) 2018-08-15 19:44:06 +02:00
Tushar Tiwari
1691cf8a99 Add alias for git add --verbose (#3167)
Add alias `gav='git add -v'`
fixes #6793
2018-08-13 21:11:25 +02:00
Michal Juriš
b6ca933a02 Add alias for 'git rebase develop' (#6006) 2018-06-30 22:25:53 +02:00
Matteo Giaccone
0808c0f6ef Remove default for git reset (#4993)
The command will do the same as before, but now you can also specify
a path.

Example:
grh branch-name
grhh tag-name
2018-06-12 18:23:31 +02:00
Chuan Jin
2642f0a8b4 Add git log with date (#6789) 2018-05-20 16:02:53 -07:00
George Kaklamanos
acacfec924 Remove unneeded option in glol and glola (#6059) 2018-04-25 14:14:33 +02:00
Mahmoud Hossam
ed85147e6e Rename clashing ag alias (#5849)
* Fix ubuntu ag alias clashing with the silver searcher

* Add aliases for git apply and git merge --abort
2017-11-07 08:06:41 -08:00
Jonathan Channon
5486aa21eb Added --force-with-lease method (#5025) 2017-11-07 08:06:19 -08:00
Tomas Chmelevskij
1700c948b4 Add chaced word diff (#6378) 2017-11-01 05:55:19 -07:00
Felipe Guilherme
456341fd69 Add git alias for staging tracked files (#5178)
Although `gaa` (git add --all) is cool, it stages every file, tracked or
not, if it is not on .gitignore.

Sometimes we want to just stage everything we are working on, that is
already tracked. For that reason, 'gau' can save us some time.
2016-12-17 18:01:13 +01:00
Jason Kurian
3477ff2527 feat: no CI on WIP commits (#5643) 2016-11-16 10:42:46 +01:00
Marc Cornellà
7f9b773350 Fix compdef commands in git plugin
The command `compdef command=git` returns an error in some cases, the
appropriate command is `compdef _git command`.

Fixes #5442
2016-10-04 17:23:20 +02:00
savimat
6d975f7258 Add alias for signed git commit with message (#5390)
Signed-off-by: Mat Munn <mat@savi.com.au>
2016-10-03 01:11:26 +02:00
Allan Lewis
c713407f90 git.plugin.zsh: Don't run Git hooks when making a WIP commit (#4751)
When making a WIP commit, we generally just want to save the state of the
current branch temporarily, maybe because we want to push our work for backup
purposes, or change branch to work on something else. Therefore, it's generally
undesirable to run Git hooks, which might do things like run linters, because
we probably don't care if our WIP has lint errors.
2016-09-30 13:45:28 +02:00
Luis Ferrer-Labarca
e9793fc199 Added 'gbd' alias for 'git branch -d' (#5417) 2016-09-19 19:50:16 -07:00
Marc Cornellà
298b63513d git plugin: remove `format:' from --pretty flag
Changes gke, glol and glola aliases.

Fixes #5362
2016-09-05 10:56:18 +02:00
Simon
b9c3e862c7 Add alias for checking out develop branch (#5307) 2016-08-21 19:46:37 +02:00
Marc Cornellà
76821f506c Rename gh alias (git help) to ghh
This conflicts with several tools, including NodeGH [1] and
scm_breeze [2].

[1] https://github.com/robbyrussell/oh-my-zsh/issues/5313
[2] https://github.com/robbyrussell/oh-my-zsh/issues/5321

Related: #5130
2016-08-20 23:53:12 +02:00
Emmanuel Isaac
9981214437 Add git alias to clear entire stash (#5306)
Using the "gstc" alias runs "git stash clear"
that clears every stash index
2016-08-18 09:22:21 +02:00
Dzianis Dashkevich
95371afdd8 Add gcpa and gcpc aliases to git plugin (#5271) 2016-08-14 17:58:11 -07:00
Robby Russell
b96a5877aa #5130 resolving conflict in git plugin for gh 2016-08-14 17:39:27 -07:00
Simen Bekkhus
ae21102030 (git): Add gpsup alias (#5287) 2016-08-11 02:47:54 +02:00
Marc Cornellà
7654b16b39 [git plugin] Fix indentation and organise aliases 2016-08-07 18:30:57 +02:00
Cédric Malard
f5537241a4 Fix gbda alias to support color.ui = always + exclude dev branches (#4304)
* Fix gbda alias to support git config color.ui = always
* Update gbda alias to exclude develop and dev branches
2016-08-01 18:16:54 +02:00
Marc Cornellà
c62442f999 Fix gfg function completion definition
Related: #5179
2016-06-21 01:06:21 +02:00
wangzengdi
5fa4d9d760 add alias gh=git help 2016-05-31 09:57:36 +08:00
Wasif Hasan Baig
bdc82114d0 Changd alias gsta='git stash' to alias gsta='git stash save'. 2016-05-26 10:26:01 -07:00
Ivan Mironov
d2712d3180 Add alias for oneline git tree with --all option 2016-05-18 12:28:36 +03:00
Wanbok Choi
615af65087 Add 'gcn!' for the '--no-edit' option. (#4830)
Remove the '-s' option from 'gcan!'
Add 'gcans!'. It is the same as the current 'gcan! -s'.
2016-05-14 13:45:55 +02:00
Marc Cornellà
b4a85eca9d Merge pull request #4728 from atk91/4727
Remove --color flag from git log aliases

The way to colorize `git log` output is by setting the `color.ui` configuration.
2016-03-30 04:46:22 +02:00
Filippo Valsorda
52737b1828 git.plugin: remove the conflicting gvt alias
See FiloSottile/gvt#19 and FiloSottile/gvt#4
2016-02-10 18:31:49 +00:00
atk91
d853ec4b62 Closes #4727 2015-12-25 11:33:29 +03:00
Andrew Janke
9f552130bd Move current_branch() from git plugin to core lib/git.zsh
Fixes #4085: core -> plugin dependency issue.
Rename it to git_current_branch for clarity that it's git-specific.
Update all plugins that were calling it to use new name.
Fix variable leaks by making more variables in lib/git.zsh local.
Have lib/git.zsh use [[ ]] instead of [ ] everywhere.
2015-12-14 20:28:37 -05:00
Robby Russell
57c2ac1e60 Merge pull request #4482 from sachin21/add_an_alias_for_upstream
Add an alias for upstream
2015-10-10 07:12:21 -07:00
Satoshi Ohmori
7597bf805e Add an alias for upstream 2015-10-10 11:51:33 +09:00
Bruno Volcov
252078dd6c add alias to sort by version 2015-10-09 18:47:48 -03:00
Michael SALIHI
8e74f7c1aa Add alias for print latest tag name 2015-09-24 02:22:50 +02:00
Robby Russell
a77e23a0f9 Merge pull request #4109 from zhiyelee/patch-1
add git alias `gcam` -  git commit -am
2015-08-30 21:52:07 -07:00
Matteo Giaccone
a2b574bc9e git plugin: make gclean safer, introduce gpristine 2015-07-30 12:32:41 +01:00
Zhiye Li
efb04d66a0 add git alias gcam - git commit -am
add git alias `gcam` -  `git commit -am`
2015-06-30 17:50:01 -05:00
ncanceill
d24196cfbd git plugin: fix ggl to avoid empty string
see
https://github.com/robbyrussell/oh-my-zsh/pull/2790#issuecomment-112716330
2015-06-17 22:38:31 +02:00
Arnaud Rinquin
ed6645a282 Fix plugin/git ggpull and ggpush backward compatibility
Current `ggpush` is `git push origin` instead of `git push origin $(current_branch)`
Same for `ggpull`
2015-06-17 22:36:25 +02:00
ncanceill
f1a43daa36 git plugin: new/changed aliases
gaa was brought back by popular demand — see #3535
gap was replaced with gapa — see #3682
gdc was replaced with gdca — see #3977
2015-06-12 11:50:30 +02:00
ncanceill
8eb31a6f9a git plugin: fix ggpnp when called without argument
also allow multiple arguments for ggp and ggl aliases
2015-06-11 23:34:18 +02:00
ncanceill
f513999a4d git plugin: make b local in gg* functions
because it leaked, and led to #3991
2015-06-11 17:14:35 +02:00
ncanceill
6ff96dab36 git plugin: fix error msg in gwip alias
because git rm will fail when no files were deleted
2015-06-11 16:16:12 +02:00
ncanceill
6c29041af7 git plugin: global var for git command
due to issues like #3962
until a proper plugin-loading system is implemented
2015-06-11 15:12:28 +02:00
ncanceill
a570f4b7f3 git plugin: bring back olg gg aliases
by popular demand, see #3972
2015-06-11 11:04:54 +02:00
ncanceill
5b75cc7880 Many updates to git plugin (see #2790) 2015-05-08 16:00:22 +02:00
Robby Russell
43531625ab Merge pull request #2407 from mgalgs/gmt-compdef
Fix gmt compdef
2015-02-22 10:24:39 -08:00
Tejas Bubane
8cb97d6f22 Add alias for git add --all 2015-02-04 12:24:17 +05:30
Robby Russell
5e25913178 Revert "Exit early from git plugin if not in git repo." 2014-09-04 12:53:43 +02:00
AJ Henriques
f0d5cfdc33 add git difftool alias (gdt) 2014-08-31 20:30:42 -07:00
Robby Russell
99fde07b8f Merge pull request #3000 from bigtiger/add-git-add-patch
Add gap (git add --patch)
2014-08-31 12:10:04 -07:00
Robby Russell
58491bda21 Merge pull request #3012 from abstractj/git-gpg-signatures
Inclusion of aliases for sign git commits and tags
2014-08-31 11:44:57 -07:00
Robby Russell
74e7510a7d Merge pull request #3014 from allister-lundberg/git_alias_gitbranchremote
New alias for git plugin: gbr == git branch --remote
2014-08-31 11:43:59 -07:00
Robby Russell
c07bf981c3 Merge pull request #1504 from jediant/master
Exit early from git plugin if not in git repo.
2014-08-31 10:59:55 -07:00
DariusPHP
5d6c73d7d3 #git plugin git diff-tree --name-only added 2014-08-22 10:21:38 +03:00
lundberg
9a0196dbf7 New alias for git plugin: gbr == git branch --remote 2014-08-10 12:01:47 -07:00
Bruno Oliveira
45abe764e5 Inclusion of aliases for sign git commits and tags 2014-08-09 12:26:35 -03:00
Jim Remsik
4f1ee6c1ee Add gap (git add --patch) 2014-08-01 20:16:33 -05:00
Mitchel Humpherys
33ef34baa5 Fix gmt compdef
Fix typo: gm -> gmt
2014-04-29 10:20:39 -07:00
Benoit Dubertret
a869ec9bc8 Fix gwip alias in git plugin when no files to rm 2014-03-17 16:07:46 +01:00
Emanuele Zattin
f6f3e93019 Improve oneline logs
Add decorate and color to the normal oneline and add a new alias for graph oneline logs.
2014-02-13 10:32:52 +01:00
Sam O
d60522c7a2 escape dashes 2014-01-02 15:53:34 -08:00
Sam O
827d9dfcb4 Update git.plugin.zsh 2014-01-02 15:48:09 -08:00
Robby Russell
4e34588a5b Merge pull request #2208 from onemouth/master
Update git.plugin.zsh
2013-12-03 00:20:36 -08:00
Robby Russell
b6f4a887ac Merge pull request #2131 from stevschmid/patch-1
Fix gallois theme
2013-12-02 23:24:01 -08:00
onemouth
c81e42f050 Update git.plugin.zsh
add command to ignore changes to file temporarily
2013-10-30 11:05:35 +08:00
Robby Russell
86d57e83ed Merge pull request #2078 from tbuehl/master
Add commonly used git stash aliases to git plugin
2013-10-24 20:24:59 -07:00
Steven Schmid
05b3ea342a Fix work_in_progress in empty git repos
I noticed that the function ``work_in_progress``, which is used in the "gallois"-theme, would print ``fatal: bad default revision 'HEAD'`` in a new folder after ``git init``.

This is the fix.
2013-10-01 18:08:15 +02:00
Robby Russell
26e936e645 Merge pull request #1967 from tchaudhri/gdc_git_alias
Added a 'git diff --cached' alias -> 'gdc'
2013-09-19 06:56:58 -07:00
Robby Russell
a712579a2a Merge pull request #2099 from mchaisse/master
Added WIP (work in progress) feature to git.plugin
2013-09-18 23:38:11 -07:00
Maxime Chaisse-Leal
095a01d92a Added WIP (work in progress) feature to git.plugin 2013-09-18 21:54:23 +02:00
Torsten Bühl
5bf20572cc Add commonly used git stash aliases 2013-09-05 14:37:37 +02:00
yleo77
fda5afaebc Merge remote-tracking branch 'robbyrussell/master' 2013-08-29 13:41:42 +08:00
Robby Russell
39a5e36c37 Merge pull request #1790 from simlegate/master
change git  alias
2013-08-13 06:20:53 -07:00
yleo77
6041e4938c set default value --max-count=10 2013-07-16 16:54:54 +08:00
yleo77
67b2781f62 Merge remote-tracking branch 'robbyrussell/master' 2013-07-16 16:37:18 +08:00
Tehmasp Chaudhri
57a2327ddf Added a 'git diff --cached' alias -> 'gdc' 2013-07-12 12:03:44 -06:00
Brent Theisen
05d8fdf3d5 Copy and paste of two functions from Ubuntu 13.04's version of /usr/share/zsh/functions/Completion/Unix/_git that were referenced in 46f0d8d. Fixes #1952. 2013-07-09 23:15:43 -05:00
Okura Masafumi
c51ef9dce6 Change duplicated alias name 2013-06-27 22:28:14 +09:00
Robby Russell
b9baf37739 Merge pull request #1859 from ayushs/plugin-git-clean
Added alias for git clean
2013-06-25 09:26:00 -07:00
Robby Russell
a8c0c4de06 Merge pull request #1864 from Stibbons/gsemet_push_git_plugin
Improvement in the git plugin
2013-06-25 09:25:38 -07:00
Michiel Missotten
d6945e2daa Adding a rebase option to git alias. 2013-06-11 11:23:02 +02:00
Gaetan Semet
46f0d8dba9 Improvement in the git plugin
Signed-off-by: Gaetan Semet <gaetan@xeberon.net>
2013-06-05 15:16:51 +02:00
Ayush Samantroy
6f8e8c58a0 Added alias for git clean 2013-06-01 18:02:38 +05:30
yleo77
00848cd8b7 add gf alias for git flow 2013-05-22 17:00:08 +08:00
simlegate
22dce9e715 add git alias 'gcmsg' and stand for 'git commit -m' 2013-05-09 12:57:32 +08:00
simlegate
b36c42b76d rename gcm to gcmsg and stand for 'git commit -m' 2013-05-08 17:03:07 +08:00
simlegate
cf3a03d45e rm alias gcm='git checkout master' and add alias gcm='git commit -m' 2013-05-05 16:35:40 +08:00
Robby Russell
f44d403572 Resolving conflict with merge of #1058 2013-04-23 21:20:00 -07:00
Robby Russell
b4578be3f1 Merge pull request #818 from jmacdonald/master
Alias for 'git diff'
2013-04-23 20:48:36 -07:00
Ben Marshall-Corser
f7f487c426 Alias for commit and commit all with amend
For the lazy and forgetful. Don't worry, a bang is fine in an alias and completion.

🎉
2013-03-17 23:00:12 +00:00
Anton Eicher
fdb3c0e68d Added check for .git directory in current, before wasting time querying git. This saves seconds on my pc. 2012-12-19 07:22:03 -08:00
Robby Russell
083da66c0b Merge pull request #1139 from mappleconfusers/pull_req_git
Add aliases for git-remote
2012-12-05 07:16:36 -08:00
Robby Russell
178bce287e Merge branch 'master' of github.com:robbyrussell/oh-my-zsh 2012-12-04 08:27:13 -08:00
Robby Russell
bd9a86051f Merge pull request #1247 from drnic/git-cmds
Added 'gcl'for 'git config --list'; and gd for 'git diff'
2012-12-04 06:37:18 -08:00
Robby Russell
868a5138f6 Resolving conflict in merge of #1313 2012-12-04 06:35:59 -08:00
Robby Russell
9977afc0b5 Merge pull request #1263 from tedv/headless-git
Make git use sha when branch name is missing.
2012-12-02 12:42:38 -08:00
Robby Russell
ac90eed387 Merge pull request #1274 from sc68cal/feature/git_decorate_log
[Git Plugin] Add shortcut for showing log of all branches
2012-12-02 12:39:55 -08:00
Marcus Müller
ab13d0756f git find 2012-12-02 12:16:14 -08:00
Robby Russell
f2050fc093 Merge pull request #1413 from arnihermann/master
Implement 'gup' as git pull --rebase
2012-12-01 11:33:40 -08:00
Robby Russell
5189cb8843 Merge pull request #1418 from Mehonoshin/patch-2
Added gwc(git whatchanged alias) to git plugin
2012-12-01 11:32:35 -08:00
Stanislav Mekhonoshin
7991562e76 Added gwc(git whatchanged alias)
Allows to view commit history in extended way
2012-11-24 11:23:44 +04:00
Josh Matthews
7be660bf1d Adding grt alias to the git plugin. 2012-11-20 13:13:04 -05:00
Árni Hermann Reynisson
003b0da9e5 Use pull --rebase for 'gup' shortcut.
Instead of git fetch && git rebase.
2012-11-20 15:01:39 +00:00
Alexander Surma
28d28ee6f6 git plugin: Add gpoat alias 2012-09-14 13:57:13 +02:00
Sean M. Collins
74faabbcab Add shortcut for showing log of all branches 2012-08-07 14:38:48 -04:00
Ted Vessenes
027fcccc92 Make git use sha when branch name is missing. 2012-07-31 13:27:40 -04:00
Dr Nic Williams
73df0c8e93 added 'gcl'for 'git config --list'; and gd for 'git diff' 2012-07-23 07:51:29 -07:00
mapc
3dd3c1f415 Add aliases for git-remote: gr... 2012-05-29 14:32:49 +02:00
Steven G. Harms
9b05a44387 Adds glo; glp (arg)
* glo := git log --oneline
* glp := git log --pretty=arg
2012-04-05 10:18:22 -07:00
pomaxa
b1e4ef1754 current repository action 2012-03-01 16:57:00 +02:00
Carlos Rodriguez
8769e5f8c9 Removed trailing spaces in Git files. Fixes #867 2012-01-26 23:19:50 -08:00
Carlos Rodriguez
9d92987b8a Merge pull request #663 from gravof/patch-1
Replace "git-diff" with "git diff" in the git plugin
2012-01-26 00:11:42 -08:00
Jordan MacDonald
49d44adb09 Fixed compdef alias to use 'gd' as shortcut. 2012-01-20 13:07:03 -05:00
Chad Seeger
ae735335e1 Kill the compdef; Introduce 'grh' alias for 'git reset HEAD' 2012-01-09 15:19:19 -08:00
Jordan MacDonald
730e029664 Added alias for git diff. 2012-01-07 15:36:58 -05:00
Chad Seeger
9ac98f6ceb Git Plugin: adds 'grhh' alias for 'git reset HEAD --hard' 2012-01-05 13:41:27 -08:00
Alexander Balashov
12a04571bb Added alias gcm='git checkout master 2011-12-23 11:14:22 +04:00
Gavin Huang
7553d0171f Replace "git-diff" with "git diff" in the git plugin 2011-10-18 11:46:45 +08:00
Dan Shearmur
c1c7b0e4af added git merge as gm 2011-09-26 14:44:42 +01:00
Mark Szymanski
bd6aba9c68 Add an alias for ga --> git add, too 2011-08-27 16:23:49 -05:00
Mark Szymanski
1fb141cfb5 Add gss alias for git status -s 2011-08-27 16:16:51 -05:00