brew install mongodb
Set up launchctl to auto start mongod
$ ln -sfv /usr/local/opt/mongodb/*.plist ~/Library/LaunchAgents
/usr/local/opt/mongodb/ is a symlink to /usr/local/Cellar/mongodb/x.y.z (e.g., 2.4.9)
| string meaning | |
| ------ ------- | |
| @reboot Run once, at startup. | |
| @yearly Run once a year, "0 0 1 1 *". | |
| @annually (same as @yearly) | |
| @monthly Run once a month, "0 0 1 * *". | |
| @weekly Run once a week, "0 0 * * 0". | |
| @daily Run once a day, "0 0 * * *". | |
| @midnight (same as @daily) | |
| @hourly Run once an hour, "0 * * * *". |
| [ SERVER PART ] (for desktop, scroll down) | |
| sudo apt install -y build-essential libssl-dev libncurses5-dev libpcap-dev git apt-transport-https ca-certificates | |
| git config --global core.autocrlf false | |
| git config --global core.longpaths true | |
| // NodeJS | |
| cd /tmp | |
| curl -sL https://deb.nodesource.com/setup_10.x -o nodesource_setup.sh | |
| sudo bash nodesource_setup.sh |
| <div id="details"> | |
| <h1 id='head'>{user.firstName}</h1> | |
| <h2 rv-text='user.surname'></h2> | |
| <input id='input' type='text' rv-value="user.firstName"> | |
| </div> | |
| <script src='rivets.js'></script> | |
| <script> | |
| var user = { |
| #!/bin/sh | |
| set -e | |
| set -x | |
| for package in $(npm -g outdated --parseable --depth=0 | cut -d: -f3) | |
| do | |
| npm -g install "$package" | |
| done |
| /** | |
| * SVG Fixer | |
| * | |
| * Fixes references to inline SVG elements when the <base> tag is in use. | |
| * Firefox won't display SVG icons referenced with | |
| * `<svg><use xlink:href="#id-of-icon-def"></use></svg>` when the <base> tag is on the page. | |
| * | |
| * More info: | |
| * - http://stackoverflow.com/a/18265336/796152 | |
| * - http://www.w3.org/TR/SVG/linking.html |
| /* | |
| A full list of simple easing equations inspired by GIST from greweb - https://gist.github.com/gre/1650294 | |
| Equations source - http://gsgd.co.uk/sandbox/jquery/easing/ | |
| */ | |
| { | |
| linear: function(t) { | |
| return t | |
| }, | |
| inQuad: function(t) { |
| var express = require('express'); | |
| var app = express(); | |
| var fs = require('fs'); | |
| app.listen(3000, function() { | |
| console.log("[NodeJS] Application Listening on Port 3000"); | |
| }); | |
| app.get('/api/play/:key', function(req, res) { | |
| var key = req.params.key; |
| #For Ubuntu 16.04 LTS | |
| #First you need to know where google-chrome is installed. To find out run: | |
| which google-chrome | |
| #For my case, google-chrome is installed inside both /usr/bin/google-chrome and /usr/bin/google-chrome-stable. | |
| #I decided to use the stable version. | |
| #Now, list the domains that you'd like chrome to treat as secure. Make sure that you have access to the folder following --user-data-dir. I used $HOME for convenience. | |
| #Run the following command: |