Commit Graph

9 Commits

Author SHA1 Message Date
Don Cross
7e196a3c17 Fixed Windows batch files ignoring negative integer failure codes.
In many of my Windows batch files, I used the following
construct to detect failures:

    do_something
    if errorlevel 1 (
        echo.An error occurred in do_something
        exit /b 1
    )

I discovered that it is possible for a Windows program
to exit with a negative integer error code.
This causes the above construct to miss the failure
and the batch file blithely continues.

So I have replaced that construct with

    do_something || (
        echo.An error occurred in do_something
        exit /b 1
    )

This way, if the command exits with any nonzero error,
we correctly detect it as a failure.
2023-02-26 10:26:42 -05:00
Don Cross
139fde6fe8 Windows CI: Upgraded Visual Studio target platform of C programs. 2022-01-09 20:42:28 -05:00
Don Cross
27adf8a3e0 Windows CI: second attempt to run msbuild.exe. 2022-01-09 20:09:32 -05:00
Don Cross
4ef515953e Windows CI: attempt to put msbuild.exe in PATH. 2022-01-09 19:57:30 -05:00
Don Cross
37c8aeafa9 Moved 'windows' directory away from root.
The 'windows' directory is mainly useful for
maintainers, not end users. So I moved it out of
the root to reduce distraction for a first-time
visitor.

While I was fixing up resulting breakage in
Visual Studio project files, I noticed I still had
some hard-coded absolute paths that would only work
on my own Windows laptop (e.g. "c:\don\github\astronomy").
I replaced those with relative paths that will work
regardless of what directory the repo is cloned into.
2022-01-09 12:55:41 -05:00
Don Cross
9ed27be0f8 Work in progress: Adding C magnitude tests. 2019-05-23 12:05:18 -04:00
Don Cross
7d4047429a Fixed #38 - Run C unit tests on Windows. 2019-05-19 21:29:31 -04:00
Don Cross
6413a24094 Run.bat now builds code before proceeding. 2019-04-18 14:40:40 -04:00
Don Cross
0c5415a1f5 Added batch file to rebuild generate.exe on Windows. 2019-04-18 14:34:14 -04:00