Your SlideShare is downloading. ×
  • Like
Phing
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Now you can save presentations on your phone or tablet

Available for both IPhone and Android

Text the download link to your phone

Standard text messaging rates apply

Phing

  • 2,997 views
Published

Slides from my Phing talk given at PHPNW June 2011.

Slides from my Phing talk given at PHPNW June 2011.

Published 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
2,997
On SlideShare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
25
Comments
0
Likes
1

Embeds 0

No embeds

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