Skip to content

Commit 08c8830

Browse files
committed
initializing
1 parent 643deb5 commit 08c8830

File tree

5 files changed

+67
-9
lines changed

5 files changed

+67
-9
lines changed

.github/dependabot.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
5+
schedule:
6+
interval: "weekly"
7+
labels: []

.github/workflows/build.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Build Status
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
workflow_dispatch:
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
12+
cancel-in-progress: true
13+
14+
permissions:
15+
checks: write
16+
pull-requests: write
17+
18+
jobs:
19+
build:
20+
runs-on: ubuntu-latest
21+
22+
steps:
23+
- uses: actions/checkout@v4
24+
25+
- name: Prework
26+
run: |
27+
printf '[package]\nname = "rust"\nversion = "0.1.0"\nedition = "2021"\n[dependencies]\n' > Cargo.toml
28+
mkdir -p src
29+
printf 'fn main() {\n println!("Hello, world!");\n}\n' > src/main.rs
30+
31+
- name: Setup Rust
32+
uses: actions-ext/rust/setup@main
33+
34+
- name: Install
35+
run: cargo build

README.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,7 @@
1-
# rust
2-
Helper actions for rust projects
1+
# node
2+
3+
Helper actions for Node projects
4+
5+
| Name | Action Reference | Description |
6+
| :--------------- | :----------------------- | :----------------------------------------------------- |
7+
| [setup](./setup) | `actions-ext/rust/setup` | An action to setup a rust compiler and enable caching. |
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ An action to setup a rust compiler and enable caching.
77
- name: Setup Rust
88
uses: actions-ext/rust/setup-rust@v1
99
```
10+
Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,27 @@ inputs:
55
kind:
66
type: choice
77
description: "Whether to install just a default target, or all targets (e.g. for during deployments / wheel building)"
8-
options:
8+
options:
99
- minimal
1010
- full
1111
- full-wasm
1212

1313
runs:
1414
using: 'composite'
1515
steps:
16-
- name: Setup Rust
17-
uses: actions-rs/toolchain@v1
16+
- name: Set up Rust
17+
uses: dtolnay/rust-toolchain@stable
1818
with:
19-
profile: minimal
20-
toolchain: nightly
21-
components: clippy
22-
override: true
19+
toolchain: stable
20+
components: clippy, rustfmt
21+
22+
# - name: Setup Rust
23+
# uses: actions-rs/toolchain@v1
24+
# with:
25+
# profile: minimal
26+
# toolchain: nightly
27+
# components: clippy
28+
# override: true
2329

2430
# - name: Setup Rust cache
2531
# uses: Swatinem/rust-cache@v2
@@ -38,13 +44,17 @@ runs:
3844
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
3945

4046
- run: rustup target add aarch64-apple-darwin
47+
shell: bash
4148
if: ${{ inputs.kind == 'full' && runner.os == 'macOS' }}
4249

4350
- run: rustup toolchain install stable-i686-pc-windows-msvc
51+
shell: bash
4452
if: ${{ inputs.kind == 'full' && runner.os == 'Windows' }}
4553

4654
- run: rustup target add i686-pc-windows-msvc
55+
shell: bash
4756
if: ${{ inputs.kind == 'full' && runner.os == 'Windows' }}
4857

4958
- run: rustup target add wasm32-unknown-unknown
59+
shell: bash
5060
if: ${{ inputs.kind == 'full' && runner.os == 'Windows' }}

0 commit comments

Comments
 (0)