Skip to content

Instantly share code, notes, and snippets.

Eric Cholis ericcholis

Block or report user

Report or block ericcholis

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:bd91e3ea0b9f1aac1b0222c8e313f1d8
Verifying my Blockstack ID is secured with the address 17mGoUU32HVtJzHf6ujL4a9NyoThxuGg2U https://explorer.blockstack.org/address/17mGoUU32HVtJzHf6ujL4a9NyoThxuGg2U
@ericcholis
ericcholis / nginx_apt_modules.sh
Last active Oct 6, 2015
Install Mainline Nginx and add modules
View nginx_apt_modules.sh
readonly RELEASE=$(lsb_release -cs)
wget http://nginx.org/keys/nginx_signing.key
sudo apt-key add nginx_signing.key
echo "deb http://nginx.org/packages/mainline/ubuntu/ $RELEASE nginx" >> /etc/apt/sources.list.d/nginx.list
echo "deb-src http://nginx.org/packages/mainline/ubuntu/ $RELEASE nginx" >> /etc/apt/sources.list.d/nginx.list
apt-get update
@ericcholis
ericcholis / nginx_install.sh
Last active Jan 27, 2017
Install nginx from source with nginScript
View nginx_install.sh
# nginx 1.9.5
# ubuntu trusty 14.04
apt-get update
apt-get upgrade
apt-get install build-essential mercurial libpcre3 libpcre3-dev libssl-dev
wget http://nginx.org/download/nginx-1.9.5.tar.gz
tar -xzvf nginx-1.9.5.tar.gz
@ericcholis
ericcholis / currency
Created Apr 14, 2015
Currency Conversion
View currency
#!/usr/bin/env bash
curl "http://www.xe.com/wap/2co/convert.cgi?Amount=$1&From=$2&To=$3" -A "Mozilla" -s | sed -n "s/.*>\(.*\) $3<.*/\1/p";
@ericcholis
ericcholis / random-string
Created Apr 14, 2015
Random String Generator
View random-string
#!/usr/bin/env bash
usage()
{
cat << EOF
usage: random-string
This script run the test1 or test2 over a machine.
OPTIONS:
View gifenc.sh
#!/bin/sh
# http://blog.pkh.me/p/21-high-quality-gif-with-ffmpeg.html
palette="/tmp/palette.png"
filters="fps=15,scale=460:-1:flags=lanczos"
ffmpeg -v warning -i $1 -vf "$filters,palettegen" -y $palette
ffmpeg -v warning -i $1 -i $palette -lavfi "$filters [x]; [x][1:v] paletteuse" -y $2
View mov2gif
#!/bin/bash
# mov2giv in out width
# mov2gif video_file_in.mov gif_file_out.gif 300
tmp_dir=/tmp/frames_$(date +%s)
mkdir $tmp_dir
if [ -z "$3" ]
then
size=600
View keybase.md

Keybase proof

I hereby claim:

  • I am ericcholis on github.
  • I am ericcholis (https://keybase.io/ericcholis) on keybase.
  • I have a public key ASB_grT_1En2_YeHVYzs13CEliX3TcFB56WBtfw3A2nRSAo

To claim this, I am signing this object:

@ericcholis
ericcholis / random-string
Created Apr 16, 2014
Random String Generator
View random-string
#!/usr/bin/env bash
usage()
{
cat << EOF
usage: random-string
This script run the test1 or test2 over a machine.
OPTIONS:
View gist:8606045
<!doctype html>
<head>
<meta charset="utf-8">
<title>jQuery Sortable</title>
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="http://netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css">
<!-- Optional theme -->
<link rel="stylesheet" href="http://netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap-theme.min.css">
</head>
You can’t perform that action at this time.