Skip to content

Commit fbc7fb1

Browse files
committed
CI updates.
1 parent 9fa6dbb commit fbc7fb1

File tree

3 files changed

+56
-1
lines changed

3 files changed

+56
-1
lines changed

.github/workflows/ci.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,15 @@ jobs:
1212
toolchain: stable
1313
target: wasm32-unknown-unknown
1414
default: true
15-
components: clippy
15+
components: clippy, rustfmt
1616
- uses: actions-rs/cargo@v1
1717
with:
1818
command: clippy
1919
args: -- -D warnings
20+
- uses: actions-rs/cargo@v1
21+
with:
22+
command: fmt
23+
args: -- --check
2024
- uses: actions-rs/cargo@v1
2125
with:
2226
command: build

.github/workflows/release.yaml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: release
2+
on:
3+
push:
4+
tags:
5+
- 'v*'
6+
7+
jobs:
8+
release:
9+
runs-on: ubuntu-latest
10+
outputs:
11+
upload_url: ${{ steps.create_release.outputs.upload_url }}
12+
steps:
13+
- uses: actions/checkout@v2
14+
- run: echo ::set-env name=RELEASE_VERSION::${GITHUB_REF#refs/*/}
15+
- uses: actions-rs/toolchain@v1
16+
with:
17+
toolchain: stable
18+
- uses: actions-rs/cargo@v1
19+
with:
20+
command: build
21+
args: --release
22+
- name: create release
23+
id: create_release
24+
uses: actions/create-release@v1
25+
env:
26+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27+
with:
28+
tag_name: ${{ github.ref }}
29+
release_name: ${{ github.ref }}
30+
body: ""
31+
draft: true
32+
prerelease: false

CONTRIBUTING.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
contributing
2+
============
3+
We are all living beings, and what is most important is that we respect each other and work together. If you can not uphold this simple standard, then your contributions are not welcome.
4+
5+
## linting
6+
We are using clippy & rustfmt. Clippy is SO GREAT! Rustfmt ... has a lot more growing to do; however, we are using it for uniformity.
7+
8+
Please be sure that you've configured your editor to use clippy & rustfmt, or execute them manually before submitting your code. CI will fail your PR if you do not.
9+
10+
## release workflow
11+
We follow [semver](https://semver.org/spec/v2.0.0.html) for versioning this system.
12+
13+
- [ ] update `Cargo.toml` `version`.
14+
- [ ] ensure CI completes successfully.
15+
- [ ] add a new tag to the repo matching the new `Cargo.toml` `version`. Either via `git tag` or via the Github UI.
16+
- all release tags should start with the letter `v` followed by a semver version.
17+
- [ ] CI is configured for release tags and will create a new Github release.
18+
- [ ] once CI for the tag has finished successfully, update the new release page with details on the changes made, which should reflect the content of the `CHANGELOG.md`.
19+
- [ ] lastly, `cargo publish`.

0 commit comments

Comments
 (0)