I updated my package autolike today using the following steps:
- Changed the version number in
setup.py
and modify package as necessary.
Assuming you’re in the root of your project directory, then run:
pip install -e .
I updated my package autolike today using the following steps:
setup.py
and modify package as necessary.Assuming you’re in the root of your project directory, then run:
pip install -e .
Microsoft partnered with Canonical to create Bash on Ubuntu on Windows, running through a technology called the Windows Subsystem for Linux. Below are instructions on how to set up the ssh server to run automatically at boot.
/etc/ssh/sshd_config
file by running the command sudo vi /etc/ssh/sshd_config
and do the following
Port
to 2222 (or any other port above 1000)PasswordAuthentication
to yes. This can be changed back to no if ssh keys are setup.sudo service ssh --full-restart
Deploying a node app with Forever is great...until your server restarts unexpectedly. Then your app stops running and you have to re-deploy.
To get around this, we're going to run our node app as an Upstart service. Upstart services are great, because, once started, the system auto-restarts them if they fail, or if the server restarts.
###Step 1: Create a service for your node app
ssh root@youripaddress
service node-app start
##Setup your server (this would ideally be done with automated provisioning)
npm install -g forever
##Install flightplan
npm install -g flightplan
npm install flightplan --save-dev
Here's all you have to do to add clustering to your node.js application.
cluster.js
, and run cluster.js
instead of server.js
(or /bin/www, or whatever it's called for your project)server.js
filevar cluster = require('cluster');
if (cluster.isMaster) {
// Count the machine's CPUs
var cpuCount = require('os').cpus().length;
/* ******************************************************************************************* | |
* THE UPDATED VERSION IS AVAILABLE AT | |
* https://github.com/LeCoupa/awesome-cheatsheets | |
* ******************************************************************************************* */ | |
// 0. Synopsis. | |
// http://nodejs.org/api/synopsis.html | |
@include keyframe(fadeout) { | |
0% { | |
opacity: 1; | |
} | |
100% { | |
opacity: 0; | |
} | |
} |
If someone forks a gist and you'd like to merge their changes. Do this:
clone your repo, I use the name of the gist
git clone git://gist.github.com/1163142.git gist-1163142
add a remote for the forked gist, I'm using the name of my fellow developer
git remote add aaron git://gist.github.com/1164196.git