In this article, I will share some of my experience on installing NVIDIA driver and CUDA on Linux OS. Here I mainly use Ubuntu as example. Comments for CentOS/Fedora are also provided as much as I can.
| import express from 'express'; | |
| const app = express(); | |
| if (IS_DEV) { | |
| require('piping')(); | |
| } | |
| //express routes, etc. | |
| export default app; |
| #!/bin/bash | |
| PARAMS=('-m 6 -q 70 -mt -af -progress') | |
| if [ $# -ne 0 ]; then | |
| PARAMS=$@; | |
| fi | |
| cd $(pwd) |
| %YAML 1.2 | |
| --- | |
| # See http://www.sublimetext.com/docs/3/syntax.html | |
| name: JavaScript NG | |
| file_extensions: | |
| - js | |
| - ng.js | |
| scope: source.js.ng | |
| contexts: | |
| main: |
| module.exports = function (shipit) { | |
| require('shipit-deploy')(shipit); | |
| shipit.initConfig({ | |
| default: { | |
| workspace: '../shipit-temp-folder', | |
| deployTo: '~/express4-es6', | |
| branch: "shipit", | |
| repositoryUrl: 'https://github.com/khanghoang/express4-es6.git', | |
| ignores: ['.git', 'node_modules'], |
This is a collection of the most common commands I run while administering Postgres databases. The variables shown between the open and closed tags, "<" and ">", should be replaced with a name you choose. Postgres has multiple shortcut functions, starting with a forward slash, "". Any SQL command that is not a shortcut, must end with a semicolon, ";". You can use the keyboard UP and DOWN keys to scroll the history of previous commands you've run.
http://www.postgresql.org/download/linux/ubuntu/ https://help.ubuntu.com/community/PostgreSQL
Deploy key is a SSH key set in your repo to grant client read-only (as well as r/w, if you want) access to your repo.
As the name says, its primary function is to be used in the deploy process in replace of username/password, where only read access is needed. Therefore keep the repo safe from the attack, in case the server side is fallen.
- Generate a ssh key
| // Promise.all is good for executing many promises at once | |
| Promise.all([ | |
| promise1, | |
| promise2 | |
| ]); | |
| // Promise.resolve is good for wrapping synchronous code | |
| Promise.resolve().then(function () { | |
| if (somethingIsNotRight()) { | |
| throw new Error("I will be rejected asynchronously!"); |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.