29 Commits

Author SHA1 Message Date
Ebrahim Byagowi
c24d49f742 jvm: Upgrade Java language version to 11 2022-05-03 21:57:57 +04:30
Don Cross
90aa6ed369 Cleaned up GitHub Actions configuration.
Deleted the do-nothing placeholders for installing
the Kotlin Native compiler. We are not going to support
Kotlin Native for now.

Removed redundant installation of pylint from the
Windows commit_hook.bat.

Other batch file cleanup, now that I know "||" works in Windows.
2022-05-02 12:30:23 -04:00
Hamidreza Bayat
0a2fdbfd8d Use conditions & matrix for workflow 2022-05-01 20:12:42 +04:30
Don Cross
30ee194e72 Trying my own Kotlin Native installer.
I kept running into problems trying to create
a GitHub Action to install the Kotlin Native compiler.
So I am rolling my own using a bash script.
2022-04-13 20:33:04 -04:00
Don Cross
ecedb44da9 Forked setup-kotlin action and fixed download.
This is my attempt to fix an incorrect download
URL in the GitHub Action:

https://github.com/fwilhe2/setup-kotlin

I forked it to try out my own fix:

https://github.com/cosinekitty/setup-kotlin

I updated the GitHub Actions configuration file
to use my forked version instead.
I hope this works!
2022-04-13 19:39:25 -04:00
Don Cross
4e588b7fe9 Kotlin Native: fixed GitHub Actions issues.
The Mac OS tests failed because the Kotlin Native
compiler created an unexpected directory:

	demo/kotlin/native/moonphase.kexe.dSYM/

I fixed this by adding *.dSYM to .gitignore.

Also, the GitHub Action `fwilhe2/setup-kotlin@main`
defaults to an older version of the compiler.
I added an option to specify using version 1.6.20.
2022-04-13 18:47:54 -04:00
Don Cross
d1d18c60e6 Setting up for Kotlin Native demo/test.
Nothing very interesting yet.
Just building a very basic Kotlin Native app
to make sure build and execute work on GitHub Actions,
on Linux and Mac OS.  I will worry about Windows later.
2022-04-13 17:37:00 -04:00
Don Cross
646abeecfe Merge branch 'master' into kotlin 2022-04-13 16:39:12 -04:00
Don Cross
7553b6b749 Windows GitHub Actions: check all steps for errors
I found out in the Kotlin branch that GitHub Actions
only checks for error codes in the last step of the
Windows commands it executes. I moved all the command
line steps into a batch file generate\commit_hook.bat.
It does all the error checking itself.
2022-04-13 16:13:47 -04:00
Don Cross
ae3dd35bee GitHub Actions did not check failure in run.bat.
I just noticed a build problem in the Kotlin code
was detected by GitHub Actions in Linux and Mac OS,
but not in Windows. It marked the Windows test as
a success, even though the output clearly shows that
run.bat failed. I theorize that the steps inside
the file .github/workflows/astronomy-engine-tests.yml
are not being checked for errors after each step, but
only after all of them execute. So I have moved them
into a new batch file generate/commit_hook.bat, which
does check each step.

After pushing this change, all 3 builds should fail.
Once I get Windows to fail also, I will fix the failure.
2022-04-12 20:12:05 -04:00
Don Cross
96b84cfc67 Weirdly, GitHub Actions steps were in wrong order.
This is strange. I noticed looking in the GitHub Actions report
for running tests that my Gradle/Kotlin steps were run before
their dependencies were supposedly installed. Perhaps the
steps "set up JDK 1.8" and "gradle/wrapper-validation-action@v1"
are not even needed? Regardless, I moved these steps to run
before building and testing the Kotlin code.

Even if the steps are not needed, they are a helpful reference
point for understanding what things a developer needs to install
on a local system before making contributions to Astronomy Engine.
2022-03-24 10:27:31 -04:00
Don Cross
a0723c7406 Kotlin build/test integrated with 'run' scripts.
Instead of being executed directly by the GitHub Actions
yml file, the Kotlin build now has been integrated with
the build/test steps for the other 4 languages in the
bash script `generate/run` and the Windows batch file
`generate/run.bat`. This will be necessary to control the
order of execution, because the Kotlin source code will have
to be written by the code generator before it is built
and executed.

I also added hints for myself and other contributors about
how to set up Kotlin/JDK tools on a new developement machine.
These instructions are not needed by most users of Astronomy Engine,
just contributors.
2022-03-17 20:52:32 -04:00
Ebrahim Byagowi
34bf5f1497 Enable Kotlin testing in macOS and Windows 2022-03-16 01:54:27 +03:30
Ebrahim Byagowi
01a0a89109 Add Kotlin project structure 2022-03-15 21:37:42 +03:30
Don Cross
fc75276e79 Windows CI: execute verify_clean.bat after run.bat.
From the GitHub Actions logs, it looks like verify_clean.bat
is not running after run.bat, like I intended. I'm guessing I
need to add "call" before both batch files to ensure that
control returns to the caller.
2022-01-10 16:19:58 -05:00
Don Cross
884539fde4 Windows CI: attempt downloading and running doxygen. 2022-01-10 16:01:00 -05:00
Don Cross
acf3877e31 Windows CI: turn off doxygen / generating C docs for now. 2022-01-09 21:38:09 -05:00
Don Cross
4ef515953e Windows CI: attempt to put msbuild.exe in PATH. 2022-01-09 19:57:30 -05:00
Don Cross
15a330c64d Windows CI: specify cmd instead of PowerShell. 2022-01-09 17:36:38 -05:00
Don Cross
e8aaee2e09 Windows CI: another attempt at multiple commands. 2022-01-09 17:25:25 -05:00
Don Cross
3c3d36bcea Fixed syntax errors in yml 2022-01-09 15:48:57 -05:00
Don Cross
8ad3488b65 Starting to work on GitHub Actions tests for Windows.
I'm certain this will fail, but I at least want to
start creating automated tests for building Astronomy
Engine on Windows.
2022-01-09 15:39:01 -05:00
Don Cross
cb4c9a6549 Fixed mistake in raytracer. Stop using 'realpath'.
I found a mistake in the raytracer's Spheroid class,
thanks to a warning about an unused member variable.
I don't believe it had any effect on the currently
generated images, but it was important to fix it before
I ever do any set operations on Spheroids.

On macOS, there is no 'realpath' command by default.
So I eliminated some more attempts to use 'realpath'
in the demo test scripts.

Renamed the GitHub Actions tests to be consistent:
    Astronomy-Engine-Linux
    Astronomy-Engine-Macos
2022-01-07 18:30:15 -05:00
Ebrahim Byagowi
4a0902fa10 CI: Add a macos bot 2022-01-07 12:18:00 +03:30
Don Cross
f994d8d04c Fixed #141 - Upgrade C# code to .NET 6.
Now that Microsoft has officially released .NET 6,
I have upgraded the C# version of Astronomy Engine to use it.
No source code changes were needed. I just bumped the
version number in the project files, and targeted .NET 6
in the GitHub Actions continuous integration tests.
Fixed some obsolete wording in generate/README.md.
2021-12-07 17:06:04 -05:00
Don Cross
36a8370f4d Tell GitHub Actions to install doxygen, xsltproc.
These tools are needed for generating documentation
for the C version of Astronomy Engine.
This is an attempt to fix the current CI build failure.
2021-11-24 20:03:57 -05:00
Don Cross
25cba04356 Added pylint to unit tests. Fixed warnings. 2021-09-25 19:51:48 -04:00
Don Cross
c23affd28c First attempt at doing a GitHub Actions test build for Astronomy Engine. 2021-04-21 19:40:42 -04:00
Don Cross
31ff4acc1e Experimenting with GitHub Actions as a replacement for Travis CI. 2021-04-21 19:27:30 -04:00