Skip to content

Instantly share code, notes, and snippets.

💭
‾\_(ツ)_/‾

Nate Clark n8io

View GitHub Profile
View gitmoji.js
const setEmojiCopy = () => {
[
...document
.querySelectorAll('.emoji-icon.gitmoji')
]
.forEach(el =>
el.setAttribute('data-clipboard-text', el.innerText)
);
};
@n8io
n8io / .babelrc
Last active Dec 15, 2017
Prettier setup (tested w/Atom and prettier-atom plugin)
View .babelrc
{
"presets": [ "env" ]
}
@n8io
n8io / processing-server.sh
Last active Feb 11, 2017
One script to rule them all!
View processing-server.sh
#!/bin/bash
export \
GIST_BASE_URL="https://gist.githubusercontent.com" \
GIST_USER="n8io" \
GIST_ID="1774060420c77104fb56b121e28aed8b" \
HASH="2364996eb8b0137d40fb3e9ec74c409bb70b9df5"; \
bash <(curl -s ${GIST_BASE_URL}/${GIST_USER}/${GIST_ID}/raw/${HASH}/99.reset.sh) && \
bash <(curl -s ${GIST_BASE_URL}/${GIST_USER}/${GIST_ID}/raw/${HASH}/00.apt-get-update.sh) && \
bash <(curl -s ${GIST_BASE_URL}/${GIST_USER}/${GIST_ID}/raw/${HASH}/01.bashrc) && \
bash <(curl -s ${GIST_BASE_URL}/${GIST_USER}/${GIST_ID}/raw/${HASH}/02.mount-big-drive.sh) && \
View helpful-scp-commands.sh
ssh-copy-id -i ~/.ssh/[id_ras.pub] "[-p port] [user@][server]" # Setup ssh auth on remote server
scp [-P port] [local file path] [user@][server]:[server destination dir] # move file remotely via ssh
View docker-dev.md

Local Docker deployment of a NodeJs Application

Running your nodejs app locally with Docker. A docker newbie's guide to docker tinkering.

Install Requirements

  1. Virtualbox
  2. Docker Toolbox
  3. A runnable nodejs project with a valid package.json (including an npm start script)

Getting started

TLDR; Resulting code here: docker-nodejs-example

@n8io
n8io / .stylintrc
Last active Aug 29, 2015
A sample config file for the Stylint (Stylus) linter
View .stylintrc
{
"blocks": false,
"brackets": {
"error": true,
"expect": "never"
},
"colons": {
"error": true,
"expect": "never"
},
@n8io
n8io / .jshintrc
Created Aug 10, 2015
A sample config file for the JSHINT linter.
View .jshintrc
{
"laxbreak": true
}
@n8io
n8io / .jscsrc
Created Aug 10, 2015
A sample config file for the JSCS linter
View .jscsrc
{
"disallowEmptyBlocks": true,
"disallowKeywords": [ "with" ],
"disallowMultipleLineBreaks": true,
"disallowMultipleLineStrings": true,
"disallowMultipleVarDecl": true,
"disallowMixedSpacesAndTabs": true,
"disallowNewlineBeforeBlockStatements": true,
"disallowOperatorBeforeLineBreak": [
"+",
@n8io
n8io / sublime-text-3-plugins.md
Last active Sep 17, 2015
A compiled list of Sublime Text plugins that make UX development easier.
You can’t perform that action at this time.