zsh terminal
Add these lines in your ~/.bash_profile file
# Show current git branch name
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}| #!/bin/bash | |
| group_name='<log-group-name>' | |
| start_seconds_ago=3600 | |
| aws_cmd_opts= # e.g. "--profile <profile-name>" | |
| # Usage: get_loglines "<log-group-name>" <start-time> | |
| get_loglines() { | |
| aws $aws_cmd_opts --output text logs filter-log-events \ | |
| --log-group-name "$1" \ |
| #!/bin/bash | |
| set -e | |
| if [ $# -eq 0 ]; then | |
| echo "USAGE: $0 plugin1 plugin2 ..." | |
| exit 1 | |
| fi | |
| plugin_dir=/var/lib/jenkins/plugins |
| if ls /path/to/your/files* &> /dev/null; then | |
| echo "files do exist" | |
| else | |
| echo "files do not exist" | |
| fi |
| def findPluginsWithUpdates = ''' | |
| Hudson.instance.pluginManager.plugins.inject([]) { List toUpdate, plugin -> | |
| if(plugin.hasUpdate()) | |
| { | |
| toUpdate << plugin.shortName | |
| } | |
| toUpdate | |
| }.inspect() | |
| ''' | |
| OutputStream updateablePlugins = new ByteArrayOutputStream() |