mirror of
https://github.com/socatlolmeow/drift.git
synced 2026-11-03 11:20:20 +00:00
Add Makefile, update README with install instructions, fix .gitignore
This commit is contained in:
parent
573faaeff7
commit
9c94cfbdcd
4 changed files with 63 additions and 7 deletions
11
.gitignore
vendored
11
.gitignore
vendored
|
|
@ -2,8 +2,6 @@
|
|||
# will have compiled files and executables
|
||||
debug
|
||||
target
|
||||
README.md
|
||||
|
||||
# These are backup files generated by rustfmt
|
||||
**/*.rs.bk
|
||||
|
||||
|
|
@ -23,3 +21,12 @@ rustc-ice-*.txt
|
|||
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
||||
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
||||
#.idea/
|
||||
|
||||
# makepkg build artifacts
|
||||
pkg/
|
||||
drift-music/
|
||||
src/cargo-home/
|
||||
src/drift-music/
|
||||
src/target/
|
||||
*.pkg.tar.zst
|
||||
*.pkg.tar.xz
|
||||
|
|
@ -2,11 +2,11 @@
|
|||
name = "drift"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[workspace]
|
||||
description = "A Vim-style terminal music player for YouTube Music (no login required)"
|
||||
license = "MIT"
|
||||
|
||||
[workspace]
|
||||
|
||||
[dependencies]
|
||||
ratatui = "0.29"
|
||||
anyhow = "1"
|
||||
|
|
|
|||
19
Makefile
Normal file
19
Makefile
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
PREFIX ?= /usr/local
|
||||
BINDIR := $(PREFIX)/bin
|
||||
BINARY := drift
|
||||
|
||||
.PHONY: all build install uninstall clean
|
||||
|
||||
all: build
|
||||
|
||||
build:
|
||||
cargo build --release
|
||||
|
||||
install: build
|
||||
install -Dm755 target/release/$(BINARY) $(DESTDIR)$(BINDIR)/$(BINARY)
|
||||
|
||||
uninstall:
|
||||
rm -f $(DESTDIR)$(BINDIR)/$(BINARY)
|
||||
|
||||
clean:
|
||||
cargo clean
|
||||
36
README.md
36
README.md
|
|
@ -34,9 +34,39 @@ Stream your favourite music from YouTube Music — all in one client, in your te
|
|||
|
||||
## Installation
|
||||
|
||||
> **Not implemented yet.**
|
||||
>
|
||||
> Package manager installs are not available yet. Distro-specific instructions will be added here (Arch Linux, Void Linux, NixOS, Debian/Ubuntu, etc.) once packages are published.
|
||||
### Dependencies
|
||||
|
||||
- [mpv](https://mpv.io/) — audio playback
|
||||
- [yt-dlp](https://github.com/yt-dlp/yt-dlp) — YouTube stream extraction
|
||||
- [Rust](https://rustup.rs/) (build only)
|
||||
|
||||
Install them with your package manager, e.g. on Arch:
|
||||
```
|
||||
sudo pacman -S mpv yt-dlp
|
||||
```
|
||||
|
||||
### Build & install
|
||||
|
||||
```bash
|
||||
git clone https://github.com/socatlolmeow/drift.git
|
||||
cd drift
|
||||
sudo make install
|
||||
```
|
||||
|
||||
This installs `drift` to `/usr/local/bin`. To install to `/usr/bin` instead:
|
||||
```bash
|
||||
sudo make install PREFIX=/usr
|
||||
```
|
||||
|
||||
### Other make targets
|
||||
|
||||
| Command | Description |
|
||||
|---|---|
|
||||
| `make` | Build (debug skipped, release only) |
|
||||
| `make build` | Same as above |
|
||||
| `sudo make install` | Build and install to `$PREFIX/bin` |
|
||||
| `sudo make uninstall` | Remove the installed binary |
|
||||
| `make clean` | Remove build artifacts |
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue