Skip to content

Instantly share code, notes, and snippets.

View usmansbk's full-sized avatar
🏠
Working from home

Usman Suleiman Babakolo usmansbk

🏠
Working from home
View GitHub Profile
@phortuin
phortuin / postgres.md
Last active March 9, 2025 22:22
Set up postgres + database on MacOS (M1)

Based on this blogpost.

Install with Homebrew:

$ brew install postgresql@14

(The version number 14 needs to be explicitly stated. The @ mark designates a version number is specified. If you need an older version of postgres, use postgresql@13, for example.)

@hyochan
hyochan / convertBase64ToFileInWeb.ts
Last active July 18, 2022 21:49
expo image upload in both web and mobile
const fileName = uri.split('/').pop();
const fileType = mime.getType(uri);
const data: FormData = new FormData();
if (Platform.OS === 'web') {
const byteString = atob(uri.split(',')[1]);
const ab = new ArrayBuffer(byteString.length);
const arr = new Uint8Array(ab);
@Tamal
Tamal / git-ssh-error-fix.sh
Last active May 9, 2025 19:59
Solution for 'ssh: connect to host github.com port 22: Connection timed out' error
$ git clone [email protected]:xxxxx/xxxx.git my-awesome-proj
Cloning into 'my-awesome-proj'...
ssh: connect to host github.com port 22: Connection timed out
fatal: Could not read from remote repository.
$ # This should also timeout
$ ssh -T [email protected]
ssh: connect to host github.com port 22: Connection timed out
$ # but this might work
@ygotthilf
ygotthilf / jwtRS256.sh
Last active May 12, 2025 12:07
How to generate JWT RS256 key
ssh-keygen -t rsa -b 4096 -m PEM -f jwtRS256.key
# Don't add passphrase
openssl rsa -in jwtRS256.key -pubout -outform PEM -out jwtRS256.key.pub
cat jwtRS256.key
cat jwtRS256.key.pub
@kalinchernev
kalinchernev / countries
Created October 6, 2014 09:42
Plain text list of countries
Afghanistan
Albania
Algeria
Andorra
Angola
Antigua & Deps
Argentina
Armenia
Australia
Austria
@derdesign
derdesign / locales.json
Created June 16, 2012 18:54
locales.json
{
"af": "Afrikaans",
"sq": "Albanian",
"am": "Amharic",
"ar_DZ": "Arabic - Algeria",
"ar_BH": "Arabic - Bahrain",
"ar_EG": "Arabic - Egypt",
"ar_IQ": "Arabic - Iraq",
"ar_JO": "Arabic - Jordan",
"ar_KW": "Arabic - Kuwait",