I know we have a decent chunk of IT types on here, so it seemed like a good place to ask....
I was recently asked to update a large chunk of scripts (a combination of perl and bash), and in doing so discovered that they are unreadable due to the atrocious amount of white space used. For example, in one section there is 143 spaces before the actual line starts. If this was just one script that would be one thing, but across this many...
I know I could do something like "sed 's/^[ \t]*//;s/[ \t]*$//'", but that leaves me with a mess as well. Anyone know of a way/utility/script/anything to rebalance these files?
I was recently asked to update a large chunk of scripts (a combination of perl and bash), and in doing so discovered that they are unreadable due to the atrocious amount of white space used. For example, in one section there is 143 spaces before the actual line starts. If this was just one script that would be one thing, but across this many...
I know I could do something like "sed 's/^[ \t]*//;s/[ \t]*$//'", but that leaves me with a mess as well. Anyone know of a way/utility/script/anything to rebalance these files?