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
function _fzf_open_project_in_code | |
fzf -m | xargs -I {} code {} | |
end | |
function fzf_open_project_in_code | |
begin | |
ghq list -p | |
echo $HOME/.config/fish | |
echo $HOME/.config/nvim | |
end | sed -e 's/\/$//' | awk '!a[$0]++' | _fzf_open_project_in_code $argv |
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
find -maxdepth 5 -type d -name "projects" -prune -printf "%T@ %Tc %p\n" | sort -n |
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
const axios = require('axios').default; | |
function getAPIClient() { | |
const axiosConfig = { | |
baseURL: 'https://csrng.net/csrng/csrng.php', | |
timeout: 5000, | |
}; | |
return axios.create(axiosConfig); | |
} |
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
version: "3.0" | |
services: | |
zookeeper: | |
image: confluentinc/cp-zookeeper | |
hostname: zookeeper | |
container_name: zookeeper | |
healthcheck: | |
test: nc -z localhost 2181 || exit -1 | |
interval: 10s |
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
import { | |
ApplicationRef, | |
ComponentFactoryResolver, | |
ComponentRef, | |
EmbeddedViewRef, | |
Injectable, | |
Injector | |
} from '@angular/core'; | |
@Injectable() |
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
const gitLogParser = require('git-log-parser'); | |
const getStream = require('get-stream'); | |
const execa = require('execa'); | |
const {GIT_NOTE_REF} = "" | |
Object.assign(gitLogParser.fields, {hash: 'H', message: 'B', gitTags: 'd', committerDate: {key: 'ci', type: Date}}); | |
/** | |
* Get the commit sha for a given tag. | |
* |
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/sh | |
COMMIT_MESSAGE=$(cat $1) | |
OUTPUT=$(echo $COMMIT_MESSAGE | awk '/^(build|ci|chore|docs|feat|fix|perf|refactor|revert|style|test)(\(.*\))?(\!|\\\!)?: .*/'); | |
if [[ ${#OUTPUT} -gt 0 ]]; then | |
exit 0; | |
else | |
echo "Mensagem de commit inválida. \n Consulte https://www.conventionalcommits.org/pt-br."; | |
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
# Install these packages (use your favorite AUR tool here) | |
yay -S minikube-bin kubectl-bin docker-machine-driver-kvm2 libvirt qemu-headless docker-machine ebtables | |
# Get libvirt going | |
sudo systemctl enable libvirtd.service | |
sudo usermod -a -G libvirt $(whoami) | |
# This fix thanks to http://blog.programmableproduction.com/2018/03/08/Archlinux-Setup-Minikube-using-KVM/ | |
sudo virsh net-autostart default |
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 | |
sudo apt-get install -y cowsay | |
cowsay "MUUU" | |
sudo shutdown -P now > /dev/null |
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 | |
# | |
# A quickndirty bash-utility to generate REST-documentation from sourcecode comments. | |
# (initially aimed at php-files, but js should also work) | |
# Basically its a c-style comment -> markdown -> html converter | |
# Dependancies: | |
# - awk | |
# - sed | |
# - bash | |
# - php |
NewerOlder