SPC q q
- quitSPC w /
- split window verticallySPC w
- - split window horizontallySPC 1
- switch to window 1SPC 2
- switch to window 2SPC w c
- delete current windowSPC TAB
- switch to previous bufferSPC b b
- switch buffers
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
`emacs --daemon` to run in the background. | |
`emacsclient.emacs24 <filename/dirname>` to open in terminal | |
NOTE: "M-m and SPC can be used interchangeably". | |
* Undo - `C-/` | |
* Redo - `C-?` | |
* Change case: 1. Camel Case : `M-c` | |
2. Upper Case : `M-u` | |
3. Lower Case : `M-l` |
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
var args = process.argv.slice(2) | |
var path = require('path') | |
var fs = require('fs') | |
var private = false | |
var description = '' | |
var opener = require('opener') | |
var copy = process.platform === 'darwin' | |
var open = false | |
var help = false | |
var stdin = true |
(wherever it says url.com, use your server's domain or IP)
Login to new server as root, then add a deploy user
sudo useradd --create-home -s /bin/bash deploy
sudo adduser deploy sudo
sudo passwd deploy
And Update the new password
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
# Aliases | |
# -------------------------------------------------------------------- | |
alias mv='mv -iv' | |
alias ......='cd ../../../../..' | |
alias .....='cd ../../../..' | |
alias ....='cd ../../..' | |
alias ...='cd ../..' | |
alias ..='cd ..' | |
alias cd..='cd ..' | |
alias cd.='cd ..' |
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
# Don't use FFmpeg for metadata extraction. Use FFprobe. | |
# Its output is geared toward parsabilty. | |
# Container and stream information in JSON format: | |
ffprobe -show_format -print_format json 'Serenity - HD Trailer.mp4' | |
ffprobe -show_streams -print_format json 'Serenity - HD Trailer.mp4' | |
# Human-readable values: | |
ffprobe -show_format -pretty -print_format json 'Serenity - HD Trailer.mp4' | |
# Trim video to first 30 seconds, without transcoding. |
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
(define (fact-iter x counter n) | |
(if (> counter n) | |
x | |
(fact-iter (* x counter) (+ counter 1) n))) | |
(define (fact n) | |
(fact-iter 1 1 n) | |
) |
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
# cat << EOF > /dev/null | |
# https://github.com/gpakosz/.tmux | |
# (‚Äë‚óè‚Äë‚óè)> released under the WTFPL v2 license, by Gregory Pakosz (@gpakosz) | |
# /!\ do not edit this file | |
# instead, override settings in ~/.tmux.conf.local | |
# -- general ------------------------------------------------------------------- | |
set -g default-terminal "screen-256color" # colors! |
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
See my DASH-IF presentation from October, 2014: | |
https://s3.amazonaws.com/misc.meltymedia/dash-if-reveal/index.html#/ | |
1. encode multiple bitrates with keyframe alignment: | |
ffmpeg -i ~/Movies/5D2_Portrait.MOV -s 1280x720 -c:v libx264 -b:v 1450k -bf 2 \ | |
-g 90 -sc_threshold 0 -c:a aac -strict experimental -b:a 96k -ar 32000 out.mp4 | |
My input was 30 fps = 3000 ms. If it were 29.97, then a GOP size of 90 frames will yield a base segment | |
size of 3003 milliseconds. You can make the segment size some multiple of this, e.g.: 6006, 9009, 12012. |
OlderNewer