Skip to content

Instantly share code, notes, and snippets.

🕶

0xADADA 0xadada

🕶
Block or report user

Report or block 0xadada

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@0xadada
0xadada / vim-cheatsheet.md
Last active Oct 16, 2019
VIM movement, keyboard commands and shortcuts
View vim-cheatsheet.md
View placeholder.html
<!DOCTYPE html>
<html>
<meta charset="utf-8">
<title>Placeholder</title>
<img data-size="150x300" alt="Asian" data-show-markup>
<img data-size="150x300" alt="Bengal">
<script src="placeholder.js"></script>
</html>
View talk-using-ember-fastboot-in-weird-ways.server.js
// LOL this is not production code, but "inspired" by production code
const FastBoot = require('fastboot');
const FastBootAppServer = require('fastboot-app-server');
const server = new FastBootAppServer({
gzip: true, // enable gzip compression
beforeMiddleware(app) {
app.use(async (request, response, next) => {
if (request.path === '/render') {
@0xadada
0xadada / brew-pin-readline.sh
Last active Apr 8, 2019
pin homebrew readline to version 7.0.5, permanantly
View brew-pin-readline.sh
#!/usr/bin/env bash
# Uninstall this incompatible version
brew uninstall --ignore-dependencies readline
# Go to the local clone of homebrew-core
pushd "$(brew --prefix)/Homebrew/Library/Taps/homebrew/homebrew-core"
# Move to the homebrew-core revision that had 7.0.5, last version before 8
# see: https://raw.githubusercontent.com/Homebrew/homebrew-core/b1bd1c4a62e1336422de3614d1fc49ffbce589a8/Formula/readline.rb
@0xadada
0xadada / sum.js
Last active Oct 21, 2018
A chained invocable, n-argument, sum function in javascript
View sum.js
/* This discussion was started on Reddit about a job interview question:
* Question: How would you make this work?
* add(2, 5); // 7
* add(2)(5); // 7
* url: https://www.reddit.com/r/javascript/comments/2t6riw/a_frontend_developer_interview_question_thats/cnxhnow/
*/
/**
* sum Returns the sums of N arguments.
*
@0xadada
0xadada / cloudSettings
Last active Oct 4, 2018
Visual Studio Code Settings Sync Gist
View cloudSettings
{"lastUpload":"2018-10-04T16:15:21.511Z","extensionVersion":"v3.1.2"}
@0xadada
0xadada / github-latest-release.sh
Created Jul 8, 2015
Download latest GitHub project release
View github-latest-release.sh
curl -LOk `curl --silent https://api.github.com/repos/jasmine/jasmine/releases/latest | /usr/bin/awk '/browser_download_url/ { print $2 }' | /usr/bin/sed 's/"//g'`
@0xadada
0xadada / old-fashioned.package.json
Last active Mar 15, 2018
The Old Fashioned Cocktail Recipe, as specified as an NPM package (yes, these are real NPM dependencies)
View old-fashioned.package.json
{
"name": "Old Fashioned",
"version": "1.0.0",
"description": "The Old Fashioned Cocktail",
"scripts": {
"build": "dissolve && mix && stir && pour && serve",
"dissolve": "cat muddler bitters sugar > mixer && muddle",
"mix": "cat bourbon > mixer",
"stir": "cycle spoon --time 30s",
"pour": "pour mixer > tumbler",
@0xadada
0xadada / filevault-password-user-account.md
Created Jan 24, 2018
Update FileVault password with user account password
View filevault-password-user-account.md

Update FileVault password with user account password

sudo fdesetup remove -user username
sudo fdesetup add -usertoadd username
You can’t perform that action at this time.