- Modificado (modified);
- Preparado (staged/index)
- Consolidado (comitted);
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 subprocess | |
import fnmatch | |
import os | |
import os.path | |
from string import Template | |
from optparse import OptionParser | |
import webbrowser | |
import string | |
import datetime |
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 bash | |
# Use this one-liner to produce a JSON literal from the Git log: | |
git log \ | |
--pretty=format:'{%n "commit": "%H",%n "author": "%aN <%aE>",%n "date": "%ad",%n "message": "%f"%n},' \ | |
$@ | \ | |
perl -pe 'BEGIN{print "["}; END{print "]\n"}' | \ | |
perl -pe 's/},]/}]/' |
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
# Simple JBoss7 helper functions | |
# set var to jboss home dir | |
JBOSS_HOME="/usr/local/jboss/jboss-as-web-7.0.2.Final" | |
#Start BBoss | |
alias jboss-start="sudo $JBOSS_HOME/bin/standalone.sh" | |
#Stop JBoss | |
alias jboss-stop="sudo $JBOSS_HOME/bin/jboss-admin.sh --connect command=:shutdown" |
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
echo -e " \033[0;30m Preto \033[0m --> 0;30 " | |
echo -e " \033[0;31m Vermelho \033[0m --> 0;31 " | |
echo -e " \033[0;32m Verde \033[0m --> 0;32 " | |
echo -e " \033[0;33m Marrom \033[0m --> 0;33 " | |
echo -e " \033[0;34m Azul \033[0m --> 0;34 " | |
echo -e " \033[0;35m Purple \033[0m --> 0;35 " | |
echo -e " \033[0;36m Cyan \033[0m --> 0;36 " | |
echo -e " \033[0;37m Cinza Claro \033[0m --> 0;37 " | |
echo -e " \033[1;30m Preto Acinzentado \033[0m --> 1;30 " | |
echo -e " \033[1;31m Vermelho Claro \033[0m --> 1;31 " |
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 | |
# query the root of the repo because git status prints | |
# relative paths within the repo | |
if ! pushd "`git rev-parse --show-toplevel`" >/dev/null | |
then | |
echo "git rev-parse --show-toplevel failed to return the root dir of the repo" | |
exit 1 | |
else | |
gitroot=`pwd` |
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
:: Stop IIS | |
PsExec.exe \\LDNSERV01 -s -i C:\windows\system32\inetsrv\appcmd.exe stop site OnlineXCart | |
:: Recycle App Pool (removes lock on file system) | |
PsExec.exe \\LDNSERV01 -s -i C:\windows\system32\inetsrv\appcmd.exe recycle apppool OnlineXCart | |
:: Wait 4 Seconds | |
:: This is useful if you have a command straight after that executes file operations on IIS App Directory | |
ping -n 5 127.0.0.1 > nul |
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 | |
set -e | |
if [ $# -eq 0 ]; then | |
echo "USAGE: $0 plugin1 plugin2 ..." | |
exit 1 | |
fi | |
plugin_dir=/var/lib/jenkins/plugins |
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
############################################################################### | |
# Helpful Docker commands and code snippets | |
############################################################################### | |
### CONTAINERS ### | |
docker stop $(docker ps -a -q) #stop ALL containers | |
docker rm -f $(docker ps -a -q) # remove ALL containers | |
docker rm -f $(sudo docker ps --before="container_id_here" -q) # can also filter | |
# exec into container |
sudo su
apt-get update && apt-get install -y libvirt-dev ruby-all-dev apparmor-utils
curl -O -L https://dl.bintray.com/mitchellh/vagrant/vagrant_1.6.5_x86_64.deb
dpkg -i vagrant_1.6.5_x86_64.deb
aa-complain /usr/lib/libvirt/virt-aa-helper # workaround
exit
OlderNewer