A creative (albeit limited) application of unit aliases in Delphi...

A creative (albeit limited) application of unit aliases in Delphi...
http://www.deltics.co.nz/blog/posts/1945

Comments

  1. And boom there goes your possibility to just commandline compile your project without additional parameters because someone thought that dproj files don't belong into version control.

    ReplyDelete
  2. I prefer $ifdef and include files.

    ReplyDelete
  3. Command line compilation is most often part of a CI setup, and depending on what you use to drive the command line compilation itself it need not be a problem.

    With FinalBuilder, for example, you would simply specify your unit aliases in the build options of the Delphi Compiler step in the build script, entirely independent of any project configuration files.  And the build script of course is a versionable resource.  :)

    Of course, if it is a problem in any particular case you can't use the technique.  Like almost every "tool" there are limits on it's utility, and I did say that this had limited application, even if I didn't enumerate all of those limits.  :)

    ReplyDelete

Post a Comment