Skip to content

Commit

Permalink
Merge pull request #2 from zombocoder/feature/add-melodica-brew-formula
Browse files Browse the repository at this point in the history
Add Homebrew Formula for Melodica
  • Loading branch information
zombocoder authored Nov 8, 2024
2 parents 71205f4 + d828ef3 commit dae3126
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 2 deletions.
21 changes: 19 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Melodica is a console-based audio player built with Go. It supports playback of

## Screenshot

<img width="1505" alt="image" src="https://github.com/user-attachments/assets/d6e6e43b-73ad-4cab-a998-d6e8855a3f4a">
<img width="1829" alt="image" src="https://github.com/user-attachments/assets/77c12fa6-4d3b-4f5b-8617-bdb1b9e0a7e2">

## Features

Expand All @@ -25,7 +25,24 @@ Melodica is a console-based audio player built with Go. It supports playback of

## Installation

To install Melodica, ensure you have Go installed (version 1.20 or later). You can install the latest version of Melodica directly from the GitHub repository using the following command:
### Homebrew (macOS)

To install Melodica on macOS via Homebrew, use the following commands:

1. Tap the repository:

```bash
brew tap zombocoder/melodica
```

2. Install Melodica:
```bash
brew install melodica
```

### Go Installation

If you prefer to install Melodica via Go, ensure you have Go installed (version 1.20 or later), then run:

```bash
go install github.com/zombocoder/melodica/cmd/melodica@latest
Expand Down
19 changes: 19 additions & 0 deletions melodica.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
class Melodica < Formula
desc "Melodica is a console-based audio player built with Go"
homepage "https://github.com/zombocoder/melodica"
url "https://github.com/zombocoder/melodica/archive/v0.0.2.tar.gz"
sha256 "6f66853918049596774ccfa098109aa57d8b852bbfddfc88e5773346375cdb8c"
license "MIT"
version "0.0.2"

depends_on "go" => :build

def install
system "go", "build", *std_go_args(output: bin/"melodica"), "./cmd/melodica"
end

test do
assert_match "Usage: melodica <playlist.txt>", shell_output("#{bin}/melodica -h", 2)
end
end

0 comments on commit dae3126

Please sign in to comment.