Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Feature Request: Put everything in checkout folder then filter to "Build" folder #2319

Open
jacobjiangwei opened this issue Jan 11, 2018 · 22 comments

Comments

@jacobjiangwei
Copy link

jacobjiangwei commented Jan 11, 2018

As @mdiep mentioned in this ticket:

#2304

The user story background:

Develop want to integration whatever type of library or code
*.a , *.framework, *.h, *.m, *.swfit, even Android *.so library, doesn't matter, right?

The download module just checkout everything into "Checkout" folder, do NOT filter out anything. Carthage has cache feature, right?

Then carthage can try to compile for iOS/tvOS/MacOS/even further Android and put everything in "Build" folder.

What we are trying to archive?
Some times it's just private library, all we need is checkout the zip file and unzip. That's it.
Trying to compile for developers is over-thinking, sometimes it doesn't work that way.

@mdiep I kind of want to help you to develop this feature, If you can point out where to start, I can certainly finish this feature. Do you want me to dev this in swift?

@jacobjiangwei jacobjiangwei changed the title Feature Request: Put everything in checkout folder than filter to "Build" folder Feature Request: Put everything in checkout folder then filter to "Build" folder Jan 11, 2018
@mdiep
Copy link
Member

mdiep commented Jan 11, 2018

This would only apply to binary-only frameworks, right?

Right now it's downloaded to a temporary directory; we just need to change that to be the correct checkout folder.

Yes to Swift! Carthage is Swift-only.

@jacobjiangwei
Copy link
Author

@mdiep I'm more welcome to any kind of library, especially someone just use this tool as a version management download tool.

We can always think about how to build something on top of these checkout stuffs. Right?

@mdiep
Copy link
Member

mdiep commented Jan 19, 2018

I just mean that it should only apply to binary "…" dependencies inside Cartfiles.

Then you'd be free to use whatever you wanted from the checkout folder, yes.

@jacobjiangwei
Copy link
Author

jacobjiangwei commented Jan 20, 2018 via email

@stale
Copy link

stale bot commented Jun 30, 2018

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jun 30, 2018
@stale stale bot closed this as completed Jul 7, 2018
@KoCMoHaBTa
Copy link
Contributor

@mdiep Any updates on this feature request?

@mdiep mdiep reopened this Jul 22, 2018
@stale stale bot removed the stale label Jul 22, 2018
@mdiep
Copy link
Member

mdiep commented Jul 22, 2018

I don't think anything has been done. PRs welcome. 🙂

@KoCMoHaBTa
Copy link
Contributor

@mdiep Just to clarify, from development perspective, the idea
Is to change where binary depencies are downloaded - from a temporary directory to the checkout directory.

@tmspzz
Copy link
Member

tmspzz commented Jul 22, 2018

FYI

*.a , *.framework, *.h, *.m, *.swfit, even Android *.so library, doesn't matter, right?

This statement does not hold true for Carthage. There are plenty of checks to make sure that what is being downloaded & copied to the build folder is a dynamic or static framework.

@KoCMoHaBTa
Copy link
Contributor

KoCMoHaBTa commented Jul 22, 2018

The topis is not about the build folder, but before that.
Like github depencies - the are first checked out to the Checkout folder and then builded to the build folder.
For binary dependencies - they are currently downloaded to an unknown temporary directory and then, if valid as you said - copied to the Build folder.

From what I understand - this enhancement is about to make the downloaded depencies abailable inside the Checkout folder upon download, and then if they are valid - put them inside the Build folder.

So I don’t see how that does not hold true for Carthage.

@KoCMoHaBTa
Copy link
Contributor

If I understand this correctly, the suggested and accepted idea is to change the download folder, form a temporary directory, to a folder inside the Carthage working directory

@tmspzz
Copy link
Member

tmspzz commented Jul 22, 2018

Binary dependencies downloads are unchecked but as you correctly said, checks happen before copy.

@KoCMoHaBTa
Copy link
Contributor

Exactly. I'm talking about the binary dependencies downloads only. The copy to the build folder should continue working as expected.

As @mdiep said:

Right now it's downloaded to a temporary directory; we just need to change that to be the correct checkout folder.

@KoCMoHaBTa
Copy link
Contributor

@blender @mdiep @ikesyo I'm trying to understand how to get access to the downloaded binary dependencies which are missing from the Carthage working directory.
I've looked around and ended up on this issue and got the impression that this was a feature request that was not implemented, so i tried to jump in and make sure we are on the same page.
Then, while waiting for response, i submitted an issue (#2525), which was shortly marked as duplicate of #2449 which is referenced to #2478
Looking trough them i can't understand what is the current situation on the topic.

Is there a solution or is it rejected or is it still on hold due to something or is it currently in development?
Can anybody share more information on it?
If there is already an existing solution for this or an alternative, please let me know.
As i mention in #2525 - i'm using carthage update --no-build.

@mdiep
Copy link
Member

mdiep commented Jul 23, 2018

Then, while waiting for response, i submitted an issue (#2525), which was shortly marked as duplicate of #2449 which is referenced to #2478

#2449 is about how carthage update --no-build doesn't download binary dependencies.

This issue is requesting that the archives from binary dependencies be extracted to Carthage/Checkout/ before the frameworks are copied to Carthage/Build. I believe this feature request is still a valid request and something we could support if someone wants to submit a PR.

It sounds like you're interested in #2449, which is separate from this issue.

@KoCMoHaBTa
Copy link
Contributor

I tought that this issue and #2449 are the same, because my expectations are that upon carthage update —no-build - binary depencies would be available at Carthage/Checkout folder.

So I’m really interested in

This issue is requesting that the archives from binary dependencies be extracted to Carthage/Checkout/ before the frameworks are copied to Carthage/Build. I believe this feature request is still a valid request and something we could support if someone wants to submit a PR.

Any considerations or requirements i should consider before diving into the code?

@ikesyo
Copy link
Member

ikesyo commented Jul 23, 2018

I tought that this issue and #2449 are the same

No they aren't. 1: Moving contents in a zip file to Carthage/Checkouts, and 2: the issue that binary depndencies (zip files) are not downloaded completely with --no-build option, are totally different (as @mdiep explained above). This is a feature request but #2449 is a bug. Even if #2449 is fixed this issue will not be resolved so should be tackled separately.

@KoCMoHaBTa
Copy link
Contributor

Thanks for the clarification, i got the difference now.

@KoCMoHaBTa
Copy link
Contributor

KoCMoHaBTa commented Jul 23, 2018

I've noticed that binary dependencies are not downloaded when using the checkout or carthage bootstrap --no-build command. Because of this, existing binary dependencies defined in the Cartfile.resolved cannot be resolved.
Should this be approached, discussed and resolved separately or we can consider it as part of this feature request?

@mdiep
Copy link
Member

mdiep commented Jul 23, 2018

I've noticed that binary dependencies are not downloaded when using the checkout or carthage bootstrap --no-build command. Because of this, existing binary dependencies defined in the Cartfile.resolved cannot be resolved.
Should this be approached, discussed and resolved separately or we can consider it as part of this feature request?

That is #2449.

@KoCMoHaBTa
Copy link
Contributor

@mdiep @blender Ready for review :)

@rdingman
Copy link

Any chance the related PR (#2532) could be resurrected? I'd find this particularly useful for FirebaseCrashlytics which distributes some binaries (non-framework) for uploading dSYMs to their service. Check out any of the zip files referenced in:

https://dl.google.com/dl/firebase/ios/carthage/FirebaseCrashlyticsBinary.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants