Skip to content

Instantly share code, notes, and snippets.

View wilcorrea's full-sized avatar
🚀
// TODO: be life good

William Correa wilcorrea

🚀
// TODO: be life good
View GitHub Profile
@npearce
npearce / install-docker.md
Last active March 28, 2024 11:51
Amazon Linux 2 - install docker & docker-compose using 'sudo amazon-linux-extras' command

UPDATE (March 2020, thanks @ic): I don't know the exact AMI version but yum install docker now works on the latest Amazon Linux 2. The instructions below may still be relevant depending on the vintage AMI you are using.

Amazon changed the install in Linux 2. One no-longer using 'yum' See: https://aws.amazon.com/amazon-linux-2/release-notes/

Docker CE Install

sudo amazon-linux-extras install docker
sudo service docker start
@paolocarrasco
paolocarrasco / README.md
Last active March 28, 2024 10:27
How to understand the `gpg failed to sign the data` problem in git

Problem

You have installed GPG, then tried to commit and suddenly you see this error message after it:

error: gpg failed to sign the data
fatal: failed to write commit object

Debug

@GusAntoniassi
GusAntoniassi / README.md
Last active March 15, 2024 06:05
Configure autocompletion to kubectl with zsh

kubectl with ZSH (oh-my-zsh)

How to configure

Use the following commands to add the kubectl autocomplete to zsh:

mkdir -p ~/.oh-my-zsh/custom/plugins/kubectl-autocomplete/
kubectl completion zsh > ~/.oh-my-zsh/custom/plugins/kubectl-autocomplete/kubectl-autocomplete.plugin.zsh
@armand1m
armand1m / Dockerfile
Last active March 10, 2024 14:54
Yarn cache compatible Dockerfile
FROM alpine
RUN apk add --update --no-cache nodejs
RUN npm i -g yarn
ADD package.json yarn.lock /tmp/
ADD .yarn-cache.tgz /
RUN cd /tmp && yarn
RUN mkdir -p /service && cd /service && ln -s /tmp/node_modules
@scottopell
scottopell / fix_exfat_drive.md
Last active March 9, 2024 12:08
Fix corrupted exFAT disk macOS/OSX

exFAT support on macOS seems to have some bugs because my external drives with exFAT formatting will randomly get corrupted.

Disk Utility is unable to repair this at first, but the fix is this:

  1. Use diskutil list to find the right drive id.
  2. You want the id under the IDENTIFIER column, it should look like disk1s1
  3. Run sudo fsck_exfat -d <id from above>. eg sudo fsck_exfat -d disk1s3
  4. -d is debug so you'll see all your files output as they're processed.
  5. Answer YES if it gives you the prompt Main boot region needs to be updated. Yes/No?
@Restuta
Restuta / framework-sizes.md
Last active March 7, 2024 00:01
Sizes of JS frameworks, just minified + minified and gzipped, (React, Angular 2, Vue, Ember)

Below is the list of modern JS frameworks and almost frameworks – React, Vue, Angular, Ember and others.

All files were downloaded from https://cdnjs.com and named accordingly. Output from ls command is stripped out (irrelevant stuff)

As-is (minified)

$ ls -lhS
566K Jan 4 22:03 angular2.min.js
@iguit0
iguit0 / startup.sh
Last active February 25, 2024 16:38
My scripts for APT distros
sudo apt-get update
echo 'installing curl'
sudo apt install curl -y
echo 'installing git'
sudo apt install git -y
echo "What name do you want to use in GIT user.name?"
echo "For example, mine will be \"Igor Lucio\""
@helisoncruz
helisoncruz / lista-de-bancos-brasileiros.sql
Last active February 25, 2024 00:42
Lista de Bancos Brasileiros em SQL/MySql
INSERT INTO `bancos` (`cod`, `banco`) VALUES (001,'001 - BANCO DO BRASIL S/A');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (002,'002 - BANCO CENTRAL DO BRASIL');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (003,'003 - BANCO DA AMAZONIA S.A');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (004,'004 - BANCO DO NORDESTE DO BRASIL S.A');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (007,'007 - BANCO NAC DESENV. ECO. SOCIAL S.A');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (008,'008 - BANCO MERIDIONAL DO BRASIL');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (020,'020 - BANCO DO ESTADO DE ALAGOAS S.A');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (021,'021 - BANCO DO ESTADO DO ESPIRITO SANTO S.A');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (022,'022 - BANCO DE CREDITO REAL DE MINAS GERAIS SA');
INSERT INTO `bancos` (`cod`, `banco`) VALUES (024,'024 - BANCO DO ESTADO DE PERNAMBUCO');
@karmi
karmi / git-hosting-apache.conf
Created July 21, 2010 07:43
Configuration for hosting Git repositories with Apache 2.x
# ----------------------------------------------------------
# Configuration for hosting Git repositories with Apache 2.x
# ----------------------------------------------------------
#
# This setup provides "dual URLS", where URL like <http://git.example.com/my_repository.git>
# loads Gitweb in the browser and the same URL can be used in commands like `git clone` and `git remote add`.
# It was compiled from some sources on the internet and further customized/tuned.
#
# Please see documentation for:
#
@thomasfr
thomasfr / Git push deployment in 7 easy steps.md
Last active February 14, 2024 05:58
7 easy steps to automated git push deployments. With small and configurable bash only post-receive hook