feat: add homebrew Formula#42
Merged
bboynton97 merged 1 commit intoagentstack-ai:mainfrom Nov 12, 2024
Merged
Conversation
I had some issues with my local python env, so built a homebrew formula. In general, homebrew allows installation of packages from GitHub with the following format ``` brew install <username>/<repo> ``` However, this requires that we have a repo named github.com/agentops-ai/homebrew-agentstack. If we want to keep it all in the same repo, users can run the following instead ``` brew tap agentops-ai/agentstack https://github.com/agentops-ai/agentstack brew install agentops-ai/agentstack/agentstack ``` In order for this to work, we need to ensure that every dep from the lockfile is codified in the formula, and that the url + shasum are kept up to date for each release. In the formula, you'll see "url" and "shasum". Those will need updating per release. You'll also need to change the list of resources if anything changes with your deps. This is pretty annoying, but luckily there's some tooling! I used "poet" to generate a bunch of this, though it needed some manual tweaking - https://github.com/tdsmith/homebrew-pypi-poet Also, note this line in the install function ``` ENV.append_to_cflags '-Wno-incompatible-function-pointer-types' if DevelopmentTools.clang_build_version >= 1500 ``` There's currently an issue with the later versions of Xcode, while building the YAML package used here Upstream ref: https://sourceforge.net/p/ruamel-yaml-clib/tickets/32/
674ca49 to
d68872a
Compare
Contributor
Author
brew tap agentops-ai/agentstack https://github.com/agentops-ai/agentstack
brew install agentops-ai/agentstack/agentstack$ agentstack
usage: agentstack [-h] [-v] {docs,quickstart,init,i,generate,g,tools,t} ...
AgentStack CLI - The easiest way to build an agent application
positional arguments:
{docs,quickstart,init,i,generate,g,tools,t}
Available commands
docs Open Agentstack docs
quickstart Open the quickstart guide
init (i) Initialize a directory for the project
generate (g) Generate agents or tasks
tools (t) Manage tools
options:
-h, --help show this help message and exit
-v, --version Show the versionit works 🥳 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I had some issues with my local python env, so built a homebrew formula.
In general, homebrew allows installation of packages from GitHub with the following format
However, this requires that we have a repo named github.com/agentops-ai/homebrew-agentstack, with the contents of this PR.
If we want to keep it all in the same repo, users can run the following instead
In order for this to work, we need to ensure that every dep from the lockfile is codified in the formula, and that the url + shasum are kept up to date for each release.
In the formula, you'll see "url" and "shasum". Those will need updating per release. You'll also need to change the list of resources if anything changes with your deps.
This is pretty annoying, but luckily there's some tooling!
I used "poet" to generate a bunch of this, though it needed some manual tweaking - https://github.com/tdsmith/homebrew-pypi-poet
Also, note this line in the install function
There's currently an issue with the later versions of Xcode, while building the YAML package used here
Upstream ref: https://sourceforge.net/p/ruamel-yaml-clib/tickets/32/