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 | |
brew list | |
brew cask list | |
brew update | |
brew outdated | |
brew upgrade | |
brew cask upgrade | |
brew cask upgrade --greedy | |
brew cleanup -n | |
brew cleanup |
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
cd <basedir> | |
git clone ssh://git@<your git repo>:7999/fleet/fleet.git | |
cd <basedir>/fleet | |
git checkout -b xbtask01 | |
... make changes ... | |
cd <basedir>/fleet | |
git status | |
git commit -am "fixing issue, task01" | |
git push origin xbtask01 |
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 | |
docker run -d --name swagger -p 8080:8080 swaggerapi/swagger-editor | |
docker run -d --name dillinger -p 8090:8080 --restart="always" joemccann/dillinger:3.24.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
startpyws () | |
{ | |
V=$(python -c 'import sys;print(sys.version_info.major)'); | |
if [ "$V" == "2" ]; then | |
python -m SimpleHTTPServer; | |
else | |
python -m http.server; | |
fi | |
} |
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
# make your browser your simple editor | |
# in the address bar type: | |
data:text/html,<html contenteditable> | |
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
<script> | |
var d = new Date(); | |
var mm = (d.getMonth() + 1).toString().padStart(2, "0"); | |
var dd = (d.getDate()).toString().padStart(2, "0"); | |
var yy = ((d.getFullYear() %100).toString()).padStart(2, "0"); | |
var date_str = '' + mm + '-' + dd + '-' + yy; | |
</script> |
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
# repo - https://github.com/xbalaji/git-hooks | |
wget https://raw.githubusercontent.com/xbalaji/git-hooks/master/setup-githooks.sh -q -O - | bash |
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 python | |
import sys | |
ifile = open(sys.argv[1], 'r') | |
ofile = open(sys.argv[2], 'w') | |
for c, line in enumerate(ifile, 1): | |
ofile.write("{} {}".format(c,line)) | |
ifile.close() | |
ofile.close() |
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
export DOCKER_MVN_VOLS="-v ${PWD}:/usr/src/mymaven -v ${HOME}/.m2:/root/.m2 -v ${HOME}/.m2/repository:/usr/share/maven/ref/repository" | |
docker run -it --rm --name my-maven-project $DOCKER_MVN_VOLS -w /usr/src/mymaven maven:3.3-jdk-8 mvn archetype:generate -DgroupId=com.xb -DartifactId=java-project -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false | |
docker run -it --rm --name my-maven-project $DOCKER_MVN_VOLS -w /usr/src/mymaven maven:3.3-jdk-8 mvn -f java-project/pom.xml package | |
docker run -it --rm --name my-maven-project $DOCKER_MVN_VOLS -w /usr/src/mymaven maven:3.3-jdk-8 mvn -f java-project/pom.xml cobertura:cobertura | |
docker run -it --rm --name my-maven-project $DOCKER_MVN_VOLS -w /usr/src/mymaven maven:3.3-jdk-8 java -Duser.dir=./java-project -cp target/java-project-1.0-SNAPSHOT.jar com.xb.App |
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 remote show origin | |
git config --get remote.origin.url | |
git remote -v | |
git ls-remote --get-url | |
git remote get-url origin |