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
def manager = org.jenkins.plugins.lockableresources.LockableResourcesManager.get() | |
def resources = manager.getResources().findAll { | |
(!it.locked) && ( | |
it.name.contains("PR-") || | |
it.name.contains("hotfix-") || | |
it.name.contains("feature-") | |
) | |
} | |
resources.each { | |
println "Removing ${it.name}" |
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 | |
#loop through characters in string taking input from first param | |
string=${1} | |
for (( i=0; i<${#string}; i++ )); do | |
#echo "${string:$i:1}" | |
for (( x=(($i + 1)); x<${#string}; x++ )); do | |
#echo XXX- "${string:$x:1}" | |
if [[ "${string:$i:1}" == "${string:$x:1}" ]] | |
then |
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
[Unit] | |
Description=Demonstrate Bash | |
[Service] | |
ExecStartPre=/usr/bin/bash -c "/usr/bin/systemctl set-environment MYVAR=$(( 2 + 2 ))" | |
ExecStart=/usr/bin/echo "2 + 2 = ${MYVAR}" |
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
### Keybase proof | |
I hereby claim: | |
* I am leonowski on github. | |
* I am leonowski (https://keybase.io/leonowski) on keybase. | |
* I have a public key ASBKdnQmZAKpbC7aouLlyHhnm4O6j2b3S63HZvZ-Rft6Vwo | |
To claim this, I am signing this object: |