This file contains 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
# This file has been auto-generated by i3-config-wizard(1). | |
# It will not be overwritten, so edit it as you like. | |
# | |
# Should you change your keyboard layout some time, delete | |
# this file and re-run i3-config-wizard(1). | |
# | |
# i3 config file (v4) | |
# | |
# Please see https://i3wm.org/docs/userguide.html for a complete reference! |
This file contains 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
# This script searchs for the application with the | |
# given classname. There are three possibilities: | |
# 1. If the app is not open, opens it | |
# 2. If the app is open but is not the active window, activates it | |
# 3. If the app is open AND is the active window, minimizes it# | |
# The idea is to assign this script to keyboard shortcuts in order | |
# to launch/activate/minimize a common used application quickly | |
# | |
# Requieres 'xdotool' installed |
This file contains 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
//PHP array containing forenames. | |
$names = array( | |
'Joao', | |
'Alberto', | |
'Jose', | |
'Raimundo', | |
'Carlos', | |
'Fabio', | |
'David', | |
'Mell', |
This file contains 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
docker network rm $(docker network ls | grep "foo" | awk '/ / { print $1 }') |
This file contains 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 | |
# Stop all containers | |
docker stop $(docker ps -a -q) | |
# Delete all containers | |
docker rm $(docker ps -a -q) | |
# Delete all images | |
docker rmi $(docker images -q) |
This file contains 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
$ sudo usermod -aG docker $USER | |
$ sudo setfacl -m user:$USER:rw /var/run/docker.sock |
This file contains 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 gulp file using gulp-livereload | |
* $ gulp -v | |
* CLI version 3.9.1 | |
* Local version 3.9.1 | |
* | |
* run example: | |
* $ gulp watch | |
* | |
* if you have errors, check first if you have fs.inotify.max_user_watches configured appropriate |
This file contains 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 | |
if [ "$#" -ne 1 ] | |
then | |
echo "Description: Split mp4 file with 14s each - for using with instagram stories" | |
echo "Usage: $0 <filename>" | |
exit 1 | |
fi | |
echo $1 |
This file contains 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 | |
# 99% of credits by https://unix.stackexchange.com/a/192021/235601 | |
if [ "$#" -ne 1 ] | |
then | |
echo "Description: Convert mp4 file to instagram portrait format (720wx1080h)" | |
echo "Usage: $0 <filename>" | |
exit 1 | |
fi |
This file contains 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
# | |
# ~/.bashrc | |
# | |
[[ $- != *i* ]] && return | |
colors() { | |
local fgc bgc vals seq0 | |
printf "Color escapes are %s\n" '\e[${value};...;${value}m' |
NewerOlder