httpcat-cli 0.2.3-rc.3 → 0.2.3-rc.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -544,10 +544,29 @@ jobs:
544
544
  contents: write # Required to push to homebrew tap repository
545
545
  steps:
546
546
  - name: Checkout homebrew tap
547
+ env:
548
+ GIT_TOKEN: ${{ secrets.HOMEBREW_TAP_TOKEN }}
547
549
  run: |
548
- git clone https://${{ secrets.HOMEBREW_TAP_TOKEN }}@github.com/hathbanger/homebrew-httpcat.git homebrew-tap
550
+ # Clone the homebrew tap repository
551
+ if [ -z "$GIT_TOKEN" ]; then
552
+ echo "❌ HOMEBREW_TAP_TOKEN secret is not set!"
553
+ exit 1
554
+ fi
555
+
556
+ echo "Cloning homebrew tap repository..."
557
+ git clone https://${GIT_TOKEN}@github.com/hathbanger/homebrew-httpcat.git homebrew-tap
558
+
549
559
  cd homebrew-tap
550
560
  git checkout main
561
+
562
+ # Verify the clone was successful
563
+ if [ ! -f "Formula/httpcat.rb" ]; then
564
+ echo "❌ Formula file not found after clone!"
565
+ ls -la
566
+ exit 1
567
+ fi
568
+
569
+ echo "✅ Successfully checked out homebrew tap"
551
570
 
552
571
  - name: Wait for npm CDN propagation
553
572
  run: |
@@ -598,13 +617,45 @@ jobs:
598
617
  env:
599
618
  GIT_TOKEN: ${{ secrets.HOMEBREW_TAP_TOKEN }}
600
619
  run: |
620
+ # Verify directory exists
621
+ if [ ! -d "homebrew-tap" ]; then
622
+ echo "❌ homebrew-tap directory not found!"
623
+ exit 1
624
+ fi
625
+
601
626
  cd homebrew-tap
627
+
628
+ # Verify we're in the right directory
629
+ if [ ! -f "Formula/httpcat.rb" ]; then
630
+ echo "❌ Formula/httpcat.rb not found in current directory!"
631
+ pwd
632
+ ls -la
633
+ exit 1
634
+ fi
635
+
602
636
  git config user.name "github-actions[bot]"
603
637
  git config user.email "github-actions[bot]@users.noreply.github.com"
638
+
639
+ # Configure git to use token and avoid password prompts
640
+ git config credential.helper store
641
+ echo "https://${GIT_TOKEN}@github.com" > ~/.git-credentials
642
+
643
+ # Update remote URL to use token
644
+ git remote set-url origin https://${GIT_TOKEN}@github.com/hathbanger/homebrew-httpcat.git
645
+
646
+ # Check if there are changes to commit
604
647
  git add Formula/httpcat.rb
605
- git commit -m "Update httpcat to ${{ needs.prepare.outputs.version }}" || exit 0
606
- # Push using token in URL (simplest approach)
607
- git push https://${GIT_TOKEN}@github.com/hathbanger/homebrew-httpcat.git HEAD:main
648
+ if git diff --staged --quiet; then
649
+ echo "✅ No changes to commit (formula already up to date)"
650
+ else
651
+ git commit -m "Update httpcat to ${{ needs.prepare.outputs.version }}"
652
+ echo "✅ Committed changes"
653
+ fi
654
+
655
+ # Push to main branch
656
+ echo "Pushing to homebrew repository..."
657
+ git push origin main
658
+ echo "✅ Successfully pushed to homebrew repository"
608
659
 
609
660
  # Job 5: Create GitHub Release
610
661
  create-release:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "httpcat-cli",
3
- "version": "0.2.3-rc.3",
3
+ "version": "0.2.3-rc.4",
4
4
  "description": "CLI tool for interacting with httpcat agent - create, buy, and sell tokens with x402 payments",
5
5
  "main": "dist/index.js",
6
6
  "bin": {