How to use getopts to parse a script options

Posted by linuxer on Aug 26, 2017 6:07 PM EDT
linuxconfig.org; By Egidio Docile
Mail this story
Print this story

Modifying a bash script behavior via runtime options, just like we normally do with command line programs, can be very useful. The bash shell provides the getopts builtin command, a standard way to achieve this. How to use it is what we will learn in this tutorial.

Full Story

  Nav
» Read more about: Story Type: Tutorial; Groups: Developer, Linux

« Return to the newswire homepage

This topic does not have any threads posted yet!

You cannot post until you login.