Re: What is the necessity to use a installer to install php pear (Some more questions)

From: Date: Tue, 09 May 2006 15:55:10 +0000
Subject: Re: What is the necessity to use a installer to install php pear (Some more questions)
References: 1  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-24022@lists.php.net to get a copy of this message
On 5/7/06, moses@softwaysolutions.com <moses@softwaysolutions.com> wrote:
Hi Justin
        Thank You. I am much satisfied with ur answers.
        Still I Have some more questions ( It may be silly but
please.......... )
        1)Pear Packages are being modified time to time
               a)Will they add only additional  packages or even they
modify the old packages
Once a version of a package is posted to the PEAR website it is always the same. However, of course, new versions of the same packages are uploaded.
               b)If they also modify the old packages will they make
changes in the old methods or they only add new methods (why i am asking is Do i want to study different different methods on different versions for doing the same purpose)
New versions of stable packages uploaded must preserve BC (backwards compatibility), meaning that if your script works with one version of the package it should always work with any higher version. So if you install HTTP_Request 1.2.2 and wrie a script, when HTTP_Request 1.2.3 comes out you should be able to upgrade without anything breaking. It is, of course, always a good idea to look at the ChangeLogs to see what changed to see if there are some potential problems. Note that beta, alpha, and dev versions of packages may break BC and are often for testing purposes. (beta packages are encouraged not to break BC, but they may)
       2)We are using PEAR in our project but the server where  we need
to upload our project does not contail pear (ie PEAR is not installed) what will happen
Your scripts won't work, of course. You need the packages installed to be able to use them. You *can* just upload your local PEAR directory to the server, but I suggets using the PEAR installer on each seperate computer.
       3)Suppose if we are using the resent version of PEAR but the
server what we are uploading only contains the old version of PEAR what will happen
I assume you mean PEAR packages. Each package has its own releases. The outcome is unknown. Your newer versions of the package could easily have bug fixes or new features which will cause things to happen differently. It is best to keep your installations up to date.
       4)Is it necessary  the PEAR version what we  are using in our
project should be the same in the server where we have to upload the projet
No, but see above.
       5)When we are uploding our project in the server is it necessary
to check wheather the server contains pear and the version of pear installed in that server is same as what we are using.
Again, see above. You *must* have the packages you are using installed otherwise your script will die because it can't find the packages.
       6)If so how to check one sample coding please...
regards moses -------- Original Message -------- Subject: Re: [PEAR] What is the necessity to use a installer to install php pear From: "Justin Patrin" <papercrane@gmail.com> Date: Sun, May 07, 2006 10:03 pm To: "moses@softwaysolutions.com" <moses@softwaysolutions.com> Cc: pear-general@lists.php.net On 5/7/06, moses@softwaysolutions.com <moses@softwaysolutions.com> wrote:
Hi everybody I am new to pear... and i have some doubts regarding installing pear
Doubts? I think you mean questions.
1)To install pear every document says run the installer. 2)What is this installer
It is the PEAR installer. This is part of what PEAR is, a distribution system for packages. It allows you to easily install, uninstall, and upgrade packages.
3)Since pear is a package of classes where we can make use of it Why cant we just copy the class file and create an instance and make use of the methods.
Because PEAR is more than this. Yes, a package is a tarball of PHP files, but they are laid out in a specific manner in your PEAR install directory. The installer takes care of this. In addition, many packages use the same directories as other packages and it is easier to let the installer put everything in the right place than to do it manually every time. In addition, the installer make upgrading a package easy. Say a package you're using has a bug which has been fixed or a new feature in a new release. Upgrading is as simple as "pear upgrade Package" and it takes care of removing old files, adding new files, etc.
4)What is necessity here to install.
PEAR wants you to be able to easily install and upgrade your packages. The installer makes this so.
5)What is this installer doing
Installing packages, of course. It also has support for replacements in files (for, say, package versions) which some packages use and for pre and post install scripts which a few packages use. It also allows you to choose what stability you want it to use. So if you set it to "stable" you will install and upgrade only with stable versions. Oh, and the most important feature, it deals with dependencies, both required and optional and also has support for dependency groups for the more complicated packages, such as the installer itself (it has web installer and GTK installer groups). Lastly, the installer also has "channel" support which means that you can install packages in the same easy way from other package sites, such as pearified.com. -- Justin Patrin
-- Justin Patrin

« previous php.pear.general (#24022) next »