Skip to content
Browse files

Show modified files before branches when expanding git checkout -- <tab>

  • Loading branch information...
1 parent c4ac7bf commit fec4e2138d9d2c3753fafd2d4e99ddbfee9ea24b @dahlbyk dahlbyk committed May 17, 2012
Showing with 5 additions and 5 deletions.
  1. +5 −5 GitTabExpansion.ps1
View
10 GitTabExpansion.ps1
@@ -177,11 +177,6 @@ function GitTabExpansion($lastBlock) {
}
# Handles git <cmd> <ref>
- "^(?:checkout|cherry-pick|diff|difftool|log|merge|rebase|reflog\s+show|reset|revert|show).* (?<ref>\S*)$" {
- gitBranches $matches['ref'] $true
- }
-
- # Handles git <cmd> <ref>
"^commit.*-C\s+(?<ref>\S*)$" {
gitBranches $matches['ref'] $true
}
@@ -200,6 +195,11 @@ function GitTabExpansion($lastBlock) {
"^rm.* (?<index>\S*)$" {
gitDeleted $matches['index']
}
+
+ # Handles git <cmd> <ref>
+ "^(?:checkout|cherry-pick|diff|difftool|log|merge|rebase|reflog\s+show|reset|revert|show).* (?<ref>\S*)$" {
+ gitBranches $matches['ref'] $true
+ }
}
}

0 comments on commit fec4e21

Please sign in to comment.
Something went wrong with that request. Please try again.