Skip to content

another one

another one #18

Workflow file for this run

name: Build Template
on:
workflow_dispatch:
schedule:
- cron: '0 18 * * 5'
push:
branches: [ '*' ]
paths-ignore:
- "**/docs/**"
- "**.md"
jobs:
build:
runs-on: ubuntu-latest
env:
PROJECT_NAME: server-template
steps:
- uses: actions/checkout@v2
with:
path: my_workspace
- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: rustfmt, clippy
- name: Install cargo-generate
run: cargo install cargo-generate
- name: Setup Workspace Directory
run: |
echo '[workspace]' >> my_workspace/Cargo.toml
echo 'resolver = "2"' >> my_workspace/Cargo.toml
echo 'members = ["server", "services/auth"]' >> my_workspace/Cargo.toml
echo 'exclude = ["templates"]' >> my_workspace/Cargo.toml
mkdir -p my_workspace/services
- name: Generate Auth Service from Local Template
run: |
cd my_workspace/services
cargo generate --git https://github.com/codeitlikemiley/service_template --name auth --branch main --define service_description=default --define rpc_method=make
- uses: actions/checkout@v4
- uses: cargo-generate/cargo-generate-action@latest
with:
name: ${{ env.PROJECT_NAME }}
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
- run: |
mv $PROJECT_NAME ${{ runner.temp }}/
cd ${{ runner.temp }}/$PROJECT_NAME
cargo check