Article 5AZE7 Bash: script with getopts and file globbing?

Bash: script with getopts and file globbing?

by
narcissus256
from LinuxQuestions.org on (#5AZE7)
Hi,

I am trying to write a script where I need to get an input from a user from getopts.
That wouldn't be a problem, but I also need the user to select any number of files which the script should process.
Let's say that a command should look like this:

Code:mp3tag -a "Artist name" -t "Song title" -n "Track number" *.mp3How can I ensure that my mp3tag script understands file globbing? I have been scripting for a while, but can't get over this obstacle. Thank you!latest?d=yIl2AUoC8zA latest?i=Iem6DHCYVXI:vt3np5khBXU:F7zBnMy latest?i=Iem6DHCYVXI:vt3np5khBXU:V_sGLiP latest?d=qj6IDK7rITs latest?i=Iem6DHCYVXI:vt3np5khBXU:gIN9vFwIem6DHCYVXI
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments