Repository navigation
Commit 09eeee1
authored
ci: add CI, CodeQL and release automation (#18)
* chore: stop tracking the generated build output
`prepare` runs `expo-module build` on every install, so `build/` was already
being regenerated behind the tracked copy, which is a babel version behind
what the source compiles to now.
It also blocks release-it: every `yarn install` leaves the tree dirty, and a
dirty tree aborts a release.
npm still gets the directory. It's in `files`, and `prepare` rebuilds it on
publish and on git installs.
* build(deps): add eslint 8 and release-it
`yarn lint` has been broken because eslint isn't in the lockfile at all, so it
resolved to v10, which wants a flat config while the repo has `.eslintrc.js`.
expo-module-scripts pulls eslint-config-universe 12, and that one is built
against eslint 8.
release-it and @release-it/conventional-changelog are for the release
workflow.
* ci: add validation and codeql workflows
The repo had no workflows at all, so nothing ran on a PR.
CI covers pushes to master and every PR: lint, test, build, then `npm pack
--dry-run` so an empty tarball fails the job now that `build/` is generated at
install time instead of committed.
CodeQL follows safe-jsx: PRs, pushes to master, and a weekly scan.
* ci: cut releases with release-it and a generated changelog
1.0.8 was bumped, tagged, released and published by hand, and CHANGELOG.md
stopped at 1.0.6 under `@config-plugins/react-native-codepush`, a name this
package has never been published under.
release-it now derives all of it from the conventional commits since the last
tag: the version bump, the CHANGELOG section, the annotated tag message and the
GitHub release body. A `!` or a `BREAKING CHANGE:` footer bumps the major and
shows up under the same `⚠ BREAKING CHANGES` heading in all three.
The trigger is `workflow_dispatch` with an optional increment override, not a
push to master. conventional-commits treats any commit as at least a patch, so
pushing a README fix would otherwise ship a version.
Backfilled 1.0.7 and 1.0.8 from git history and reshaped the older entries into
the layout release-it writes, so the file reads as one thing.
* build(deps): add prettier so eslint stops hanging
`yarn lint` didn't fail on eslint 8, it hung with no output, in CI and locally.
eslint-config-universe peer-requires `prettier >=3` and it was never installed.
eslint-plugin-prettier 5 loads prettier through a synckit worker, and with
nothing to load the worker never answers, so eslint blocks forever inside the
`prettier/prettier` rule. Nothing prints because the rule never returns.
With prettier 3.9.6 installed, `yarn lint` finishes in 4 seconds.
* style: format src with prettier 3
`eslint src --fix`. prettier 3 defaults `trailingComma` to `all` where 2
defaulted to `es5`, so almost all of this is commas. The indentation changes in
stringsDependency and infoPlistDependency come from #11 and #14, which were
written while lint was hanging.
* ci: fail lint on warnings
universe sets most of its rules to `warn`, so `yarn lint` exits 0 no matter
what eslint reports. src is clean as of the commit before this one, so
`--max-warnings 0` starts from zero.1 parent 367e340 commit 09eeee1
49 files changed
Lines changed: 1708 additions & 470 deletions
File tree
- .github/workflows
- build
- android
- ios
- utils
- src
- android
- __tests__
- ios
- utils
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
4 | 16 | | |
5 | | - | |
| 17 | + | |
6 | 18 | | |
7 | | - | |
| 19 | + | |
8 | 20 | | |
9 | | - | |
| 21 | + | |
10 | 22 | | |
11 | | - | |
| 23 | + | |
12 | 24 | | |
13 | | - | |
| 25 | + | |
14 | 26 | | |
15 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
0 commit comments