Skip to content

Instantly share code, notes, and snippets.

@joakin
Created January 17, 2012 15:26
Show Gist options
  • Save joakin/1627053 to your computer and use it in GitHub Desktop.
Save joakin/1627053 to your computer and use it in GitHub Desktop.
Bash script to beautify all the js files in a folder using js-beautify
#!/bin/bash
PATZ=$1
for i in $(find $PATZ -name "*.js")
do
js-beautify $i > "$i.out" && mv "$i.out" $i
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment