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
| #!/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
| 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
| def scannerHome = tool 'SonarQube Scanner 3'; | |
| withSonarQubeEnv(config.sonarqube_id) { | |
| sh "${scannerHome}/bin/sonar-scanner" | |
| } | |
| def props = readProperties file: '.scannerwork/report-task.txt' | |
| echo "properties=${props}" | |
| def sonarServerUrl=props['serverUrl'] | |
| def ceTaskUrl= props['ceTaskUrl'] | |
| def projectKey = props['projectKey'] |
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
| sh """ | |
| #!/bin/bash | |
| PATH=${WORKSPACE}/venv/bin:/usr/local/bin:\$PATH | |
| rm -rf venv | |
| virtualenv -p python3 venv | |
| . venv/bin/activate | |
| pip3 install pylint | |
| venv/bin/pylint test/tests/ -r n --msg-template="{path}:{line}: [{msg_id}({symbol}), {obj}] {msg}" > pylint-report.txt || exit 0 | |
| """ |
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 | |
| # Simple command to display the wireless strenght signal | |
| # | |
| clear | |
| while true | |
| do /System/Library/PrivateFrameworks/Apple*.framework/Versions/Current/Resources/airport -I \ | |
| | grep CtlRSSI \ | |
| | sed -e 's/^.*://g' \ | |
| | xargs -I SIGNAL printf "\nWiFi dBm: SIGNAL" | |
| sleep 1 |
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 java.text.SimpleDateFormat | |
| def date = new Date() | |
| sdf = new SimpleDateFormat("MMddyyyy-hhmmss") | |
| println sdf.format(date) |
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 | |
| import requests | |
| import urllib3 | |
| import json | |
| from requests.auth import HTTPBasicAuth | |
| urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) |
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
| cat /etc/systemd/system/docker.service.d/http-proxy.conf | |
| [Service] | |
| Environment="HTTP_PROXY=http://127.0.0.1:9400" "HTTPS_PROXY=http://127.0.0.1:9400" "NO_PROXY=localhost,127.0.0.1" |