transfer function to shellscript
This commit is contained in:
parent
e6602d3410
commit
a2a54e6d9e
2 changed files with 20 additions and 10 deletions
7
bin/git-mergedetachedheadtomaster
Normal file
7
bin/git-mergedetachedheadtomaster
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
git checkout -b tmp
|
||||||
|
git branch -f master tmp
|
||||||
|
git checkout master
|
||||||
|
git branch -d tmp
|
||||||
|
git commit -m "Merged detached head into master" .
|
23
functions.sh
23
functions.sh
|
@ -279,16 +279,17 @@ unsetproxy () {
|
||||||
EXIT
|
EXIT
|
||||||
}
|
}
|
||||||
|
|
||||||
git-mergedetachedheadtomaster () {
|
# transfered to bin
|
||||||
ENTRY
|
#git-mergedetachedheadtomaster () {
|
||||||
git checkout -b tmp
|
# ENTRY
|
||||||
git branch -f master tmp
|
# git checkout -b tmp
|
||||||
git checkout master
|
# git branch -f master tmp
|
||||||
git branch -d tmp
|
# git checkout master
|
||||||
git commit -m "Merged detached head into master" .
|
# git branch -d tmp
|
||||||
#git push origin master
|
# git commit -m "Merged detached head into master" .
|
||||||
EXIT
|
# #git push origin master
|
||||||
}
|
# EXIT
|
||||||
|
#}
|
||||||
|
|
||||||
pathmunge () {
|
pathmunge () {
|
||||||
ENTRY
|
ENTRY
|
||||||
|
@ -835,6 +836,7 @@ token(){
|
||||||
[ -z "${P11M:+x}" ] && { P11M=$PKCS11_MODULE; export P11M; }
|
[ -z "${P11M:+x}" ] && { P11M=$PKCS11_MODULE; export P11M; }
|
||||||
|
|
||||||
tmppubkey="${XDG_RUNTIME_DIR}/token.pub"
|
tmppubkey="${XDG_RUNTIME_DIR}/token.pub"
|
||||||
|
# Write public keys of all in agent stored keys to a temporary file
|
||||||
loginfo "$(ssh-add -L > $tmppubkey)"
|
loginfo "$(ssh-add -L > $tmppubkey)"
|
||||||
|
|
||||||
# Usage:
|
# Usage:
|
||||||
|
@ -842,6 +844,7 @@ token(){
|
||||||
# token -r|-f|--reload-token <identity> will remove token from agent and add it again (if plugged off and plugged in again
|
# token -r|-f|--reload-token <identity> will remove token from agent and add it again (if plugged off and plugged in again
|
||||||
# startagent -t $@
|
# startagent -t $@
|
||||||
# loadagent $@
|
# loadagent $@
|
||||||
|
# Check if public-keys in tmppubkey are working. They are not working, if you removed and add back hardware-token.
|
||||||
loginfo "$(ssh-add -T ${tmppubkey} || { ssh-add -e $P11M; ssh-add -s $P11M; } )"
|
loginfo "$(ssh-add -T ${tmppubkey} || { ssh-add -e $P11M; ssh-add -s $P11M; } )"
|
||||||
loginfo "$(ssh-add -l)"
|
loginfo "$(ssh-add -l)"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue