Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
#updated ffmpeg progress indicator
#by Rupert Plumridge
#for updates visit www.prupert.co.uk
#Creative Commons Attribution-Non-Commercial-Share Alike 2.0 UK: England & Wales Licence
# Based on the ffmpegprogress bar from: http://handybashscripts.blogspot.com/2011/01/ffmpeg-with-progress-bar-re-work.html
# which was based on my initital progress script - circle of life and all that ;)
# version 2.0
# 07.04.2011
# now uses apparently better progress detection, based on duration of overall video and progress along the conversion
#!/bin/bash
#updated ffmpeg progress indicator
#by Rupert Plumridge
#for updates visit www.prupert.co.uk
#Creative Commons Attribution-Non-Commercial-Share Alike 2.0 UK: England & Wales Licence
# Based on the ffmpegprogress bar from: http://handybashscripts.blogspot.com/2011/01/ffmpeg-with-progress-bar-re-work.html
# which was based on my initital progress script - circle of life and all that ;)
# version 2.0
# 07.04.2011
# now uses apparently better progress detection, based on duration of overall video and progress along the conversion
@rakesh-sankar
rakesh-sankar / EBS-Snapshot.sh
Created August 23, 2011 08:15
A simple SHELL script which creates EBS snapshot of the volume for the given INSTANCE-ID
#!/bin/sh
# export EC2_HOME='/etc/ec2' # Make sure you use the API tools, not the AMI tools
# export EC2_BIN=$EC2_HOME/bin
# export PATH=$PATH:$EC2_BIN
# I know all of the above is good to have solution, but not re-usable
# I have captured all of the above in a particular file and lemme execute it
source /etc/environment
EC2_BIN=$EC2_HOME/bin
@rakesh-sankar
rakesh-sankar / basecamphq-wget.md
Last active August 29, 2015 14:14
Download basecamphq files via wget

An easy way to download basecamphq files via command line or wget

wget https://yoursite.basecamphq.com/.../path/to/file --no-check-certificate --http-user={your username} --http-password={your password}

make sure to update the username and the password

Better local require() paths for Node.js

Problem

When the directory structure of your Node.js application (not library!) has some depth, you end up with a lot of annoying relative paths in your require calls like:

var Article = require('../../../models/article');

Those suck for maintenance and they're ugly.

Possible solutions

@rakesh-sankar
rakesh-sankar / System Design.md
Created August 28, 2017 07:14 — forked from vasanthk/System Design.md
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
Dependences:
sudo apt-get update
sudo apt-get install build-essential
apt-get install python-dev
sudo pip install -U setuptools
Steps:
download from https://mrjbq7.github.io/ta-lib/install.html