File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : verify homebrew formula
2+
3+ on :
4+ pull_request :
5+ branches : [ "main", "development" ]
6+ paths :
7+ - ' pkg/homebrew/Formula/quickmark-cli.rb'
8+
9+ jobs :
10+ verify_formula :
11+ runs-on : macos-latest
12+
13+ steps :
14+ - name : Checkout code
15+ uses : actions/checkout@v4
16+
17+ - name : Create local tap
18+ run : |
19+ brew tap-new local/quickmark-test
20+
21+ - name : Copy formula to tap
22+ run : |
23+ cp pkg/homebrew/Formula/quickmark-cli.rb $(brew --repo local/quickmark-test)/Formula/
24+
25+ - name : Install formula from source
26+ run : |
27+ brew install --build-from-source local/quickmark-test/quickmark-cli
Original file line number Diff line number Diff line change @@ -14,6 +14,10 @@ class QuickmarkCli < Formula
1414 end
1515 end
1616
17+ def install
18+ bin . install "qmark"
19+ end
20+
1721 test do
1822 # Create a test markdown file
1923 ( testpath /"test.md" ) . write ( "# Test\n \n This is a test." )
Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ qmark --config quickmark.toml *.md
3030## Formula Details
3131
3232- ** Location** : ` Formula/quickmark-cli.rb `
33- - ** Binary name** : ` qmark `
33+ - ** Binary name** : ` qmark `
3434- ** Architecture support** : Intel and Apple Silicon Macs
3535- ** Installation method** : Pre-compiled binaries from GitHub releases
3636
@@ -43,6 +43,14 @@ When releasing a new version:
43433 . Test the formula: ` brew install --build-from-source ./Formula/quickmark-cli.rb `
44444 . Commit and push the changes
4545
46+ ### Testing changes locally
47+
48+ ``` bash
49+ brew tap-new local/quickmark-test
50+ cp pkg/homebrew/Formula/quickmark-cli.rb $( brew --repo local/quickmark-test) /Formula/
51+ brew install --build-from-source local/quickmark-test/quickmark-cli
52+ ```
53+
4654## Updating
4755
4856``` bash
@@ -55,4 +63,4 @@ brew upgrade quickmark-cli
5563``` bash
5664brew uninstall quickmark-cli
5765brew untap ekropotin/quickmark
58- ```
66+ ```
You can’t perform that action at this time.
0 commit comments