Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add option to disable the "Organization/FrameworkName" convention #180

Open
jamezilla opened this issue Apr 4, 2019 · 2 comments
Open

Comments

@jamezilla
Copy link

Enhancement Suggestion

The "Organization/FrameworkName" convention for automatically detecting frameworks causes subtle problems with Carthage workflows.

Steps which explain the enhancement or reproduce the bug

  1. Add a custom framework to your project which doesn't follow the "Organization/FrameworkName" convention
  2. Build and upload to the rome cache
  3. Clear the Carthage/Build folder
  4. Run rome download

Current behavior

rome doesn't find the framework name, but uploads a .<repo-name>.version-x.x.x file to the cache. When the Carthage/Build folder is cleared (or fresh, in the case of CI) and rome download is invoked, the version file is synced to the Build folder.

If you use a tool like carthage-verify it will say your Build folder is complete, but really you only have the version file and none of the frameworks.

Suggested behavior

Add an optional configuration to disable the "Organization/FrameworkName" convention. Only frameworks explicitly defined in the repositoryMap would be synced.

Why would the enhancement be useful to most users

It would keep CI builds from failing due to a mis-configured Romefile. IMHO, It's better to have no cache, than failing builds. Obviously, writing a correct Romefile is important, it can just be hard to enforce across distributed teams in a large organization.

Rome version:

0.20.0.56

OS and version:

macOS 10.14.3

@tmspzz
Copy link
Owner

tmspzz commented Apr 4, 2019

This sounds to me like a problem between the chair and the keyboard.

I would rather add a rome verify command .

It doesn't look like carthage-verify has enough information to actually verify the integrity of the build folder.

@jamezilla
Copy link
Author

This sounds to me like a problem between the chair and the keyboard.

Very much so. I'm just trying to code around the problems I can solve.

+1 for rome verify. Any thoughts about how to approach this? I spent a bit of time yesterday prototyping something similar, but it's messy. The two approaches I came up with were:

  1. crawl the Carthage/Checkouts folder and find all the targets
  2. parse the project files to introspect the framework build phases and try to union that with input files and input file lists from carthage copy-frameworks

The first option requires a carthage checkout pre-step.
The second option doesn't seem generalized enough.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants