This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM node:6 | |
ADD server.js /server.js | |
ADD cert.pem /cert.pem | |
ADD key.pem /key.pem | |
CMD ["node", "/server.js"] | |
EXPOSE 8080 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM node:6 | |
ADD server.js /server.js | |
CMD ["node", "/server.js"] | |
EXPOSE 8080 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
npm init --y | |
cat > .editorconfig <<EOF | |
root = true | |
[*.{md,js}] | |
indent_style = space | |
indent_size = 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
import Koa from 'koa'; | |
import KoaRouter from 'koa-router'; | |
import {SerialPort} from 'serialport'; | |
const path = '/dev/ttyAMA0'; | |
const options = {baudrate: 9600}; | |
const port = new SerialPort(path, options); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('babel-register')({ | |
presets: ['es2015', 'stage-0'], | |
only: 'my-cli/@(src|bin)/*.js' | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
'use strict'; | |
const path = require('path'); | |
const temp = process.cwd(); | |
process.chdir(path.resolve(__dirname, '../')); | |
require('config'); | |
process.chdir(temp); | |
require('babel-register')({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const bookshelf = Bookshelf(knex).plugin('virtuals'); | |
const alias = (property) => ({ | |
get: function () { | |
return this.get(property) | |
}, | |
set: function (value) { | |
this.set(property, value) | |
} | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm i @angular/router | |
import '@angular/router/angular1/angular_1_router'; | |
angular.module('application', [ | |
'ngComponentRouter' | |
]); |
NewerOlder