Check and optimize your bash scripts

Every day solutions to every day challenges. + Brilliant stuff

Moderators: b1o, jkerr82508

Forum rules
Please feel free to post your tip it does not have to be advanced. Also ask questions directly related to the tip here. But do not start new threads with questions or ask for help here. That is what the help section is for. forum rules: http://bjoernvold.com/forum/viewtopic.php?f=8&t=568
User avatar
viking60
Über-Berserk
Posts: 9351
Joined: 14 Mar 2010, 16:34

Check and optimize your bash scripts

Postby viking60 » 29 Oct 2014, 16:17

So I have this working bash script but I want to make sure that it is optimal.
I found
:A
http://www.shellcheck.net/
Just paste your code in there and you will get valuable tips. It will by no means replace your head, and sometimes come op with solutions that are plain wrong in your script, but for the most part you will be able to optimise your scripts with it.
Manjaro 64bit on the main box -Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz and nVidia Corporation GT200b [GeForce GTX 275] (rev a1. + Centos on the server - Arch on the laptop.
"There are no stupid questions - Only stupid answers!"

Return to “Tips & Tricks”