Updating formula to build properly

This commit is contained in:
Will 2025-03-11 13:02:36 -04:00
parent f56b2d9c22
commit 61aa4e1743
1 changed files with 11 additions and 2 deletions

View File

@ -91,7 +91,7 @@ jobs:
python -m venv .venv python -m venv .venv
source .venv/bin/activate source .venv/bin/activate
pip install --upgrade pip pip install --upgrade pip
pip install ra-aid homebrew-pypi-poet pip install homebrew-pypi-poet ra-aid==${{ env.version }}
- name: Clone homebrew-ra-aid repository - name: Clone homebrew-ra-aid repository
run: | run: |
@ -100,15 +100,19 @@ jobs:
- name: Generate Brew Formula with poet - name: Generate Brew Formula with poet
run: | run: |
source .venv/bin/activate
cd homebrew-ra-aid cd homebrew-ra-aid
poet -f ra-aid > Formula/ra-aid.rb poet -f ra-aid > Formula/ra-aid.rb
- name: Update Formula/ra-aid.rb - name: Update Formula/ra-aid.rb
run: | run: |
cd homebrew-ra-aid cd homebrew-ra-aid
# --- Class documentaion
sed -i '' '1s/^/# Homebrew formula for RA.Aid\n/' Formula/ra-aid.rb
# --- Update description and homepage --- # --- Update description and homepage ---
sed -i '' 's/desc "Shiny new formula"/desc "RA.Aid (pronounced \\\"raid\\\") helps you develop software autonomously"/' Formula/ra-aid.rb sed -i '' 's/desc "Shiny new formula"/desc "RA.Aid (pronounced \\\"raid\\\") helps you develop software autonomously"/' Formula/ra-aid.rb
sed -i '' 's/homepage "None"/homepage "https:\/\/github.com\/ai-christianson\/RA.Aid"/' Formula/ra-aid.rb sed -i '' 's/homepage "None"/homepage "https:\/\/github.com\/ai-christianson\/RA.Aid"\
version "${{ env.version }}"/' Formula/ra-aid.rb
# Insert the license line after the homepage line using awk # Insert the license line after the homepage line using awk
awk '/homepage "https:\/\/github.com\/ai-christianson\/RA.Aid"/ {print; print " license \"Apache-2.0\""; next} 1' Formula/ra-aid.rb > tmp && mv tmp Formula/ra-aid.rb awk '/homepage "https:\/\/github.com\/ai-christianson\/RA.Aid"/ {print; print " license \"Apache-2.0\""; next} 1' Formula/ra-aid.rb > tmp && mv tmp Formula/ra-aid.rb
@ -304,6 +308,11 @@ jobs:
end end
EOF EOF
- name: Show updated Formula
run: |
cd homebrew-ra-aid
cat Formula/ra-aid.rb
# - name: Commit and push changes # - name: Commit and push changes
# run: | # run: |
# cd homebrew-ra-aid # cd homebrew-ra-aid