This file contains hidden or 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
git fetch --prune | |
git branch -r | awk '{print $1}' | egrep -v -f /dev/fd/0 <(git branch -vv | grep origin) | awk '{print $1}' | xargs git branch -d |
This file contains hidden or 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
#!/usr/bin/env python3 | |
# pip3 install artifactory | |
import os | |
from artifactory import ArtifactoryPath | |
from pathlib import Path | |
ARTIFACTORY_URL = "https://localhost:8081/artifactory" | |
ARTIFACTORY_USER = 'admin' |
This file contains hidden or 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
import groovy.json.JsonSlurper | |
def sonarqube_host = "http://SONARQUBE_URL:9000" | |
def projectname = "MY_PROJECT" | |
def SONARCUBE_URL = "${sonarqube_host}/api/measures/component?componentKey=${projectname}&metricKeys=coverage,ncloc" | |
def son_ncloc = 'N/A' | |
def son_coverage = 'N/A' | |
def authString = "amin:admin".getBytes().encodeBase64().toString() |
This file contains hidden or 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
import groovy.json.JsonSlurper | |
def sonarqube_host = "http://SONARQUBE_URL:9000" | |
def projectname = "MY_PROJECT" | |
def SONARCUBE_URL = "${sonarqube_host}/api/measures/component?componentKey=${projectname}&metricKeys=coverage,ncloc" | |
def son_ncloc = 'N/A' | |
def son_coverage = 'N/A' | |
def son_qgates = 'N/A' |
This file contains hidden or 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 | |
export JFROG_CLI_OFFER_CONFIG="false" | |
source_folder_name="abc" | |
source_url="http://<SOURCE_URL>:8081/artifactory" | |
source_user="" | |
source_password="" | |
target_folder_name="blablabla" |
This file contains hidden or 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
node('myslave') { | |
stage('downstream') { | |
sh """ | |
export shortDescription="${getCauser()?.shortDescription}" | |
export upstreamBuild="${getCauser()?.upstreamBuild}" | |
export upstreamUrl="${getCauser()?.upstreamUrl}" | |
export upstreamProject="${getCauser()?.upstreamProject}" | |
""" | |
} | |
} |
This file contains hidden or 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 | |
AUTHENTICATION_TOKEN="<AUTHENTICATION_TOKEN>" | |
JENKINS_URL="<JENKINS_URL>" | |
JOB="<JOB>" | |
USER="<USER>" | |
API_TOKEN="<API_TOKEN>" | |
TOKEN="<TOKEN>" | |
EComponents="mydeb.deb" |
This file contains hidden or 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 | |
sonar_version="6.7.4" | |
cxx_version="1.1.0" | |
SONAR_HOME="/home/one/sonarqube" | |
#Stop and delete sonarqube installation | |
$SONAR_HOME/bin/linux-x86-64/sonar.sh stop | |
rm -rf $SONAR_HOME/ |
This file contains hidden or 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 | |
checkdate=`date --date "yesterday 00:00" +%s000` | |
curl -u ${ARTIFACTORY_USER}:${ARTIFACTORY_PASSWORD} --silent --request GET "${ARTIFACTORY_URL}/artifactory/api/search/dates?dateFields=lastModified&from=${checkdate}&repos=${REPOS}" |