Skip to content

Instantly share code, notes, and snippets.

@ecpplus
Created July 4, 2013 09:02
Show Gist options
  • Select an option

  • Save ecpplus/5926110 to your computer and use it in GitHub Desktop.

Select an option

Save ecpplus/5926110 to your computer and use it in GitHub Desktop.
replace tab -> 4 spaces all files.
Dir.glob(["**/*.h", "**/*.m"]) do |f|
cmd = "expand -t4 #{f} > #{f}.tmp && mv #{f}.tmp #{f}"
#p cmd
`#{cmd}`
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment