

The PEAR Installer Manifesto. The PEAR Installer maintainer shows you the power of this code management and deployment system to revolutionize your PH



The PEAR Installer Manifesto. The PEAR Installer maintainer shows you the power of this code management and deployment system to revolutionize your PH - Najlepsze oferty
The PEAR Installer Manifesto. The PEAR Installer maintainer shows you the power of this code management and deployment system to revolutionize your PH - Opis
PEAR stands for PHP Extension and Application Repository, and its primary purpose is to support code re-use. PEAR provides both an advanced installer and a code repository at https://pear.php.net. PEAR code is organized into discrete re-usable components called packages. A package consists of a group of files and a descriptor file called package.xml that contains metadata about the package's contents, such as the package version, any special dependencies, and textual information such as the package description and authors.The software that transforms a package from an inert grouping of files into a dynamic software package is called the PEAR Installer and is itself a PEAR package. In other words, the PEAR Installer can be used to upgrade itself. It truly is a very powerful application. In short, the PEAR Installer is one of the most effective tools for managing a high-quality software library, high-quality applications, or high-quality websites.This book will show you a new way of organizing your PHP development, by leveraging the full power of the PEAR Installer. In a sense, the PEAR Installer is a step above a software design pattern, a meta-development pattern that can be used to systematically organize all of your PHP development.You will learn how to organize your code into packages using the package.xml format. You will learn about the revolutionary new PEAR Channel concept, and how to safely and reliably depend on external PHP libraries from sources such as pear.php.net and other PEAR channels. You will learn about the PEAR_PackageFileManager package, and how to (...) więcej customize individual installations of your PHP code through file roles, file tasks, and post-installation scripts.In addition, you will learn how to use the power of PEAR to manage your web projects with the PEAR installer to bring the power of versioning and rollbacks to your live website. The synergy of the PEAR Installer and a revision control system like CVS or Subversion is also explored in depth.Next, you will learn how to set up your own PEAR Channel for distributing PHP applications, both open-source and proprietary closed-source PHP applications that can be secured using technology already built into the PEAR Installer.Finally, you will learn how to embed the PEAR Installer inside your own web application in order to manage plug-ins from a remote server. The book covers in detail designing a custom plug-in system for a fictitious blog application. The plug-in system is used to manage templates, and the PEAR Installer is used to manage the details of querying the remote server for templates, handling dependencies between versioning, and doing the actual installation process as well. Spis treści:The PEAR Installer Manifesto
Table of Contents
The PEAR Installer Manifesto
Credits
About the Author
About the Reviewers
Preface
What This Book Covers
Conventions
Reader Feedback
Customer Support
Downloading the Example Code for the Book
Errata
Questions
1. Acquiring PEAR: What is it and How do I Get It?
A Democratic Innovation for PHP: PEAR Channels
What is PEAR? A Code Repository or an Installer?
PEAR Package Repository and PEAR Channel
PEAR Installer
Installing the PEAR Installer
PEAR Bundled with PHP
Installation for PHP Versions Older than 5.1.0
Other Unofficial Sources
Synchronizing to a Server with no Shell Access Using PEAR_RemoteInstaller
Summary
2. Mastering PHP Software Management with the PEAR Installer
Distributing Libraries and Applications
Differences between Libraries and Applications from the Installers Point of View
Using Versioning and Dependencies to Help Track and Eliminate Bugs
Versioning
PEAR Packaging and Strict Version Validation
Enterprise-Level Dependency Management
Distribution and Upgrades for the End User
An Overview of package.xml Structure
Tags Shared between package.xml 1.0 and 2.0
Package Metadata
Package Name/Channel
Maintainers (Authors)
Package Description and Summary
Basic Release Metadata
Package Version
Package Stability
External Dependencies
Simplifying XML Validation of package.xml
Managing Trust of Dependencies
Reliably Depending on PECL Packages
Release Notes
Release License
Changelog
File List, or Contents of the Package
New Tags in package.xml
File/Directory Attributes: name, role, and baseinstalldir
Summary
3. Leveraging Full Application Support with the PEAR Installer
package.xml Version 2.0: Your Sexy New Friend
PEAR Channels: A Revolution in PHP Installation
Application Support
Introduction to Custom File Roles
Creating PEAR_Installer_Role_Chiaramdb2schema Custom Role
Full Range of Possible Custom File Roles
Introduction to Custom File Tasks
Creating the PEAR_Task_Chiara_Managedb Custom Task
The Full Range of Possible Custom File Tasks
validXml($pkg, $xml, &$config, $fileXml)
init($xml, $fileAttributes, $lastVersion)
startSession($pkg, $contents, $dest)
run($tasks)
Post-Installation Scripts for Ultimate Customization
Components of a Post-Install Script
Bundling Several Packages into a Single Archive
Backwards Compatibility: Using package.xml 1.0 and 2.0
Why Support Old and Crusty package.xml 1.0?
Case Study: The PEAR Package
PEAR_PackageFileManager
Obtaining PEAR_PackageFileManager
PEAR_PackageFileManager Script and the package.xml Files it Generates
How PEAR_PackageFileManager Makes a Hard Life Easy
Globbing Files for package.xml
Managing Changelog
Synchronizing package.xml Version 1.0 and package.xml Version 2.0
Creating a Package for Installation with the PEAR Installer
Summary
4. Clever Website Coordination Using the PEAR Installer
Overview of the Problem
Understanding the Problem
Managing Code Breakage and Reverting to Previous Versions
Managing Missing or Extraneous Files
Coordinating Development with a Team of Developers
Backing Up Code: Redundancy as a Necessary Precaution
The Solution, Part I: All-Important Source Control
Providing Redundancy and Revision History
Installing CVS or Subversion
Concurrent Versions System
Setting Up a CVS Repository
Subversion
Setting Up a Subversion Repository
Intelligent Source Control
Maintaining Branches for Complex Versioning Support
Using Tags to Mark Point Releases
The Solution, Part II: Using the PEAR Installer to Update the Website
Generating package.xml from the Source Control Checkout
Packaging: Coordinating Release Versions with Tags and Branches
Testing the Release before Uploading
Upgrading the Live Server
Using the pear upgrade Command
The Real Beauty of Using Pear to Fix Problems
Summary
5. Releasing to the World: PEAR Channels
Distributing a package.xml-Based Package
Distributing Packages through a Channel Server
The channel.xml File
channel.xml Tag Summary
Obtaining Chiara_PEAR_Server
Configuring the Server; Obtaining a Front End for End Users
Adding a Package and Releasing Packages
Installing a Public Channel Front End
Distributing Pay-For-Use PHP Applications through a Channel
Distributing Packages through Static tarballs for Single-Client Installations
Who Needs this Feature?
Differences in package.xml and Dependencies
Releasing Equals Uploading
Security Issues Inherent in Remote Installation
How do PEAR Installer and Chiara_PEAR_Server Provide Security?
Extra Security beyond what PEAR Provides
Specific Security Principles Applied in Designing the PEAR Installer and Chiara_PEAR_Server
Summary
6. Embedding the PEAR Installer: Designing a Custom Plug-In System
Why Embed PEAR?
Simplify User Choices for Installation
Eliminate Chances for Error
Other Plug-In Systems
Bundling Plug-Ins Directly in the Source Code
Subpackages - PEAR Dependencies
Case Study: MDB2
Custom Plug-In Systems: Remote Server
Case Study: Serendipity Blog's Spartacus Plug-In Manager
Case Study: Seagull Framework's Embedded PEAR Installer
Designing a Custom PEAR Channel-Based Plug-In System
Reusing Existing Functionality
PEAR Installer Infrastructure: REST and PEAR Installer Classes
PEAR_Config
PEAR_Dependency2
PEAR_REST and PEAR_REST_10/PEAR_REST_11
PEAR_Downloader and PEAR_Downloader_Package
PEAR_Installer
Extending REST with Custom Information
Designing a Lightweight Installer Plug-In: The Code At Last
MyBlog_Template_IConfig and MyBlog_Template_Config
MyBlog_Template_REST
MyBlog_Template_Lister
MyBlog_Template_Fetcher
The MyBlog Post-Install Script
The Rest of the Fake MyBlog Package
Improvements for the Ambitious
Summary
Index O autorze: Gregory Beaver has been one of the most active contributors to open-source PHP development since 2001. As the primary developer of important infrastructure software such as phpDocumentor, the PEAR installer, PHP_Archive, PHP_LexerGenerator, and PHP_ParserGenerator as well as co-lead of the Phar PHP extension, Gregory has helped to ease the development needs of PHP developers around the world. After he transformed phpDocumentor from a small project into the most advanced auto-documentation tools for PHP, phpDocumentor was voted second best PHP tool in Germany-based PHP Magazin's 2003 Reader's Choice awards list for best PHP application, and voted third best PEAR package (https://tinyurl.com/bn7pb). Currently, he is working to refactor the PEAR installer for PHP 6, as well as helping to lead the PEAR community forward. Gregory blogs about his programming escapades and other news on his blog, Lot 49 (https://greg.chiaraquartet.net). Gregory also leads a mysterious double life as the cellist of the internationally renowned Chiara String Quartet (https://www.chiaraquartet.net) with whom he tours the world. He lives in Lincoln, Nebraska where he is a full-time lecturer/artist-in-residence at the University of Nebraska-Lincoln Hixson-Lied College of Fine Arts. mniej
The PEAR Installer Manifesto. The PEAR Installer maintainer shows you the power of this code management and deployment system to revolutionize your PH - Opinie i recenzje
Na liście znajdują się opinie, które zostały zweryfikowane (potwierdzone zakupem) i oznaczone są one zielonym znakiem Zaufanych Opinii. Opinie niezweryfikowane nie posiadają wskazanego oznaczenia.