Commit graph

18 commits

Author SHA1 Message Date
Vadim Zeitlin
dbb85de9cd Use the same ccache cache key for all languages but not compilers
There doesn't seem to be any good reason to use per-language caches, as
there are files that are common to all languages.

But we do want to use different keys for the different compilers and
even different compiler versions, as they yield different results when
compiling the same code.
2021-09-30 17:39:23 +02:00
Vadim Zeitlin
6088323e14 Use ccache for building, not just configuring
Set the PATH to include the ccache directory for the subsequent steps,
including the "build" one, rather than only setting it locally for
configure, as this didn't have much effect at all.
2021-09-30 17:38:24 +02:00
Vadim Zeitlin
84b1b3f8b5 Do not use "make -s" in the CI builds
We want to have as much information as possible in case of the build
failure, so don't use the "--silent" make option.
2021-09-30 17:29:38 +02:00
Vadim Zeitlin
0c46a30249 Use consistent names for the build steps
Follow the convention of the GitHub built-in steps, such as the first
"Set up job" one and use capitalized verbs in imperative mood rather
than a mix of non-capitalized verbs and nouns.

This is a purely cosmetic change.
2021-09-30 17:27:40 +02:00
Vadim Zeitlin
1395b902be Re-add "clean" step of the build
This was used with Travis CI, so there doesn't seem to be any reason not
to use it with GitHub Actions too.
2021-09-30 17:25:25 +02:00
Vadim Zeitlin
542bc18b0f Use working directory step option instead of explicit "cd"
This seems simpler and more explicit ("cd" is easy to miss or forget).
2021-09-30 17:24:54 +02:00
Vadim Zeitlin
9156f390ae Don't set shell explicitly for the build steps
Bash is used by default under all platforms we're going to support here,
so there is no need to specify it explicitly. Moreover, by default the
appropriate shell options (such as "pipefail", as well as "e") are used,
and there is no need to override them.
2021-09-30 17:23:24 +02:00
Vadim Zeitlin
7692d5f9ec Set SWIGJOBS environment variable automatically
Use the number of available CPUs + 1 which seems to work best with the
number of actually available CPUs in the GitHub Actions environment.
2021-09-30 17:17:10 +02:00
Vadim Zeitlin
bbfdedc18b Define all environment variables at job level
There doesn't seem to be any reason to make them step-specific, so
simplify the workflow by doing it once and only once at the job level.

No real changes.
2021-09-30 17:13:33 +02:00
Vadim Zeitlin
a2ff01a910 Use better names for the CI builds
Don't rely on the auto-generated names which are not very useful: e.g.
currently something like "build (1, python, 3)" is shown, while this
commit changes it to just "python3" which is both shorter and more
readable.
2021-09-30 17:08:23 +02:00
Vadim Zeitlin
5d9bbea510 Default to Ubuntu 20.04 if OS is not specified
This makes the matrix more compact, as we don't need to specify the OS
for the majority of the field (all of them now, but we'll add builds
using "macos-N" later, so it will still be necessary for some of them),
and the builds more stable than using which the current latest Ubuntu
version is.
2021-09-30 17:00:24 +02:00
Vadim Zeitlin
067d927cb1 Skip running CI for the changes to the files not affecting it
Note that if we decide to do something for the docs later (e.g. run a
spell checker on them), it should be done in a separate workflow and not
in this one.
2021-09-30 16:53:40 +02:00
Vadim Zeitlin
d022a1507a Rename workflow file to just ci.yml
It doesn't seem appropriate to use test.yml for it.
2021-08-09 13:20:40 +02:00
Vadim Zeitlin
4e599ddbdb Remove "GHA" branch from the workflow file
Follow an existing comment saying that it should be removed before
merging.
2021-08-09 13:17:57 +02:00
Kris Thielemans
9d50ec97d0 [GHA] enable GHA branch for the moment
[appveyor skip]
[travis skip]
2021-08-02 12:12:57 +01:00
Kris Thielemans
0e45679aa7 [GHA] only run on master and PRs 2021-08-02 12:02:53 +01:00
Kris Thielemans
fb09a5578a [GHA] convert matrix to use include 2021-08-02 10:57:20 +01:00
Kris Thielemans
b734d67dd3 [GHA] first GitHub actions workflow 2021-08-02 09:51:46 +01:00