Feat: more bluefin dinos and brew installs #5

Merged
Robin7 merged 0 commits from main into main 2026-08-10 16:56:09 +00:00
Robin7 commented 2026-08-10 06:09:39 +00:00 (Migrated from codeberg.org)

Added more pngs and such with a brew tap that installs from the tar release and such

Added more pngs and such with a brew tap that installs from the tar release and such
thelinuxcast commented 2026-08-10 06:31:32 +00:00 (Migrated from codeberg.org)

So I don't know anything about Brew, so I let claude review this in its entirety; this is the outcome:

Summary
Two good instincts here — a Homebrew formula and more Bluefin art — but the two halves don't connect, and the install docs teach commands that Homebrew has removed. Formula/mattfetch.rb itself is well-formed (correct tap layout, right idioms, valid test do, license "MIT" matches LICENSE), and commit f211a03 correctly repointed url/homepage/head/sha256 from the fork to upstream. The problems are around it.

Blocking

  1. brew install no longer works — 2 of the 4 documented commands will fail for every user.

Homebrew removed installing formulae from arbitrary URLs for security; you get Non-checksummed download of ... from an arbitrary URL is disabled!. Both of these are dead:

brew install https://codeberg.org/.../Formula/mattfetch.rb ← the first method the README teaches
brew install --HEAD https://... ← same
Only brew install ./Formula/mattfetch.rb (local path) and the tap route still work. The "From the Formula File" section should be cut down to the local-checkout form, with the tap promoted to the primary method.

  1. The formula pins v0.5, which contains none of the images this PR adds.

git ls-tree v0.5:assets returns zero matches for bluefin-*/dakota/karl. So brew install mattfetch ships the old asset set — the headline feature is unreachable via the install method added in the same PR. Needs a fresh tag + sha256 after merge.

  1. No code path can ever select the new images.

get_distro_image_name at display.rs:653 is an exhaustive match on DistroId — Bluefin => "bluefin.png", hard-coded. bluefin-2..6.png, dakota.png, and karl.png are unreachable. The escape hatches don't help:

display.image_path (display.rs:625) does a bare Path::new(custom_path).exists(), so it needs a literal absolute path. Under Homebrew that's a Cellar path containing the version number — it breaks on every upgrade.
config.display.logo (the logo = "nix" key documented at README.md:445) is never read anywhere in the source. grep -rn "display.logo" excluding logo_size/logo_position returns nothing.
The cleanest fix is to mirror the anime handling: get_available_anime_images (display.rs:522) already auto-discovers numbered variants. Doing the same for distro logos, or routing image_path through resolve_asset_path so bare filenames work, would make these images usable. Worth asking the contributor to add that here — otherwise 22.6 MiB lands with no way to see it.

  1. Version mismatch: brew info and --version will disagree.

version "0.5.0", but tag v0.5's Cargo.toml says 0.4.0 (and main is now 0.6.0). Since main.rs:13-14 uses #[command(name = "mattfetch")] + #[command(version)], the binary prints mattfetch 0.4.0. Note commit a06d10c ("Updated the version number") changed this from 0.4.0, which was actually correct for that tag. Best fix: drop the version stanza and let Homebrew derive it from the URL, and straighten out the upstream tag/Cargo.toml drift separately.

Fragility
5. Codeberg auto-generated archive tarballs aren't byte-stable. If Gitea changes its tar/gzip output, the sha256 breaks and every install fails. Pin the git source instead:

url "https://codeberg.org/thelinuxcast/mattfetch.git", tag: "v0.5", revision: "0d084cdc43"
I did not verify the checksum — that needs a download, so it's yours to run:

curl -sL https://codeberg.org/thelinuxcast/mattfetch/archive/v0.5.tar.gz | sha256sum
Expected: 2ec5db0eefc8ee08f93410cbf0fed1ed0ca0df1f8b741a08cc2be02a52641683

Polish
6. Image sizes are ~20× larger than needed. Measured from the blobs:

file dims size
bluefin.png (existing) 726² 232 KB
bluefin-2.png 3000² 9.1 MB
bluefin-6.png 2100² 3.0 MB
dakota.png 2100² 2.3 MB
logo_size is clamped to ≤1200px at display.rs:100, so every one of these is downscaled — the extra pixels are never rendered. Worse, image::open (image_display.rs:33) decodes the full image: 3000×3000 RGBA is a ~36 MB allocation plus a resize, on every single run of a tool whose selling point is being instant. The pack is already 192 MiB and brew tap clones the repo. Resizing to 1200px max and running oxipng/pngquant would cut ~95% with no visible difference.

  1. brew trust is correct but broader than needed. The syntax and the "required since Homebrew 6.0" note both check out. But Homebrew's docs explicitly prefer item-specific trust over whole-tap. Suggest documenting brew trust --formula thelinuxcast/mattfetch/mattfetch instead.

  2. README doesn't mention the new images at all — no list, no example of how to select one.


I'm going to assume most of that makes sense to you. #1 might as well have been in German for me. The rest looks like it's most ly about paths and version hard coding.

So I don't know anything about Brew, so I let claude review this in its entirety; this is the outcome: Summary Two good instincts here — a Homebrew formula and more Bluefin art — but the two halves don't connect, and the install docs teach commands that Homebrew has removed. Formula/mattfetch.rb itself is well-formed (correct tap layout, right idioms, valid test do, license "MIT" matches LICENSE), and commit f211a03 correctly repointed url/homepage/head/sha256 from the fork to upstream. The problems are around it. Blocking 1. brew install <URL> no longer works — 2 of the 4 documented commands will fail for every user. Homebrew removed installing formulae from arbitrary URLs for security; you get Non-checksummed download of ... from an arbitrary URL is disabled!. Both of these are dead: brew install https://codeberg.org/.../Formula/mattfetch.rb ← the first method the README teaches brew install --HEAD https://... ← same Only brew install ./Formula/mattfetch.rb (local path) and the tap route still work. The "From the Formula File" section should be cut down to the local-checkout form, with the tap promoted to the primary method. 2. The formula pins v0.5, which contains none of the images this PR adds. git ls-tree v0.5:assets returns zero matches for bluefin-*/dakota/karl. So brew install mattfetch ships the old asset set — the headline feature is unreachable via the install method added in the same PR. Needs a fresh tag + sha256 after merge. 3. No code path can ever select the new images. get_distro_image_name at display.rs:653 is an exhaustive match on DistroId — Bluefin => "bluefin.png", hard-coded. bluefin-2..6.png, dakota.png, and karl.png are unreachable. The escape hatches don't help: display.image_path (display.rs:625) does a bare Path::new(custom_path).exists(), so it needs a literal absolute path. Under Homebrew that's a Cellar path containing the version number — it breaks on every upgrade. config.display.logo (the logo = "nix" key documented at README.md:445) is never read anywhere in the source. grep -rn "display\.logo" excluding logo_size/logo_position returns nothing. The cleanest fix is to mirror the anime handling: get_available_anime_images (display.rs:522) already auto-discovers numbered variants. Doing the same for distro logos, or routing image_path through resolve_asset_path so bare filenames work, would make these images usable. Worth asking the contributor to add that here — otherwise 22.6 MiB lands with no way to see it. 4. Version mismatch: brew info and --version will disagree. version "0.5.0", but tag v0.5's Cargo.toml says 0.4.0 (and main is now 0.6.0). Since main.rs:13-14 uses #[command(name = "mattfetch")] + #[command(version)], the binary prints mattfetch 0.4.0. Note commit a06d10c ("Updated the version number") changed this from 0.4.0, which was actually correct for that tag. Best fix: drop the version stanza and let Homebrew derive it from the URL, and straighten out the upstream tag/Cargo.toml drift separately. Fragility 5. Codeberg auto-generated archive tarballs aren't byte-stable. If Gitea changes its tar/gzip output, the sha256 breaks and every install fails. Pin the git source instead: url "https://codeberg.org/thelinuxcast/mattfetch.git", tag: "v0.5", revision: "0d084cdc43e0ecd22997537685470cc10c0cff41" I did not verify the checksum — that needs a download, so it's yours to run: curl -sL https://codeberg.org/thelinuxcast/mattfetch/archive/v0.5.tar.gz | sha256sum Expected: 2ec5db0eefc8ee08f93410cbf0fed1ed0ca0df1f8b741a08cc2be02a52641683 Polish 6. Image sizes are ~20× larger than needed. Measured from the blobs: file dims size bluefin.png (existing) 726² 232 KB bluefin-2.png 3000² 9.1 MB bluefin-6.png 2100² 3.0 MB dakota.png 2100² 2.3 MB logo_size is clamped to ≤1200px at display.rs:100, so every one of these is downscaled — the extra pixels are never rendered. Worse, image::open (image_display.rs:33) decodes the full image: 3000×3000 RGBA is a ~36 MB allocation plus a resize, on every single run of a tool whose selling point is being instant. The pack is already 192 MiB and brew tap clones the repo. Resizing to 1200px max and running oxipng/pngquant would cut ~95% with no visible difference. 7. brew trust is correct but broader than needed. The syntax and the "required since Homebrew 6.0" note both check out. But Homebrew's docs explicitly prefer item-specific trust over whole-tap. Suggest documenting brew trust --formula thelinuxcast/mattfetch/mattfetch instead. 8. README doesn't mention the new images at all — no list, no example of how to select one. --- I'm going to assume most of that makes sense to you. #1 might as well have been in German for me. The rest looks like it's most ly about paths and version hard coding.
Robin7 commented 2026-08-10 10:14:35 +00:00 (Migrated from codeberg.org)

Alright updated the needed things

1, is fixed
2, this will need to be fixed by you with a new release
3, I assume this can be done with config right?
4, I just followed the release and that was the version you had
5, I assume this should be fine because I pulled the tar and got the sha256
6, nonsense
7, It works just fine this way
8, There is no need for the readme to update on images when it's just bluefin nonsense

Alright updated the needed things 1, is fixed 2, this will need to be fixed by you with a new release 3, I assume this can be done with config right? 4, I just followed the release and that was the version you had 5, I assume this should be fine because I pulled the tar and got the sha256 6, nonsense 7, It works just fine this way 8, There is no need for the readme to update on images when it's just bluefin nonsense
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
thelinuxcast/mattfetch!5
No description provided.