1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Publish Crate
on:
workflow_dispatch:
workflow_call:
inputs:
current_version:
type: string
required: true
# release:
# types: [published]
permissions:
contents: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: Publish to crates.io
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
run: cargo publish --token $CARGO_REGISTRY_TOKEN
- uses: mislav/bump-homebrew-formula-action@v3
with:
# By default, this will edit the `my_formula.rb` formula in
# homebrew-core to update its "url" field to:
# `https://github.com/OWNER/REPO/archive/refs/tags/<tag-name>.tar.gz`
# The "sha256" formula field will get automatically recomputed.
formula-name: folder-declutter
homebrew-tap: ricardodantas/homebrew-tap
base-branch: main
tag-name: v${{ inputs.current_version }}
env:
# the personal access token should have "repo" & "workflow" scopes
COMMITTER_TOKEN: ${{ secrets.COMMITTER_TOKEN }}