tmux
sed (Stream Editor)
sed s/-/\ /g
substitute globally (- to spaces in this case)
users and groups
- list all users:
cut -d: -f1 /etc/passwd
ORcompgen -u
- list all groups:
compgen -g
// thanks sleepycat https://github.com/sleepycat/mapboxgl-webpack-example | |
import mapboxgl from 'mapbox-gl' | |
mapboxgl.accessToken = 'pk.eyJ1IjoibWlrZXdpbGxpYW1zb24iLCJhIjoibzRCYUlGSSJ9.QGvlt6Opm5futGhE5i-1kw'; | |
var map = new mapboxgl.Map({ | |
container: 'map', // container id | |
style: 'mapbox://styles/mapbox/streets-v8', //stylesheet location | |
center: [-74.50, 40], // starting position | |
zoom: 9 // starting zoom |
#!/usr/bin/env sh | |
# Usage: call with docker container name, requires stat | |
# E.g. sudo ./logs-per-hour project_service_1 | |
id=$(docker inspect $1 --format "{{ .ID }}") | |
started_date=$(docker inspect $id --format "{{ .Created}}") | |
started=$(date +%s -d ${started_date}) | |
now=$(date +%s) |
{ | |
"scripts": { | |
"start": "webpack-dev-server", | |
"build": "NODE_ENV=production webpack" | |
}, | |
"devDependencies": { | |
"babel-core": "^6.18.2", | |
"babel-loader": "^6.2.8", | |
"babel-plugin-add-module-exports": "^0.2.1", | |
"babel-plugin-glslify": "^2.0.0", |
tmux
sed (Stream Editor)
sed s/-/\ /g
substitute globally (- to spaces in this case)users and groups
cut -d: -f1 /etc/passwd
OR compgen -u
compgen -g
'use strict' | |
const path = require('path') | |
const webpack = require('webpack') | |
const HtmlWebpackPlugin = require('html-webpack-plugin') | |
const CopyWebpackPlugin = require('copy-webpack-plugin') | |
const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer') | |
const whsAliases = require('whs/tools/alias.js') | |
const isProd = process.env.NODE_ENV === 'production' |
const links = [{ | |
title: 'About', | |
position: [2, 1.5, 0], | |
color: 0x00ff00 | |
}, | |
{ | |
title: 'Contact', | |
position: [2, -1.5, 0], | |
color: 0xff0000 | |
}, |
'use strict' | |
const width = 512 | |
const height = 512 | |
const fs = require('fs') | |
const { PNG } = require('pngjs') | |
const gl = require('gl')(width, height, { preserveDrawingBuffer: true }) | |
const regl = require('regl')(gl) |
version: '2' | |
services: | |
drone: | |
image: drone/drone:0.4 | |
restart: always | |
env_file: drone/dronerc | |
privileged: true # allows us to run a docker daemon | |
volumes: | |
- data:/var/lib/drone | |
- /var/run/docker.sock:/var/run/docker.sock |
class Shell extends WHS.Component { | |
static instructions = { | |
position: [ 'x', 'y', 'z' ] | |
} | |
constructor(params = {}) { | |
super(params, WHS.Component.defaults, Shell.instructions) | |
const { radius, detail } = params.geometry |