Beginning Shell Scripting Paperback – Apr 29 2005
Customers Who Bought This Item Also Bought
No Kindle device required. Download one of the Free Kindle apps to start reading Kindle books on your smartphone, tablet, and computer.
To get the free app, enter your e-mail address or mobile phone number.
From the Back Cover
Beginning Shell Scripting
Shell scripts give you the power to automate tedious daily tasks, improve your work capabilities, and get more out of your computers. Whether you are working on Mac OS®X, Linux®, Unix®, or Windows®, this book presents complete shell scripting instructions, robust code examples, and full scripts for customizing your operating system.
You'll first learn the basics of shell scripts, including what they are, how they run, and how you can design executable commands from them. You'll then progress to more advanced scripting topics, such as using awk and sed commands, building command pipelines, and creating functions. This book covers everything you'll need to know about shells and scripting in order to begin writing your own.
What you will learn from this book
- How shells work and how to find them on your system
- Steps for passing data to a shell script and modifying your environment
- Techniques for creating, reading, enhancing, and removing files
- How to query about processes and gather information about what is running on your system
- Tips for editing and debugging scripts
- Ways to monitor and administer your system using scripts
- How to call on your desktop applications from scripts
Who this book is for
This book is for anyone who wants to get more out of their computer systems, including Mac OS X, Linux, Unix, and Windows users.
Wrox Beginning guides are crafted to make learning programming languages and technologies easier than you think, providing a structured tutorial format that will guide you through all the techniques involved.
About the Author
Eric Foster-Johnson (Arden Hills, MN) is a veteran programmer who works daily with Linux, Unix, Windows, Mac OS X, and other operating systems. By day, he writes enterprise Java software for ObjectPartners, a Minnesota consulting firm. He has authored a number of Linux and Unix titles including Red Hat RPM Guide, Teach Yourself Linux, Teach Yourself Unix, and Perl Modules.
John C. Welch (Boston, MA) has more than ten years of Mac experience in the trenches of the IT world. He packs the hall at Macworld Expo where he’s a regular speaker, sharing his experiences and knowledge on using Macs effectively in business and enterprise IT environments. John’s articles are frequently featured in MacTech Magazine and WorkingMac.com, and he is semi-regularly featured on The Mac Show conducting interviews with the geekier side of the Mac community. He’s recently been touring the country presenting seminars on Mac OS X administration to IT professionals from coast to coast.
Micah Anderson has been a Unix system administrator for more than a decade. He is a Debian GNU/Linux developer and works as an independent consultant building alternative communication infrastructure and supporting the technology needs of positive grassroots alternatives.
Inside This Book(Learn More)
Most Helpful Customer Reviews on Amazon.com (beta)
The author hates Windows and never misses a chance to let you know this - I wish the author had left the personal views and OS politics out ...
or just not covered Windows at all. (Which by the way isn't covered at all - other than the Cygwin program and why the author hates Windows so much.)
This book uses the BASH shell almost exclusively with some "oh yea, this syntax won't work on the C Shell" thrown in.
the Korn & Z Shells are treated like they don't even exist - and BASH is always the only way to go.
The book at about Chapter 3 becomes more of a "look what i can do" and "here write this out in a text editor and save the file as this", without much explaInation as to why it happens that way and what the syntax introduced means. With some syntax being introduced in a script and never being explained or referenced at all.
The terms the Author uses are as technical as you can get (like Palindromic Scripting" instead of saying a number reads the same forward and backwards (ex. 15851) or even symmetrical would have been a better term for a newbie. Luckily i know what Palindromic numbers are.
Not a good book for Newbies ... too much un-explained out of nowhere syntax - related in the most technical terms the Author could find. It reads more like a technical manual on something ... not a how to learn from the ground up book. Your just as well off reading the MAN pages.
In looking forward to the chapter "Scripting with Files", I see some minor notes on chmod and file test conditionals for files. I don't see more advance topics like using find or stat or related topics, and instead we are presented with a conversation on Next file systems, Mac OS X file systems (UFS and HFS+). And on those topics, we get "gee that's neat to know" trivia, but it's totally useless, as there nothing on Mac specific commands like ditto or setfile to handle the Mac flavor of Unix.
On one topic on "Controlling Processes", the author explains the concept of processes and shows a screen shot of a Windows Task Manager. I was thinking, that well, maybe this book offers something different by showing how to script with Windows specific commands, like tasklist, but nope, we only get the screen shot, and following discussion on ps command and the /proc directory on Linux.
Overall, the book offers a lot of trivia on a variety of topics, and in some places there may be some scripts -- if you are lucky -- relating to the topic, and interspersed chaotically is some introduction material on shell scripting, sometimes bourne, sometimes c shell, sometimes something different. If this type of style works for you, then this might be the book, but I think for most of us, we'll want to follow more focused organized books relating to shell scripting (and of a particular scripting language, e.g. POSIX shell or other shell language).
Chapter List: Introducing Shells; Introducing Shell Scripts; Controlling How Scripts Run; Interacting With The Environment; Scripting With Files; Processing Text with sed; Processing Text with awk; Creating Command Pipelines; Controlling Processes; Shell Scripting Functions; Debugging Shell Scripts; Graphing Data With MRTG; Scripting For Administrators; Scripting For The Desktop; Answers To Exercises; Useful Commands; Index
This book has something for just about every beginning user. As a "Beginning" Wrox book, it's meant to take you from no knowledge to basic competency. Normally when you think of shell scripts, you think Unix. But this book goes beyond that. The authors include just about every OS in their coverage. Unix and Linux users are obviously taken care of, as I'd expect. But they also address Mac OS X users so that they can start to delve under the covers of their operating system. They even include Windows users by having them download the Cygwin software. Overall, the focus is on the Bourne shell, but special features of the others (like C, bash, and Korn) are also addressed as they come up. Overall, you get coverage on just about everything you could want as a beginner.
With the combination of "Try It Out" and "How It Works" examples in the book, beginners should quickly be able to do something with their new knowledge. To me, that's always the sign of a good beginning level book on a subject... get the reader doing something productive quickly. Beginning Shell Scripting meets that criteria.
I recommend this book to those who know the Shell Scripting, but they are looking for some new ideas or second opinion.
It is easy to read and follow, the examples are clear and well described. Overall very nice effort!