Fix simple README #138
Workflow file for this run
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
name: Build Template | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
build-simple: | |
runs-on: ubuntu-latest | |
env: | |
PROJECT_NAME: ratatui-github-example | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Run cargo generate | |
uses: cargo-generate/[email protected] | |
with: | |
name: ${{ env.PROJECT_NAME }} | |
template: simple | |
- name: Install Rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
- name: Cargo check | |
# we need to move the generated project to a temp folder, away from the template project | |
# otherwise `cargo` runs would fail | |
# see https://github.com/rust-lang/cargo/issues/9922 | |
run: | | |
mv $PROJECT_NAME ${{ runner.temp }}/ | |
cd ${{ runner.temp }}/$PROJECT_NAME | |
cargo check --tests | |
build-simple-async: | |
runs-on: ubuntu-latest | |
env: | |
PROJECT_NAME: ratatui-github-example | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Run cargo generate | |
uses: cargo-generate/[email protected] | |
with: | |
name: ${{ env.PROJECT_NAME }} | |
template: simple-async | |
- name: Install Rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
- name: Cargo check | |
# we need to move the generated project to a temp folder, away from the template project | |
# otherwise `cargo` runs would fail | |
# see https://github.com/rust-lang/cargo/issues/9922 | |
run: | | |
mv $PROJECT_NAME ${{ runner.temp }}/ | |
cd ${{ runner.temp }}/$PROJECT_NAME | |
cargo check --tests | |
build-component: | |
runs-on: ubuntu-latest | |
env: | |
PROJECT_NAME: ratatui-github-example | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Run cargo generate | |
uses: cargo-generate/[email protected] | |
with: | |
name: ${{ env.PROJECT_NAME }} | |
template: component | |
arguments: --define=gh-username=ratatui --define=project-description=example --define=use-gitserver=false | |
- name: Install Rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
- name: Cargo check | |
# we need to move the generated project to a temp folder, away from the template project | |
# otherwise `cargo` runs would fail | |
# see https://github.com/rust-lang/cargo/issues/9922 | |
run: | | |
mv $PROJECT_NAME ${{ runner.temp }}/ | |
cd ${{ runner.temp }}/$PROJECT_NAME | |
cargo check --tests |