Created
March 5, 2014 20:03
-
-
Save falsecz/9375442 to your computer and use it in GitHub Desktop.
jenkins-cli
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function _jenkins() { | |
local cur tasks | |
cur="${COMP_WORDS[COMP_CWORD]}" | |
tasks="$(/Users/bender/bin/jenkins --jobs)" | |
COMPREPLY=( $(compgen -W "$tasks" $cur) ) | |
} | |
complete -o default -F _jenkins jenkins c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
USER=benesl | |
PASS=`security find-internet-password -g -s jenkins.ccl -w` | |
if [ "$1" = "--jobs" ] | |
then | |
cat ~/bin/jenkins.tmp | |
exit | |
fi | |
if [ "$1" = "update" ]; then | |
ssh benesl@jenkins.ccl -p 2222 list-jobs > ~/bin/jenkins.tmp | |
exit | |
fi | |
ssh $USER@jenkins.ccl -p 2222 build -v -s $@ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment