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

GitHub actions #1635

Merged
merged 7 commits into from Apr 1, 2020
Merged

GitHub actions #1635

merged 7 commits into from Apr 1, 2020

Conversation

UziTech
Copy link
Member

@UziTech UziTech commented Apr 1, 2020

Description

Use github actions

Contributor

  • Test(s) exist to ensure functionality and minimize regression

Committer

In most cases, this should be a different person than the contributor.

  • Draft GitHub release notes have been updated.
  • CI is green (no forced merge required).
  • Merge PR

@vercel
Copy link

vercel bot commented Apr 1, 2020

This pull request is being automatically deployed with ZEIT Now (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://zeit.co/markedjs/markedjs/5z6k4mrtb
✅ Preview: https://markedjs-git-github-actions.markedjs.now.sh

@UziTech
Copy link
Member Author

UziTech commented Apr 1, 2020

Since travis hasn't been working on PRs it seems like a good time to switch to github actions.

- name: Checkout Code
uses: actions/checkout@v2
- name: Install Node
uses: dcodeIO/setup-node-nvm@master
Copy link
Member

@styfle styfle Apr 1, 2020

Choose a reason for hiding this comment

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

I think I would rather use the official node.js action and run tests on mac and windows as well as linux. Is this only used to reference lts?

Copy link
Member Author

Choose a reason for hiding this comment

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

Is this only used to reference lts?

Yes, there is no way to reference lts or latest with the official node.js action. And updating the version number will be forgotten if we don't automate it.

Copy link
Member Author

@UziTech UziTech Apr 1, 2020

Choose a reason for hiding this comment

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

and run tests on mac and window

I don't really see how this library can change depending on which os it is on. It has no dependencies and no os dependent code.

If it does run differently on different os's with node that would be a node issue not a marked 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.

I suppose maybe testing the cli but we don't do that right now anyway.

node-version: ${{ matrix.node_version }}
- name: Install Dependencies
run: npm ci
- name: Run Unit Tests 👩🏽‍💻
Copy link
Member

Choose a reason for hiding this comment

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

Should we run lint before unit tests instead of a separate job? If it fails lint then it could fail fast.

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 think it would be better to run in parallel. We could turn off the fail-fast so it will always run both tests on node and lts and lint. For that matter we could also run unit tests and spec tests in parallel too if we wanted.

@UziTech UziTech merged commit 0c561f3 into master Apr 1, 2020
@UziTech UziTech deleted the github-actions branch April 1, 2020 21:24
@styfle
Copy link
Member

styfle commented Apr 1, 2020

I updated the required checks to use the GH Actions instead of Travis so we unblock other PRs 👍

@UziTech
Copy link
Member Author

UziTech commented Apr 2, 2020

I had to remove the checks for the protected master branch in order to allow GitHub Actions to push after the build step. We might need to use a different token if we want those checks.

@styfle
Copy link
Member

styfle commented Apr 2, 2020

That seems like a bad side effect. It looks like you removed required reviewers too 😬

@UziTech
Copy link
Member Author

UziTech commented Apr 2, 2020

ya. I don't really see that as too much of a problem since there aren't very many people who can merge PRs and we all agree there should be a reviewer before merging.

@UziTech
Copy link
Member Author

UziTech commented Apr 2, 2020

Not to mention we could all bypass that requirement before if we really wanted to.

@styfle
Copy link
Member

styfle commented Apr 3, 2020

Not to mention we could all bypass that requirement before if we really wanted to.

It's more about the process and having it codeified into the platform.

I get hundreds of github notifications for reviews across hundreds of repos so its always good to have as much help from the system as possible so I don't forget when to merge and when to wait.

@UziTech UziTech mentioned this pull request Apr 20, 2020
12 tasks
zhenalexfan pushed a commit to zhenalexfan/MarkdownHan that referenced this pull request Nov 8, 2021
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

2 participants