Skip to content

Commit

Permalink
Merge branch 'main' into epic/http
Browse files Browse the repository at this point in the history
  • Loading branch information
josephjclark committed Jan 13, 2024
2 parents 027b581 + 6cd4c9a commit 7ec82ec
Show file tree
Hide file tree
Showing 10 changed files with 244 additions and 37 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ name: CI

# Runs when a pull request is created or its head is updated
# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request
on:
pull_request:
push:
branches: [main]
on: pull_request

jobs:
build:
Expand Down
32 changes: 32 additions & 0 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Publish

on:
push:
branches:
- main

jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- uses: actions/setup-node@v3
with:
node-version: '18.17.1'
- uses: pnpm/action-setup@v2
with:
version: 8.6.8
- run: pnpm install --frozen-lockfile
- run: pnpm build
- run: pnpm test
- run: pnpm config set "//registry.npmjs.org/:_authToken=${NPM_TOKEN}"
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- run:
pnpm publish -r --report-summary --publish-branch main --access=public

- run: pnpm slack:notify
env:
SLACK_TOKEN: ${{ secrets.SLACK_TOKEN }}
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -116,3 +116,6 @@ dist
.fuse_*

.vscode/


/pnpm-publish-summary.json
41 changes: 13 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -237,38 +237,23 @@ Commit the changeset to the repo when you're ready.
## Releases
To release, run this from the root:
New releases will be published to npm automatically when merging into the `main`
branch`.

```
pnpm changeset version
```
Version numbers should be bumped with `changeset` and git tags should be pushed
to the release branch BEFORE merging.

This will bump all changed packages and update their release notes.
1. Run `pnpm changeset version` from root to bump versions
1. Run `pnpm install`
1. Commit the new version numbers
1. Run `pnpm changeset tag` to generate tags
1. Push tags `git push --tags`

Then install packages and commit changes with:
Rememebr tags may need updating if commits come in after the tags are first
generated.

```
pnpm install
```
Build the adaptors with:
```
pnpm -r run build
```
To publish the release, run:
```
pnpm changeset publish
```
And finally, push the tags to Github so that the source code can be browsed for
each new release with:
```
git push --follow-tags
```
When ready, merge the branch to main and a Github Action will trigger the
release.

## Build tooling

Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
"test:imports": "cd tools/import-tests && pnpm test",
"test": "pnpm lint && pnpm --filter \"./packages/**\" test && pnpm test:imports",
"lint": "pnpm --filter \"./packages/**\" lint",
"metadata": "pnpm -C tools/metadata cli"
"metadata": "pnpm -C tools/metadata cli",
"slack:notify": "cd tools/slack && pnpm notify"
},
"author": "Open Function Group",
"license": "ISC",
Expand Down
4 changes: 4 additions & 0 deletions packages/template/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# @openfn/language-template

## 3.0.2

Test release. No code changes.

## 3.0.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/template/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@openfn/language-template",
"version": "3.0.1",
"version": "3.0.2",
"description": "The standard template for building OpenFn adaptors",
"type": "module",
"exports": {
Expand Down
103 changes: 100 additions & 3 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions tools/slack/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "@openfn/slack-notify",
"private": true,
"version": "1.0.0",
"description": "Util to notify npm publish changes to slack",
"main": "src/index.js",
"scripts": {
"notify": "node src/index.js"
},
"author": "",
"license": "ISC",
"dependencies": {
"@slack/web-api": "^6.8.1"
}
}
Loading

0 comments on commit 7ec82ec

Please sign in to comment.