Skip to content

Instantly share code, notes, and snippets.

@jeetparikh
jeetparikh / convert-mp3-to-ogg.sh
Created October 28, 2016 03:49
Convert Audio - mp3 to ogg - usually required when embedding audio to play in browsers
#!/bin/bash
for f in *.mp3; do echo "$f"; avconv -i "$f" -c:a libvorbis -q:a 4 -threads 6 "${f%.*}.ogg"; done;
@jeetparikh
jeetparikh / convert-mp3-to-m4a.sh
Created October 28, 2016 03:51
Convert Audio - mp3 to m4a - usually required when embedding audio to play in browsers
#!/bin/bash
for f in *.mp3; do echo "$f"; ffmpeg -i "$f" -c:a aac -strict experimental "${f%.*}.m4a"; done; $SHELL
@jeetparikh
jeetparikh / convert-mp4-webm.sh
Created October 28, 2016 03:56
Convert mp4 to webm - webm files are used in video tags to extend support to maximum browsers
#!/bin/bash
for f in *.mp4; do echo "$f"; avconv -i "$f" -c:a libvorbis -q:a 4 -c:v libvpx -crf 18 -b:v 2M -qmin 0 -qmax 50 -threads 6 "${f%.*}.webm"; done;
@jeetparikh
jeetparikh / Install nwjs globally
Last active March 4, 2017 22:01
Installing nwjs through npm - Trying to install globally and having issues?
sudo npm install nwjs -g --allow-root