Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI: switch to GitHub Actions #83

Merged
merged 3 commits into from Dec 23, 2020
Merged

CI: switch to GitHub Actions #83

merged 3 commits into from Dec 23, 2020

Conversation

jrfnl
Copy link
Member

@jrfnl jrfnl commented Dec 23, 2020

CI: switch to GitHub Actions - step 1: sniff and validate stage

This commit:

  • Adds a GH Actions workflow for the CI checks which were previously run on Travis in the sniff and the validate stages.
    While these aren't 100% CS (= code style) checks, for the badge and workflow display, CS still seemed the most descriptive name.
  • Removes that part of the .travis.yml configuration.
  • Adds a "Build Status" badge in the Readme to use the results from this particular GH Actions runs.

Notes:
Builds will run on all pushes and on pull requests, with the exception of those just modifying files which are irrelevant to this workflow.

CI: switch to GitHub Actions - step 2: quick test stage

This commit:

  • Adds a GH Actions workflow for the CI checks which were previously run on Travis in the quicktest stage.
  • Removes that part of the .travis.yml configuration.

Notes:

  1. Previously, this "stage" would run on all push events, except when merging to master or develop.
    The current set-up still does so, with one exception: pushes to develop will now use this quicktest instead of the full test.
    develop is a protected branch anyhow, so all merges will already have had the full test run in the pull request.
    For merges to master, the full Test will still be used as that will generally mean we're getting ready to tag a release and some extra safety checking before a release is not a bad thing.
  2. This also updates the "high" PHP version for the "quicktest" against PHPCS dev-master from PHP 7.4 to PHP 8.0 by using latest which translates to "latest stable PHP release".

CI: switch to GitHub Actions - step 3: test and coverage stage

This commit:

  • Adds a GH Actions workflow for the CI checks which were previously run on Travis in the test and coverage stages.
  • Removes the, now redundant, .travis.yml configuration.
  • Updates the .gitattributes file.
  • Updates the "Build Status" badge in the Readme to use the results from the GH Test Actions runs.
  • Updates the "Tested on" badge in the Readme to include PHP 8.

Notes:

  1. Each of these jobs has a needs dependency on the previous job to prevent it from starting if the previous job failed.
    While not 100% necessary, this is just an efficiency tweak, being kind to the free service being offered as we know that if linting fails, the tests will fail etc.
  2. The builds in the test and coverage jobs are essentially the same as previously run on Travis, though PHP 8.0 is now fully accounted for and 8.1 is set as nightly.
  3. Previously, this "stage" would run on all pull requests events.
    The current set-up still does so, with one addition: pushes to master (merges) will now also use this workflow instead of the quicktest.
    This replaces the full run on tagging a release, meaning that thing will essentially be the same.
  4. As there are a couple of jobs which are "allowed to fail" (experimental = true), the build status will unfortunately show as "failed", even though all non-experimental jobs have succeeded.
    This is a known issue in GHA: Please support something like "allow-failure" for a given job actions/runner#2347

Closes actions/toolkit#82 (superseded)

This commit:
* Adds a GH Actions workflow for the CI checks which were previously run on Travis in the `sniff` and the `validate` stages.
    While these aren't 100% CS (= code style) checks, for the badge and workflow display, `CS` still seemed the most descriptive name.
* Removes that part of the `.travis.yml` configuration.
* Adds a "Build Status" badge in the Readme to use the results from this particular GH Actions runs.

Notes:
Builds will run on all pushes and on pull requests, with the exception of those just modifying files which are irrelevant to this workflow.
@jrfnl jrfnl added this to the 1.0.0-alpha4 milestone Dec 23, 2020
This commit:
* Adds a GH Actions workflow for the CI checks which were previously run on Travis in the `quicktest` stage.
* Removes that part of the `.travis.yml` configuration.

Notes:
1. Previously, this "stage" would run on all `push` events, except when merging to `master` or `develop`.
    The current set-up still does so, with one exception: pushes to `develop` will now use this quicktest instead of the full test.
    `develop` is a protected branch anyhow, so all merges will already have had the full test run in the pull request.
    For merges to `master`, the full Test will still be used as that will generally mean we're getting ready to tag a release and some extra safety checking before a release is not a bad thing.
2. This also updates the "high" PHP version for the "quicktest" against PHPCS `dev-master` from PHP 7.4 to PHP 8.0 by using `latest` which translates to "latest stable PHP release".
This commit:
* Adds a GH Actions workflow for the CI checks which were previously run on Travis in the `test` and `coverage` stages.
* Removes the, now redundant, `.travis.yml` configuration.
* Updates the `.gitattributes` file.
* Updates the "Build Status" badge in the Readme to use the results from the GH `Test` Actions runs.
* Updates the "Tested on" badge in the Readme to include PHP 8.

Notes:
1. Each of these jobs has a `needs` dependency on the previous job to prevent it from starting if the previous job failed.
    While not 100% necessary, this is just an efficiency tweak, being kind to the free service being offered as we know that if linting fails, the tests will fail etc.
2. The builds in the `test` and `coverage` jobs are essentially the same as previously run on Travis, though PHP 8.0 is now fully accounted for and `8.1` is set as `nightly`.
3. Previously, this "stage" would run on all `pull requests` events.
    The current set-up still does so, with one addition: pushes to `master` (merges) will now also use this workflow instead of the quicktest.
    This replaces the full run on tagging a release, meaning that thing will essentially be the same.
4. As there are a couple of jobs which are "allowed to fail" (`experimental` = true), the build status will unfortunately show as "failed", even though all non-experimental jobs have succeeded.
     This is a known issue in GHA: https://github.com/actions/toolkit/issues/399
@jrfnl jrfnl merged commit 2f0e6fb into develop Dec 23, 2020
@jrfnl jrfnl deleted the feature/move-to-gh-actions branch December 23, 2020 23:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

tool-cache extractZip not working
1 participant