Symbolic Links and Subversion with ActionScript

Subversion has been a good tool to manage my project code since I started using it. I have never felt a need to migrate to GIT or other version tools. I also use it to get code libraries shared by other developers from resources like Google Code.

I prefer to keep all Actionscript in a single location in the root of my C drive. This makes it easy to set up a working directory on any PC without having to change publish settings or Flash ActionScript preferences.

I also prefer to pull complete third party libraries, which are often organized as a complete project, including a trunk, branch and tag directories which are not reflected in the package definition.

These preferences are pretty much at complete odds with each other. Keeping current versions of every library in my class directory could be a time-consuming task. I would need to periodically update each library directory and then replace a copy of each respective source subdirectory into my class directory. I also need to set Subversion to ignore each library-derived directory.

An ideal solution would allow me to make a shortcut from the source directory of each library to my class directory. Then updates to each library would flow to the class directory automatically. The only catch is that shortcuts are not recognized by Flash or Flex as a classpath destination.

However, there is another way to create a link between two directories. A Symbolic Link is similar to a shortcut, except that instead being a pointer to another directory it is a mirror, or clone directory. Once a Symbolic Link is created you have two directories that contain the same contents. Delete a file from one and you have deleted it from the other- each are a window on the same directory.

Library

Library

You may also like...

Leave a Reply

Your email address will not be published.


× 8 = eight

This site uses Akismet to reduce spam. Learn how your comment data is processed.