Build VS.NET Solution builds all configurations given invalid configuration

Hi,

 If I pass an invalid configuration to Build VS.NET in FB6, it fails. In FB7 it will compile ALL configurations present (so in my case both debug and release).  Example attached.

Build VS.Net [ J:\temp\CompileBug\FB6\TestProject1\TestProject1.sln ] [ InvalidConfigName|Any CPU ]
    Status: Completed
      Date: 4/28/2011
      Time: 15:14:47:137
       End: 15:14:49:853
  Duration: 00:00:02:716

Action Messages:
Solution J:\temp\CompileBug\FB6\TestProject1\TestProject1.sln
Running C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\IDE\devenv.com with parameters : /build "Debug|Any CPU" "J:\temp\CompileBug\FB6\TestProject1\TestProject1.sln"
------

Microsoft (R) Visual Studio Version 9.0.30729.1.
Copyright (C) Microsoft Corp. All rights reserved.
------ Build started: Project: TestProject1, Configuration: Debug Any CPU ------
C:\Windows\Microsoft.NET\Framework\v3.5\Csc.exe /noconfig /nowarn:1701,1702 /errorreport:prompt /warn:4 /define (15.139 KB)

Hi Nelson

This is a side effect of a new feature in FB7 that allows using regular expressions to match and build multiple configurations, so for example to build the Debug config for all platforms you can specify Debug.* or to build all configs for the x86 platform you can specify .*x86

I can see now that my implementation of this feature was a bit naive, in that the | in the confignames has a special meaning in regular expressions (alternate). To work around the issue you are seeing, just add a \ in front of the | to escape the |

I have added a new option to the action to disable to RegEx feature, however it defaults to on for FB7 compatibility so you will either need to escape the | or use the new option (let me know if you need a build with the option).


Hi Vincent,

Yes a checkbox to disable the regex would be helpful. I assume I can access this in script editor?

Can you recommend a way to detect the version of FB running using Javascript? There are a couple cases now where it would be useful for me to change my FB6 scripts to have if statements to do something different if being run via FB7.

-Nelson

Yes it can be accessed from script : Action.UseRegExOnConfigName

As for detecting the FB Version, theres nothing built in. It was never really intended that projects from earlier versions would be run as is from newer versions. Each time you load a older version project in FB7 it has to be upgraded. The amount of work done depends on what version it was created in, but it certainly does slow down the project load. I would recommend saving your projects in FB7 format.

Hi Vincent,

I’m using the new build with the regex disabled. That works for me.

I have decided to just bite the bullet, branch my build scripts and convert them all to FB7.

As for FB Version, I do read in the FB version in one of my scripts by reading the FinalBuilderX.exe and grabbing the version out of there. The reason I’ve done this is so I can enforce users using a version of FB older then X. This is useful since you guys fix a lot of little things over the life of a version. In version 6, my scripts depended on a number of fixes being present. Just having the FB version as a variable I think is useful as I could stick that in my logs so I can always go back and reproduce exactly. Another related feature you guys might want to throw on the back log is the ability to select an option which saves the last version of FB used to edit a project in the file. Then if the author decided, require users to have that as the minimum version. Not critical features, but might be nice.

Thanks,
-Nelson

Ok, here you go