Files
ArchiveBox/brew_dist/archivebox.rb
Claude 7c7a9ee599 Fix PR review comments: service flags, DATA_DIR, version pinning, upgrade safety
- Remove --setup flag from systemd service and CI (not valid in 0.9.x)
- Remove release triggers from debian/homebrew workflows (handled by release.yml)
- Fix brew post_install to set DATA_DIR so it initializes in var/archivebox
- Add PATH export to deb wrapper script for bundled console scripts
- Remove pip install fallback in install.sh (strict version pinning)
- Guard preremove.sh cleanup to only run on remove/purge, not upgrade
- Initialize SDIST_URL/SDIST_SHA256 in build_brew.sh (nounset safety)
- Pin awalsh128/cache-apt-pkgs-action to v1.6.0 (supply chain safety)

https://claude.ai/code/session_01Vx1EsNrNySgsc8Y67dGzCn
2026-03-15 03:12:37 +00:00

59 lines
1.7 KiB
Ruby

# This formula is auto-generated by bin/build_brew.sh using homebrew-pypi-poet.
# To update: run bin/build_brew.sh, or trigger the GitHub Actions homebrew workflow.
#
# Users install with:
# brew tap archivebox/archivebox
# brew install archivebox
class Archivebox < Formula
include Language::Python::Virtualenv
desc "Self-hosted internet archiving solution"
homepage "https://github.com/ArchiveBox/ArchiveBox"
url "https://files.pythonhosted.org/packages/source/a/archivebox/archivebox-0.9.3.tar.gz"
sha256 "" # auto-filled by bin/build_brew.sh
license "MIT"
head "https://github.com/ArchiveBox/ArchiveBox.git", branch: "dev"
depends_on "python@3.13"
depends_on "node"
depends_on "git"
depends_on "wget"
depends_on "curl"
depends_on "ripgrep"
depends_on "yt-dlp"
on_linux do
depends_on "pkg-config" => :build
depends_on "openssl@3"
depends_on "libffi"
end
# Python dependency resource blocks are auto-generated by bin/build_brew.sh
# using homebrew-pypi-poet. Run that script to populate this section.
# AUTOGENERATED_RESOURCES_START
# AUTOGENERATED_RESOURCES_END
def install
virtualenv_install_with_resources
end
def post_install
# Install runtime dependencies (plugins, JS extractors, etc.)
(var/"archivebox").mkpath
system({ "DATA_DIR" => var/"archivebox" }, bin/"archivebox", "install", "--binproviders", "pip,npm")
end
service do
run [opt_bin/"archivebox", "server", "--quick-init", "0.0.0.0:8000"]
keep_alive crashed: true
working_dir var/"archivebox"
log_path var/"log/archivebox.log"
error_log_path var/"log/archivebox.log"
end
test do
assert_match version.to_s, shell_output("#{bin}/archivebox version")
end
end