Phing
Upcoming SlideShare
Loading in...5
×

Like this? Share it with your network

Share

Phing

  • 3,483 views
Uploaded on

Slides from my Phing talk given at PHPNW June 2011.

Slides from my Phing talk given at PHPNW June 2011.

More in: Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
3,483
On Slideshare
3,069
From Embeds
414
Number of Embeds
5

Actions

Shares
Downloads
25
Comments
0
Likes
1

Embeds 414

http://www.magmadigital.co.uk 393
http://localhost 12
http://craniac 4
url_unknown 3
https://twitter.com 2

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide
  • \n\n
  • \n\n
  • Phing = PHing Is Not Gnu make\n\nDeveloper build toolkit - tool for every job (almost)!\nLGPL Licensed\n\nMy knowledge of Phing about 20%, however there's great documentation!\n
  • Web applications require deployment, packaging, testing, setting permissions, configuration, creating log files\nDoing so by hand every time is scary!\n
  • \n\n
  • \n\n
  • Project: root XML node\nTargets: collection of tasks, together for a reason\nTasks: call to specific action e.g. copy, symlink etc.\n
  • \n\n
  • \n\n
  • Fileset selectors - powerful matching, as well as **\ndate based, size, file/dir, related files present\nMapper - also a good tool, convert filenames during build\nFilters (filterchains) - transform data during build, e.g. strip comments, replace values in config files (via regex)\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n
  • \n\n

Transcript

  • 1. ContentPhing Build System (basics)What is it / Why use itWhat can it doExample build filesPhing & CI (Jenkins)Questions
  • 2. Whats this Phing about? The TPhingBuild system- Based on Ant (Apache)- PHP(5) based- No extra dependencies- Cross platform flickr.com/photos/
  • 3. I dont need nostinking Build SystemDo you write PHP Apps or just web pages?- Configuration- Deployment- Committing- Testing- Documenting
  • 4. I dont need nostinking Build SystemDo you write PHP Apps or just web pages?- Configuration - Preparation- Deployment - Predictability- Committing - Confidence- Testing - Familiarity- Documenting - Loggable
  • 5. What can this Phing do?Pretty well everything bar make tea!Anything a shell script can do (FTP, SCP,Chown, Touch, SSH etc.) for deploymentIntegrate with version control (CVS, SVN,Git)Code quality checks (phpcs, pdepend,phpmd etc.)
  • 6. Oh is that all?
  • 7. Oh is that all?Unit tests (phpunit, simpletest)Database deployment (dbdeploy)Lint (PHP, JS, XML)Reporting (code coverage, PHPDoc,DocBLox)Not enough? Write your own Tasks or Exec
  • 8. Hows it work?Phing shell script,launches Phing PHPApp + your XML buildfileBuild file contains:- Properties- Targets- Tasks flickr.com/photos/jm3/4814208649
  • 9. Hello World!
  • 10. Example build script
  • 11. phing clean
  • 12. prepare
  • 13. deploy staging
  • 14. deploy live
  • 15. Continuous IntegrationRemove reliance onHuman natureRegular automatedbuilds (phing/ant)Report on build status
  • 16. CI ReportsFor many of the toolsin the Back to BasicsseriesPhing targets:- phpcs, pdepend, phpcpd, phpmd, phpunit, phpcb etc.
  • 17. Resourceshttp://www.phing.infohttp://www.phing.info/docs/guide/stable/http://jenkins-ci.orghttp://dbdeploy.comhttp://ant.apache.org
  • 18. Questions?
  • 19. Contact?Jeremy Coates, MD MagmaDigital Ltdjeremy@phpnw.org.uk@phpcodemonkey#phpnwlinkedin.com/in/jeremycoatesfacebook.com/jeremycoates