forked from open-web3-stack/open-runtime-module-library
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'open-web3-stack:master' into master
- Loading branch information
Showing
161 changed files
with
4,057 additions
and
5,684 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# Configuration for the Zepter CLI to ensure correct feature configuration in the Rust workspace. | ||
# <https://crates.io/crates/zepter> | ||
|
||
version: | ||
# File format for parsing it: | ||
format: 1 | ||
# Minimum version of the binary that is expected to work. This is just for printing a nice error | ||
# message when someone tries to use an older version. | ||
binary: 0.15.0 | ||
|
||
# The examples in this file assume crate `A` to have a dependency on crate `B`. | ||
workflows: | ||
# Check that everything is good without modifying anything: | ||
check: | ||
- [ | ||
'lint', | ||
# Check that `A` activates the features of `B`. | ||
'propagate-feature', | ||
# These are the features to check: | ||
'--features=try-runtime,runtime-benchmarks,std', | ||
# Ignore the features of dependencies that are exclusively used as dev or build. | ||
'--dep-kinds=normal:check,dev:ignore,build:ignore', | ||
# Do not try to add a new section into `[features]` of `A` only because `B` expose that feature. There are edge-cases where this is still needed, but we can add them manually. | ||
'--left-side-feature-missing=ignore', | ||
# Ignore the case that `A` it outside of the workspace. Otherwise it will report errors in external dependencies that we have no influence on. | ||
'--left-side-outside-workspace=ignore', | ||
# Some features imply that they activate a specific dependency as non-optional. Otherwise the default behaviour with a `?` is used. | ||
'--feature-enables-dep=try-runtime:frame-try-runtime,runtime-benchmarks:frame-benchmarking', | ||
# Show the paths of failed crates to have them clickable in the terminal: | ||
'--show-path', | ||
# Aux | ||
'--offline', | ||
'--locked', | ||
'--quiet', | ||
] | ||
# Format the features into canonical format: | ||
- ['format', 'features', '--offline', '--locked', '--quiet'] | ||
# Same as `check`, but actually fix the issues instead of just reporting them: | ||
default: | ||
- [ $check.0, '--fix' ] | ||
- [ $check.1, '--fix' ] | ||
|
||
# Will be displayed when any workflow fails: | ||
help: | ||
text: | | ||
ORML uses the Zepter CLI to detect abnormalities in the feature configuration. | ||
It looks like at least one check failed; please see the console output. You can try to automatically address them by running `zepter`. | ||
Otherwise please ask directly in the Merge Request, GitHub Discussions or on Matrix Chat, thank you. | ||
links: | ||
- "https://github.com/open-web3-stack/open-runtime-module-library/pull/964" | ||
- "https://github.com/ggwpez/zepter" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,27 +16,21 @@ on: | |
env: | ||
TARPAULIN_VERSION: 0.19.1 | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
test: | ||
name: Coverage Report | ||
runs-on: [self-hosted] | ||
steps: | ||
- name: Cancel Previous Runs | ||
# Only cancel non-master branch runs | ||
if: ${{ github.ref != 'refs/heads/master' }} | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- name: Install toolchain | ||
uses: dtolnay/rust-toolchain@nightly | ||
with: | ||
toolchain: nightly-2022-10-30 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
- name: Generate code coverage | ||
run: | | ||
wget https://github.com/xd009642/tarpaulin/releases/download/${{ env.TARPAULIN_VERSION }}/cargo-tarpaulin-${{ env.TARPAULIN_VERSION }}-travis.tar.gz | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Open a release PR | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
version: | ||
description: Version to release | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
make-release-pr: | ||
permissions: | ||
id-token: write # Enable OIDC | ||
pull-requests: write | ||
contents: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: taiki-e/install-action@v2 | ||
with: | ||
tool: cargo-release | ||
- uses: chainguard-dev/actions/setup-gitsign@main | ||
- uses: cargo-bins/release-pr@v2 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
version: ${{ inputs.version }} | ||
crate-release-all: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,29 +14,19 @@ on: | |
paths-ignore: | ||
- '**/README.md' | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
cancel: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Cancel Previous Runs | ||
# Only cancel non-master branch runs | ||
if: ${{ github.ref != 'refs/heads/master' }} | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
build: | ||
runs-on: [self-hosted] | ||
env: | ||
SCCACHE_CACHE_SIZE: "50G" | ||
needs: cancel | ||
SCCACHE_CACHE_SIZE: "60G" | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install toolchain | ||
uses: dtolnay/rust-toolchain@nightly | ||
with: | ||
toolchain: nightly-2022-10-30 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
- name: Install Wasm toolchain | ||
run: rustup target add wasm32-unknown-unknown | ||
- name: Check format | ||
|
@@ -49,5 +39,9 @@ jobs: | |
run: cargo clippy -- -D warnings | ||
- name: Check for Wasm | ||
run: make dev-check | ||
- name: Install Zepter | ||
run: cargo install zepter --version 0.15.0 --locked -q -f --no-default-features && zepter --version | ||
- name: Check Rust features | ||
run: make dev-features-check | ||
- name: Run tests | ||
run: make dev-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.