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
[user] | |
name = <ur-name> | |
email = <ur-email> | |
[core] | |
editor = vim -f | |
excludesfile = /Users/<name-of-mac>/.gitignore_global | |
[color] | |
ui = true | |
[alias] | |
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cd) %C(bold blue)<%an>%Creset' --abbrev-commit |
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
# JavaScript | |
node_modules | |
.next | |
# Mac | |
.DS_Store |
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
for f in $(ls); do | |
cd $f && git fetch --prune origin && git reset --hard origin/$main_branch_name && cd -; | |
done |
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 fs = require("fs"); | |
// "4\n1\n2\n5\n3" | |
const input = fs.readFileSync(0).toString(); | |
// [4, 1, 2, 5, 3] | |
const lines = input.split("\n").map((n) => parseInt(n, 10)); | |
const T = parseInt(lines[0], 10); |
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 structured_var_dump($arr) { | |
return '<pre>' . var_export($arr, true) . '</pre>'; | |
} |
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 structured_var_dump($arr) { | |
return '<pre>' . var_export($arr, true) . '</pre>'; | |
} |
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
#!/usr/bin/env bash | |
set -eu -o pipefail | |
# Script expects these binaries to be present: | |
# - wget | |
# - node | |
# Tested on Mac. | |
# Example: | |
# | |
# bash sizeOfStringInUrl.sh nextjs.org "\bcreateElement\b" |
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 fs = require('fs'); | |
const input = fs.readFileSync(0).toString(); |
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
{ | |
"editor.renderWhitespace": "boundary", | |
"workbench.colorTheme": "Framer Syntax", | |
"workbench.editor.tabSizing": "shrink", | |
"window.zoomLevel": 3, | |
"explorer.confirmDragAndDrop": false, | |
"files.trimTrailingWhitespace": true, | |
"files.insertFinalNewline": true, | |
"workbench.sideBar.location": "right", | |
"editor.tabSize": 2, |
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
#!/usr/bin/env bash | |
git clean -fxd | |
cd <package-name> | |
yarn | |
2>&1 yarn lint | grep -vq error |
NewerOlder