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

chore(tooling): setup GitHub actions, add CODEOWNERS and PR template #20

Merged
merged 8 commits into from Nov 30, 2021

Conversation

shortcuts
Copy link
Member

🧭 What and Why

🎟 JIRA Ticket: https://algolia.atlassian.net/browse/APIC-180

Changes included :

  • Setup GitHub actions:
    • build and validate spec files
    • generate, build and lint JavaScript client
  • Add CODEOWNERS file
  • Add PULL_REQUEST_TEMPLATE file

🧪 Test

@shortcuts shortcuts self-assigned this Nov 29, 2021
Comment on lines 7 to 25
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
node: ['16']
steps:
- uses: actions/checkout@v2

- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: '11'

- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
cache: 'yarn'
cache-dependency-path: 'yarn.lock'
Copy link
Member Author

Choose a reason for hiding this comment

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

I wonder if we can add this whole part to a local GH action, will check 🤔

millotp
millotp previously approved these changes Nov 29, 2021
Copy link
Collaborator

@millotp millotp left a comment

Choose a reason for hiding this comment

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

Beautiful CI ! 🥳

.github/PULL_REQUEST_TEMPLATE.md Outdated Show resolved Hide resolved

on: [push]

jobs:
Copy link
Collaborator

Choose a reason for hiding this comment

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

This job could depend on specs because it won't build with invalid spec.

Copy link
Member Author

@shortcuts shortcuts Nov 29, 2021

Choose a reason for hiding this comment

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

Done, apparently the workflow_run option is only triggered when deployed on the main branch, which seems odd 🤔

Copy link
Contributor

Choose a reason for hiding this comment

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

From what I remember when I worked on Github Actions, there are a bunch of things that worked only on main and not on prs, this was quite an annoying limitation :(

Copy link
Member Author

Choose a reason for hiding this comment

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

Will see once this PR is merged and will fix if it's not the case!


- uses: actions/setup-node@v2
with:
node-version: 16
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you link this to .nvmrc ? It's seems possible but not supported by default: issue

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Collaborator

Choose a reason for hiding this comment

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

This feature was released just 5 hours ago ! I think the github cache is not updated yet:

Warning: Unexpected input(s) 'node-version-file', valid inputs are ['always-auth', 'node-version', 'architecture', 'check-latest', 'registry-url', 'scope', 'token', 'cache', 'cache-dependency-path', 'version']

Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe you can pin setup-node to version 2.5.0 ? 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

Maybe you can pin setup-node to version 2.5.0

It seems to work now!

Base automatically changed from feat/recommend-spec to main November 30, 2021 09:58
Copy link
Collaborator

@millotp millotp left a comment

Choose a reason for hiding this comment

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

let's go !

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.

None yet

3 participants