Skip to content

Instantly share code, notes, and snippets.

View bayrock's full-sized avatar
🔎
Exploring the world wide web.

Bay bayrock

🔎
Exploring the world wide web.
View GitHub Profile
@AdvaithD
AdvaithD / gist:fcdfbf5a2707ca3b022b65287c9c036f
Created November 1, 2017 01:45
stop tracking 'node_modules' in a git repo
$ touch .gitignore
$ nano .gitignore
Add 'node_modules' to .gitignore file
$ git rm -r --cached node_modules
$ git commit -m 'Stopped tracking node modules'
$ git push -u origin master
@willrstern
willrstern / node-ubuntu-upstart-service.md
Last active August 17, 2023 10:15
Run Node.js App as Ubuntu Upstart Service

###The Issue With Forever Forever is great for running node services, with a minor setback: the word "forever" doesn't apply to system reboots.

###The solution, run node apps as a system service logged in as root

vim /etc/init/node-app.conf

Contents for node-app.conf

// Includes functions for exporting active sheet or all sheets as JSON object (also Python object syntax compatible).
// Tweak the makePrettyJSON_ function to customize what kind of JSON to export.
var FORMAT_ONELINE = 'One-line';
var FORMAT_MULTILINE = 'Multi-line';
var FORMAT_PRETTY = 'Pretty';
var LANGUAGE_JS = 'JavaScript';
var LANGUAGE_PYTHON = 'Python';