06-09-2017 12:45 PM - edited 06-09-2017 01:12 PM
When building a source distribution or application (and some others), we can specify "pre/post build actions", i.e. VIs that are called before or after the build steps.
Sadly, this option is missing when building an installer. We can only specify executables that run before of after installation, not before/after the build process.
I can think of many scenarios where a "pre/post build action" could be useful when building an installer. For example every time I build an installer, I rename the created "Volume" folder to something else, and every time I edit the setup.ini file to change the "WinFastStartup=1" to "WinFastStartup=0" (long story). These are steps before/after the build, and occur well before distribution and installation.
After "build all", I also move all new builds (source, exe, installer) to a new and unique folder, and since the installer is the last build, even this could be automated if we had post built action when building installers.
Am I missing something obvious?
(Of course I can write a VI that does all the builds and then applies the actions. Just wondering why the built-in tools are missing this functionality).
06-09-2017 01:56 PM
Ahhh... musings of the Gods. 😄
06-09-2017 02:12 PM
I have never wanted to a Pre/Post on an installer, but you make some very good points. Make it an idea and I'll vote for it.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
16 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
06-09-2017 03:00 PM
@Hooovahh wrote:
I have never wanted to a Pre/Post on an installer, but you make some very good points. Make it an idea and I'll vote for it.
Agreed... I'd vote for it as well.
I've run into a couple of cases where doing a pre/post on an installer would have been very useful. Last time I ended up just compiling the vis as executables and packaging them with the installer, but it felt like a hack way to do it.
06-09-2017 03:05 PM
@Hooovahh wrote:
Make it an idea and I'll vote for it.
Yes, this was my plan depending on the comments here, so stay tuned.
(... and after I have searched in detail to see if anything similar has not been proposed yet).
11-15-2017 06:06 PM
This is very much needed. I like to have a pre-build VI that renames/deletes the previous build output folder to ensure that the build happens in a clean location (so that if I zip up the installer, it doesn't have any old files in there that weren't added specifically during the build process).
11-15-2017 08:33 PM
If we are talking about adding to the Pre/Post Build functionality, can we please get NI to allow us to include Actions that can modify the Build options (like set parts of the Version info) before the values are cached as part of the Build Procedure? Otherwise we are stuck with "Build Twice", or "Build Programmatically" (which allows you to do, yourself, the "Pre-Build" Actions, do the Build, then do the Post-Build Actions, and optionally do this for a single Build Spec or "Build All").
Bob "Frustrated" Schor
11-16-2017 05:02 PM
This is very much needed. I like to have a pre-build VI that renames/deletes the previous build output folder to ensure that the build happens in a clean location (so that if I zip up the installer, it doesn't have any old files in there that weren't added specifically during the build process).
01-15-2021 07:07 AM
@Bob_Schor wrote:
If we are talking about adding to the Pre/Post Build functionality, can we please get NI to allow us to include Actions that can modify the Build options (like set parts of the Version info) before the values are cached as part of the Build Procedure? Otherwise we are stuck with "Build Twice", or "Build Programmatically" (which allows you to do, yourself, the "Pre-Build" Actions, do the Build, then do the Post-Build Actions, and optionally do this for a single Build Spec or "Build All").
Bob "Frustrated" Schor
Stumbled on this today. I was wondering why I stopped using pre/post-build and made my own programmatic build. Now I found out why. Going back to programmatic build. Really crazy that I have to build first to get the version numbers correct for the next build. Kudoed https://forums.ni.com/t5/LabVIEW-Idea-Exchange/Have-Post-Pre-Build-VI-For-Installers/idi-p/3680911.
01-15-2021 08:36 AM
Still only 16 kudo's. Sigh.
Seems like there are few people smart enough to don't want to do the same thing over and over and over again. Ad infinitum
For me, it's zipping the installer volume and the fast startup hack.
I'd probably automate tossing it over the customer's fence as well.
I hope that if\when they do it, the give us an array... The pre\post build action should be an array as well. Probably easier to implement as well.