yonaskolb / yonaskolb/XcodeGen

Homebrew install failure @ specific version

Open
#1,141 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Swift
Stars
8.8k
Forks
908
Avg merge
17d 14h
Merged PRs (30d)
2

Description

Hello! We are looking to pin Xcodegen installed via Homebrew to a specific version by extracting it into our own internal tap (more info here: https://docs.brew.sh/Taps).

When attempting to install the versioned formula brew install <internal-tap-path>/argoncli@2.25.0 we receive the following error:

Error: An exception occurred within a child process:
  Errno::ENOENT: No such file or directory - .build/release/xcodegen@2.25.0

This fails because the formula uses the name property on Formula to locate the path of built product which resolves to xcodegen@2.25.0 when using brew extract.

def install
    system "swift", "build", "--disable-sandbox", "-c", "release"
    bin.install ".build/release/#{name}"
    pkgshare.install "SettingPresets"
end

Is there a reason to use the name property instead of hardcoding xcodegen in the product path? Happy to help update the formula in homebrew-core, but thought I'd start the discussion here.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Formula install method shown in the issue and review how Homebrew's brew extract changes the formula name for versioned installs. Reproduce the failure with the extracted formula, then verify that installing the versioned formula places a working XcodeGen executable in the expected bin path.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
build-system, cli
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.