Å·±¦ÓéÀÖ

Jump to ratings and reviews
Rate this book

Perl Best Practices: Standards and Styles for Developing Maintainable Code

Rate this book
Many programmers code by instinct, relying on convenient habits or a "style" they picked up early on. They aren't conscious of all the choices they make, like how they format their source, the names they use for variables, or the kinds of loops they use. They're focused entirely on problems they're solving, solutions they're creating, and algorithms they're implementing. So they write code in the way that seems natural, that happens intuitively, and that feels good. But if you're serious about your profession, intuition isn't enough. Perl Best Practices author Damian Conway explains that rules, conventions, standards, and practices not only help programmers communicate and coordinate with one another, they also provide a reliable framework for thinking about problems, and a common language for expressing solutions. This is especially critical in Perl, because the language is designed to offer many ways to accomplish the same task, and consequently it supports many incompatible dialects. With a good dose of Aussie humor, Dr. Conway (familiar to many in the Perl community) offers 256 guidelines on the art of coding to help you write better Perl code--in fact, the best Perl code you possibly can. The guidelines cover code layout, naming conventions, choice of data and control structures, program decomposition, interface design and implementation, modularity, object orientation, error handling, testing, and debugging. They're designed to work together to produce code that is clear, robust, efficient, maintainable, and concise, but Dr. Conway doesn't pretend that this is the one true universal and unequivocal set of best practices. Instead, Perl Best Practices offers coherent and widely applicable suggestions based on real-world experience of how code is actually written, rather than on someone's ivory-tower theories on how software ought to be created. Most of all, Perl Best Practices offers guidelines that actually work, and that many developers around the world are already using. Much like Perl itself, these guidelines are about helping you to get your job done, without getting in the way. Praise for Perl Best Practices from Perl community "As a manager of a large Perl project, I'd ensure that every member of my team has a copy of Perl Best Practices on their desk, and use it as the basis for an in-house style guide." -- Randal Schwartz "There are no more excuses for writing bad Perl programs. All levels of Perl programmer will be more productive after reading this book." -- Peter Scott " Perl Best Practices will be the next big important book in the evolution of Perl. The ideas and practices Damian lays down will help bring Perl out from under the embarrassing heading of "scripting languages". Many of us have known Perl is a real programming language, worthy of all the tasks normally delegated to Java and C++. With Perl Best Practices, Damian shows specifically how and why, so everyone else can see, too." -- Andy Lester "Damian's done what many thought show how to build large, maintainable Perl applications, while still letting Perl be the powerful, expressive language that programmers have loved for years." -- Bill Odom "Finally, a means to bring lasting order to the process and product of real Perl development teams." -- Andrew Sundstrom " Perl Best Practices provides a valuable education in how to write robust, maintainable Perl, and is a definitive citation source when coaching other programmers." -- Bennett Todd "I've been teaching Perl for years, and find the same question keeps being Where can I find a reference for writing reusable, maintainable Perl code? Finally I have a decent answer." -- Paul Fenwick "At last a well researched, well thought-out, comprehensive guide to Perl style. Instead of each of us developing our own, we can learn good practices from one of Perl's most prolific and experienced authors. I recommend this book to anyone who prefers getting on with the job rather than going back and fixing errors caused by syntax and poor style issues." -- Jacinta Richardson "If you care about programming in any language read this book. Even if you don't intend to follow all of the practices, thinking through your style will improve it." -- Steven Lembark "The Perl community's best author is back with another outstanding book. There has never been a comprehensive reference on high quality Perl coding and style until Perl Best Practices . This book fills a large gap in every Perl bookshelf." -- Uri Guttman

542 pages, Paperback

First published January 1, 2005

20 people are currently reading
152 people want to read

About the author

Damian Conway

11Ìýbooks7Ìýfollowers

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
132 (48%)
4 stars
99 (36%)
3 stars
36 (13%)
2 stars
5 (1%)
1 star
3 (1%)
Displaying 1 - 13 of 13 reviews
Profile Image for Apple84 Wylie.
20 reviews
January 9, 2008
Hardcore Perl programmers tend to be an audacious bunch. Damian Conway--a superstar and innovator among Perl coders--takes on the audacious task of calling to arms his fellow programmers with a battle cry of "We can do better!". Perl is a complex and highly flexible language that eschews the "one way to do it" philosophy found in other languages. However, Perl provides plenty of digital rope to hang ones self with--especially for coders new to the language. Perl code can be overtly terse or roundabout obfuscated depending on the coder's style, mood, or personal peccadillos. It is for the aforementioned reasons that Perl detractors often refer to Perl as extended "line noise". Perl Best Practices (PBP) tries to address these issues by providing a blueprint for coders to follow in many areas of coding the language. Practices are provided to the reader in soluble form: stated as a Commandment, followed with examples, and supported by logic and reasoning for the practice's existence. Practices range from common sense (Code in paragraphs) to philosophical (If you must rely on cleverness, encapsulate it.). While I do not agree with the author on every single practice--some incredulity is healthy whenever someone is telling you what to do!--I found more than enough information worth retaining in the book to warrant it's cover price. If you are a more-than-casual Perl coder, get this book and read it front to back.
Profile Image for Joshua.
87 reviews15 followers
February 29, 2008
This is a fantastic book that helps address many of the things that are negative about working with Perl in teams. Even through just beginning to standardize on a few of these principles, our group is sharing more code and spending less time discussing pros and cons of various approaches. In addition to the 'encoded practices' aspect of this book, the other 'win' is that it has some nice patterns and idioms for doing common things, and doing them well -- instead of gradually learning those things for yourself over time.
5 reviews
Read
April 29, 2008
Probably the most useful Perl book out there. Not only educational, but amazingly helpful in dealing with Perl Written By Other People.
Profile Image for Alex Satrapa.
20 reviews
January 8, 2012
Must-have reference for anyone writing Perl as part of a team, even if the team is only you and your future self!
Profile Image for David.
AuthorÌý1 book114 followers
April 20, 2022
This 517 book is the most damning evidence I could possibly present that Perl is deeply, deeply flawed at every level. Brilliant and trailblazing, but just absolutely a train wreck. Just turn to any page and see what you have to do to accomplish common tasks. Insane. I still use it, 'cause Perl 5 is still ROCK SOLID and installed everywhere in 2022. You should not learn Perl, but if you do, this is a great way to learn how to do it properly. Awful. Is this book out of date? Absolutely. The whole thing is out of date. Terrible, but STILL better than trying to figure out how to install Python dependencies. Highly recommended. :wq
Profile Image for Ashraf Bashir.
226 reviews131 followers
October 31, 2014
This book is a masterpiece! I think that it should be considered a must-read for anyone who will develop Perl applications. The author has deep understanding of Perl's under-the-hood. The book also contains "simplest scenario code" snapshots/samples (real ones, not theoretical examples) which explain each point in its depth, and these samples are well explained and very well compared to code snapshots of bad practices (Bad practices are also highlighted in the book, wow!) ... So as a small review, I'll start first with a minor weakness point of this book, that there are some few chapters that are really boring, especially those which are very primitive. But, in real life, you find that what you are considering very primitive isn't adopted by many developers; so this explains why the author highlights these points which I consider very primitive. If you are not a beginner developer, just skip these primitive chapters, else please read them carefully, this will enhance maintainability, scalability, efficiency and performance of your code ... On the other hand, one of the greatest advantages of this book is that more than 30% of what is written in it can be applied to any programming language as best practices, i.e. most of best practices are valid for any language ... I cannot say that it's worth reading, I think it's a must-read book.
Profile Image for Hunter Johnson.
230 reviews8 followers
Read
January 26, 2011
Perl Best Practices, by Damian Conway. Really worthwhile reference. I read it through on Safari; I think I'll have to acquire a personal copy. And it goes right along with...
Profile Image for Mihai Criveti.
AuthorÌý2 books20 followers
December 31, 2014
Still valid to this day - it's the modern Perl programmer's best friend (along with the excellent Perl::Critic).
Profile Image for smonff.
27 reviews3 followers
September 10, 2016
It was a very good book that draw the path to Modern Perl. It can help you to learn lots of programing best practices even for other languages.

1 review
Read
January 27, 2018
kodlamak sürekli kodlamak istiyorum
This entire review has been hidden because of spoilers.
Displaying 1 - 13 of 13 reviews

Can't find what you're looking for?

Get help and learn more about the design.