Skip to content

Instantly share code, notes, and snippets.

View vaijab's full-sized avatar

Vaidas Jablonskis vaijab

View GitHub Profile
for n in $(docker ps -a | awk '/Exited \([0-9]*/ {print $1}'); do docker rm -f -v ${n}; done
docker rmi $(docker images | awk '/^<none>/ {print $3}')
wget -q https://github.com/chadoe/docker-cleanup-volumes/raw/master/docker-cleanup-volumes.sh
bash docker-cleanup-volumes.sh -v
#!/usr/bin/bash
files="*.service"
for fname in ${files}; do
[[ -e ${fname} ]] || continue
read -r h f <<< $(md5sum ${fname})
echo ""${f/%.service/@${h}.service}""
done
### Keybase proof
I hereby claim:
* I am vaijab on github.
* I am vaijab (https://keybase.io/vaijab) on keybase.
* I have a public key whose fingerprint is 8B85 568C BB82 3F47 9866 7A8C DCA0 ECDC FC69 7983
To claim this, I am signing this object:
@vaijab
vaijab / btwifi-autologin.service
Last active August 29, 2015 14:24
BTWifi auto login
[Unit]
Description=BT Wifi auto login hack
After=network.target
[Service]
Restart=always
RestartSec=30
ExecStart=/home/vaijab/bin/btwifi_autologin.sh
[Install]
#cloud-config
users:
- name: foo
passwd: $6$5s2u6/jR$un0AvWnqilcgaNB3Mkxd5yYv6mTlWfOoCYHZmfi3LDKVltj.E8XNKE
groups:
- sudo
- docker
ssh-authorized-keys:
- ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC0g+ZTxC7weoIJLUafOgrm+
CGI::Lite - built "libcgi-lite-perl"
Mail::Mailer - in repo "libmailtools-perl"
Data::GUID - backported "libdata-guid-perl"
Text::CSV - in repo "libtext-csv-perl"
JSON - in repo "libjson-perl"
Proc::ProcessTable - in repo "libproc-processtable-perl"
Authen::SASL - in repo "libauthen-sasl-perl"
URI::Escape::XS - in repo "liburi-escape-xs-perl"
YAML - in repo "libyaml-perl"
# shows git branch if any
function git_branch {
if [[ -x /usr/bin/git ]]; then
git branch &> /dev/null
if [[ $? == 0 ]]; then
branch=$(git branch | awk '/^\* / {print $2}')
echo -n "($branch) "
fi
fi
}