Skip to content

Commit 20a17ba

Browse files
committed
Changes reverted to a previous state
1 parent 2cb986e commit 20a17ba

File tree

4 files changed

+17
-19
lines changed

4 files changed

+17
-19
lines changed

EasyKey.bash/bashstuff.sh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,20 @@ findTextAll() {
2727
find . -type f -exec grep -Hn "$textPattern" {} + | awk -F ":" '{printf "%-40s %-4s %s\n", $1, $2, $3}'
2828
}
2929

30+
whichSoftware() {
31+
echo "Which software to search?"
32+
read software
33+
[ "${software}" = "" ] && waitonexit && return
34+
which -a $software
35+
}
36+
3037
menuInit "EasyKey.bash"
31-
submenuHead "Usefull:"
38+
submenuHead "Usefull "
3239
menuItem f "Find files by pattern" findFiles
3340
menuItem t "Find text inside specific files" findText
3441
menuItem o "Find test inside all files" findTextAll
3542
menuItem l "Largest directories" "du -hsx .[!.]* * | sort -rh | head -10"
3643
menuItem m "Largest files" "find . -type f -exec du -h {} + | sort -rh | head -n 10"
3744
menuItem n "Size of current directory" "du -sh ."
45+
menuItem w "Where is my software installed?" whichSoftware
3846
startMenu "pwd"

EasyKey.git/ezk-git-atln.sh

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -37,25 +37,11 @@ atlnStatus() {
3737
echo "Atlassians view on GIT, https://de.atlassian.com/git/tutorials"
3838
}
3939

40-
checkoutAndBranch(){
41-
echo "Last 15 commits"
42-
git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit -n 100
43-
echo "Enter commit you want to checkout:"
44-
read cname
45-
[ "${cname}" = "" ] && waitonexit && return
46-
executeCommand "git checkout $cname"
47-
echo "Enter new branch name:"
48-
read cbranch
49-
[ "${cbranch}" = "" ] && waitonexit && return
50-
executeCommand "git checkout -b $cbranch"
51-
}
52-
5340
menuInit "Atlassian's View"
5441
submenuHead "Working on your local repository"
5542
menuItem b "Saving changes" savingChanges
5643
menuItem c "Inspecting a repository" inspectingRepos
5744
menuItem d "Undoing changes" undoingChanges
5845
menuItem e "Cherry pick commit" cherryPick
59-
menuItem f "Checkout commit and branch" checkoutAndBranch
6046
startMenu "atlnStatus"
6147
noterminate

EasyKey.git/ezk-git-functions.sh

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ function rollBackLast() {
188188

189189
function deleteBranch() {
190190
git branch
191-
echo "Welchen Branch löschen?"
191+
echo "Which branch to delete?"
192192
read dbranch
193193
[ "${dbranch}" = "" ] && waitonexit && return
194194
git branch -d $dbranch
@@ -331,12 +331,16 @@ function setRemoteOrigin() {
331331
executeCommand "git remote set-url origin $originaddress"
332332
}
333333

334+
newStatus() {
335+
actual=$(git rev-parse --abbrev-ref HEAD 2> /dev/null)
336+
git status -s
337+
}
338+
334339
function showStatus () {
335340
importantLog $(pwd | grep -o "[^/]*$")
336341
actual=$(git rev-parse --abbrev-ref HEAD 2> /dev/null)
337342
importantLog $actual
338-
git log --decorate --oneline -n 1
339-
git status | grep "Your branch"
343+
git log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s' --abbrev-commit -n 1
340344
analyzeWorkingDir
341345
git remote -v
342346
}

EasyKey.git/git.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ menuInit "EasyKey.git"
3131
submenuHead "Shortcuts "
3232
menuItemClm P "Change project" changeProject B "Change branch" changeBranch
3333
menuItem F "Fetch all" fetchAll
34-
startMenu "git status"
34+
startMenu "showStatus"
3535
echo "bye, bye, homie!"

0 commit comments

Comments
 (0)