The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My work

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,842 other followers

Delphi and Batch Files

Posted by jpluimers on 2014/11/06

Two interesting links today about Delphi and Batch files.

–jeroen

PS: If you want to see some serious Batch file and PowerShell related scripts, then read through the Build Automation part of my session materials I posted to ITDevCon and EKON session materials on Delphi Unit Testing + Build Automation and Continuous Integration on-line.

More details are in the batch files here:

and PowerShell scripts here:

7 Responses to “Delphi and Batch Files”

  1. David Heffernan said

    Batch is pretty much impossible to write and impossible to read as soon as you want to do anything useful. I’d always opt for a real language. My choice is Python but there are many useful possibilities.

  2. Bruce McGee said

    I wouldn’t poo-poo on batch files. They have the distinction of being universally shareable without making assumptions about what recipients have installed. Except Delphi, of course.

    And since Delphi 2007, MSBuild makes these much more reliable.

    In-house, where you can control the environment – that’s another story. What do you use to automate your builds?

    • KMorwath said

      There is a tool to write scripts “universally” shareable and it used to be Make. Being designed exactly to compile files, make scripts are usually more useful and powerful than batch scripts – and being still a command line utilty doesn’t ask to install much. TurboPascal came with a Make utility, it was later removed.

      We use Jenkins to automate builds. It is simpler to connect version control access, build tools and test tools together and make them work without tooo much scripting – and keeping account informations reserved enough.

      • Bruce McGee said

        “used to be”

      • jpluimers said

        Make: talking about a distant past (;
        Make is indeed much more powerful than batch files though. So is powershell, for which pash is a cross platform alternative gaining ground: https://github.com/Pash-Project/Pash

        I’m using various build systems to do automated builds. The session covers Continua CI, but I’m also using TeamCity and CruiseControl.net. In my experience, for all the majority of time is not getting to know the build system, but getting all the tiny details about parameters, scripts, etc right.

        Note about make: I’ve used that too. Too many platform dependencies in the various flavours of make (the version shipped Turbo Pascal wasn’t exactly Unix compliant, and even on Unix it is hard to make things clean and platform independent at the same time).

        In practice it comes down to finding the right abstraction levels in various tools.

  3. KMorwath said

    Guess the article should be updated to use PowerShell scripts… looks like Delphi developers today just love to live in a distant past. Anyway, today there are better tools to build than using a shell script – especially since old “batch” shell scripts in Windows have limited features.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: