Skip to content

Commit

Permalink
Only run workflows if specific files change. (#98)
Browse files Browse the repository at this point in the history
* Update workflows.

* Use an action.

* Fixes.

* Fix key.

* Update readme.

* Add titles.

* Add stubbed files.

* Add paths to moon.

* Fix matrix.
  • Loading branch information
milesj authored May 18, 2022
1 parent 5f1743f commit 3a1f397
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 4 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/moon-stub.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks
name: Moon
on:
pull_request:
paths-ignore:
- packages/**
- website/**
- package.json
- yarn.lock
jobs:
ci:
name: CI
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
node-version: [14, 16, 18]
steps:
- run: 'echo "Not affected, skipping"'
5 changes: 5 additions & 0 deletions .github/workflows/moon.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ on:
branches:
- master
pull_request:
paths:
- packages/**
- website/**
- package.json
- yarn.lock
jobs:
ci:
name: CI
Expand Down
33 changes: 33 additions & 0 deletions .github/workflows/rust-stub.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks
name: Rust
on:
pull_request:
paths-ignore:
- crates/**
- tests/**
- Cargo.lock
- Cargo.toml
- Makefile.toml
- rust-toolchain.toml
jobs:
format:
name: Format
runs-on: ubuntu-latest
steps:
- run: 'echo "Not affected, skipping"'
lint:
name: Lint
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
steps:
- run: 'echo "Not affected, skipping"'
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- run: 'echo "Not affected, skipping"'
7 changes: 7 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ on:
branches:
- master
pull_request:
paths:
- crates/**
- tests/**
- Cargo.lock
- Cargo.toml
- Makefile.toml
- rust-toolchain.toml
jobs:
format:
name: Format
Expand Down
7 changes: 3 additions & 4 deletions packages/cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@ JavaScript ecosystem, written in Rust!
moon can be installed with npm, pnpm, or yarn.

```bash
# Install the dependency and create the binary
# Install the dependency
yarn add --dev @moonrepo/cli
yarn install

# Access the Rust binary and initialize moon
$(yarn bin moon) init
# Initialize moon in the repo
npx @moonrepo/cli init
```

## Usage
Expand Down

0 comments on commit 3a1f397

Please sign in to comment.