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

Add GitHub workflow for CI #93

Merged
merged 2 commits into from
Nov 12, 2021

Conversation

kwridan
Copy link
Contributor

@kwridan kwridan commented Sep 14, 2021

Describe your changes

  • A new xcdiff GitHub workflow is being added for CI
  • Currently configures 2 separate jobs
    • Linting
    • Build & Test
  • The build and test were grouped together as running them on the same node allows re-using some of the cached build artefacts

Additional context

We'd like to migrate off of Travis to GitHub Actions, this PR introduces the GitHub workflow, once verified we can remove the .travis.yml file.

@codecov
Copy link

codecov bot commented Sep 14, 2021

Codecov Report

Merging #93 (b9dc537) into main (f898d30) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main      #93   +/-   ##
=======================================
  Coverage   96.22%   96.22%           
=======================================
  Files          47       47           
  Lines        1853     1853           
=======================================
  Hits         1783     1783           
  Misses         70       70           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f898d30...b9dc537. Read the comment docs.

marciniwanicki
marciniwanicki previously approved these changes Oct 30, 2021
- Declaring all the current CI steps, lint, build and test as a GitHub workflow

Signed-off-by: Kassem Wridan <kwridan@bloomberg.net>
- The workflow now limits the github token permissions
- The workflow now leverages caching to speed up builds

Signed-off-by: Kassem Wridan <kwridan@bloomberg.net>
@kwridan
Copy link
Contributor Author

kwridan commented Nov 11, 2021

Pushed a few updates to include:

  • Specifying GitHub token permissions (made it a bit more restricted)
  • Added caching support to speed up builds

Some example runs from my fork:

On a PR:
kwridan#1

On main:
https://github.com/kwridan/xcdiff/actions

Screenshot 2021-11-11 at 08 17 05

The bit that I'm not a 100% sure on is CodeCov integration, we may need to add a GitHub secret to pass along its token. That may cause some friction on PRs from forks as secrets may not be available in that scenario 🤔

There's also a dedicated CodeCov action we may be able to leverage https://github.com/codecov/codecov-action

@kwridan
Copy link
Contributor Author

kwridan commented Nov 12, 2021

I've ran another test with CodeCov enabled on my personal fork - I didn't need to setup a token for it either (seems to not be required for public repos)

kwridan#2

@marciniwanicki marciniwanicki marked this pull request as ready for review November 12, 2021 09:50
Copy link
Contributor

@marciniwanicki marciniwanicki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@kwridan
Copy link
Contributor Author

kwridan commented Nov 12, 2021

As a final test - here's an example verifying fork PRs workflows

kwridan#3

@kwridan kwridan merged commit cfe4380 into bloomberg:main Nov 12, 2021
@kwridan kwridan deleted the feature/migrate-to-github-actions branch November 12, 2021 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants