+ All Categories
Home > Technology > Version Control != Dependency Management

Version Control != Dependency Management

Date post: 26-May-2015
Category:
Upload: tricode
View: 712 times
Download: 1 times
Share this document with a friend
Popular Tags:
30
October 29, 2010 Patrick van Dissel http://ikoodi.nl [email protected] @pvdissel Version Control != Dependency Management
Transcript
Page 1: Version Control != Dependency Management

October 29, 2010

Patrick van Disselhttp://ikoodi.nl [email protected] @pvdissel

Version Control!=

Dependency Management

Page 2: Version Control != Dependency Management

Note

This presentation is focussed on and for PHP projects, but the principal can be applied on

projects in other programming language

Page 3: Version Control != Dependency Management

PHP

Page 4: Version Control != Dependency Management

Common project structureNice separation:● Application● Libraries● Public

Page 5: Version Control != Dependency Management

Common structure in VCS

Single directory structure

Libraries copied in every project;causing duplication

Page 6: Version Control != Dependency Management

Subversion(svn)

Page 7: Version Control != Dependency Management

Common structure in VCS

svn:externals to tagsAs it should be used

With Subversion (SVN)

Page 8: Version Control != Dependency Management

Common structure in VCS

svn:externals to trunkAs it's often used

With Subversion (SVN)

Page 9: Version Control != Dependency Management

Getting externals in SVN

Page 10: Version Control != Dependency Management

External fetching on SVN checkout

Page 11: Version Control != Dependency Management

svn:externalsPros:● svn:externals fixes duplication

Cons:● Externals are hidden in SVN metadata● Externals are NOT read-only(!)● Externals can ONLY point to a SVN repository● Makes branching/tagging harder

Page 12: Version Control != Dependency Management

svn:externals

Makes a rudimentary dependency manager from Subversion

Page 13: Version Control != Dependency Management

How do others handledependency management?

Page 14: Version Control != Dependency Management

*nix

Page 15: Version Control != Dependency Management

A solution the *nix way

● Compile won't succeed until all required dependencies are available

● Configurable to use optional dependencies when available

with Make

Page 16: Version Control != Dependency Management

Java

Page 17: Version Control != Dependency Management

A solution the Java waywith Maven

Page 18: Version Control != Dependency Management

A solution the Java waywith Maven

Page 19: Version Control != Dependency Management

PHP

Page 20: Version Control != Dependency Management

Solutions available for PHP

a framework and distribution system for reusable PHP components

Page 21: Version Control != Dependency Management

Solutions available for PHP

Pyrus (PHP5.3.1+) is a tool to manage PEAR packages. Pyrus simplifies and improves the PEAR experience. Features include:● Standalone tool (pyrus.phar)● Can be integrated into application● Pear repository management/connection● Dependency Management● Packaging in the PHAR format (PHp Archive)

Page 22: Version Control != Dependency Management

Solutions available for PHP

PHing Is Not GNU make.A PHP project build system/tool based on Apache Ant

Page 23: Version Control != Dependency Management

Solutions available for PHP

Use a Version Control System likeSubversion to control code versions

Page 24: Version Control != Dependency Management

Solutions available for PHP

Use a build tool likePhing to "build" projects

Page 25: Version Control != Dependency Management

Solutions available for PHP

Use Pear as repository forlibraries and applications

Page 26: Version Control != Dependency Management

Solutions available for PHP

Use Pyrus to integrate thePear repository with

Phing for dependency management

Page 27: Version Control != Dependency Management

So..?

Page 28: Version Control != Dependency Management

It isn't working yet!!

Currently Phing doesn't havea plugin to work with Pyrus

(October 29, 2010)

Page 29: Version Control != Dependency Management

Resources

● Phing - www.phing.info● Pear - http://pear.php.net● Pear2 / Pyrus - http://pear2.php.net

Pyrus presentation: http://slidesha.re/cIAcgp● Extending Phing -

http://phing.info/docs/guide/stable/chapters/ExtendingPhing.html ● Phar - http://php.net/phar● Pake - http://pake-project.com● Make - http://en.wikipedia.org/wiki/Make_(software)● Apache Maven - http://maven.apache.org● Apache Ant - http://ant.apache.org● Apache Ivy - http://ant.apache.org/ivy

Page 30: Version Control != Dependency Management

Questions?


Recommended