This file contains 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
docker build -t friendlyname . # Create image using this directory's Dockerfile | |
docker run -p 4000:80 friendlyname # Run "friendlyname" mapping port 4000 to 80 | |
docker run -d -p 4000:80 friendlyname # Same thing, but in detached mode | |
docker exec -it [container-id] bash # Enter a running container | |
docker ps # See a list of all running containers | |
docker stop <hash> # Gracefully stop the specified container | |
docker ps -a # See a list of all containers, even the ones not running | |
docker kill <hash> # Force shutdown of the specified container | |
docker rm <hash> # Remove the specified container from this machine | |
docker rm $(docker ps -a -q) # Remove all containers from this machine |
This file contains 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
/* ******************************************************************************************* | |
* GLOBAL OBJECTS > ARRAY | |
* https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array | |
* ******************************************************************************************* */ | |
// Global object: properties | |
Array.length // Reflects the number of elements in an array | |
// Global object: methods |
This file contains 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
## | |
# @server studio | |
# @host hackisition.com | |
# @desc nginx host rules | |
# @author Julien Le Coupanec <julien@gentlenode.com> | |
## | |
# HTTP Server | |
server { | |
listen 80; |
This file contains 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
/* ******************************************************************************************* | |
* GLOBAL CONFIG | |
* Vue.config is an object containing Vue’s global configurations. | |
* You can modify its properties listed below before bootstrapping your application. | |
* https://vuejs.org/v2/api/#Global-Config | |
* ******************************************************************************************* */ | |
// Configure whether to allow vue-devtools inspection | |
Vue.config.devtools = true |
This file contains 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
// Restify Server CheatSheet. | |
// More about the API: http://mcavage.me/node-restify/#server-api | |
// Install restify with npm install restify | |
// 1.1. Creating a Server. | |
// http://mcavage.me/node-restify/#Creating-a-Server | |
var restify = require('restify'); |
This file contains 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
# ***************************************************************************** | |
# UPDATED VERSION AVAILABLE HERE: | |
# https://github.com/LeCoupa/awesome-cheatsheets/blob/master/tools/nanobox_cli.sh | |
# ***************************************************************************** | |
# ***************************************************************************** | |
# LOCAL ENVIRONMENT | |
# ***************************************************************************** |
This file contains 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
# Atom Cheatsheet. | |
# Project Key Bindings. | |
- 'cmd-shift-p': open the command palette. | |
- 'cmd-p' or 'cmd-t': open the fuzzy finder to find a file. | |
- 'cmd-b': look for a file that is already open. | |
- 'cmd-shift-b': search the list of files modified and untracked in your project repository. | |
- 'ctrl-0': open and focus the the tree view. |
This file contains 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
############################################################################## | |
# SHELL ALIASES | |
# ADD TO .bashrc OR .zshrc | |
############################################################################## | |
# Capacitor | |
alias csync="npx cap sync" | |
alias cios="npx cap open ios" | |
alias cand="npx cap open android" |
This file contains 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 CheatSheet. | |
# Super easy intall: npm comes with node now. | |
# To create your own npm package: https://www.npmjs.org/doc/misc/npm-developers.html | |
# More: https://www.npmjs.org/doc/ | |
# 1. NPM Command Lines. | |
# Local mode is the default. | |
# Use --global or -g on any command to operate in global mode instead. |
This file contains 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
# SYNTAX: | |
var pattern = new RegExp(pattern, attributes); # attributes: g (global); i (case-sensitive); m (multiline matches) | |
var pattern = /pattern/attributes; # same as above | |
# BRACKETS: | |
[...]: Any one character between the brackets. | |
[^...]: Any one character not between the brackets. |