Live data from Hacker News

CocoaPods trunk read-only plan

blog.cocoapods.org

71–80 of 116 posts

Re: CocoaPods trunk read-only plan

#71
post #33

Earlier quoted context omitted.

Flutter too: https://docs.flutter.dev/get-started/install/macos/mobile-io...

Flutter has moved to Swift Package Manager, it’s just not enabled by default iirc

From the official docs it sounds more like experimental support that's still under development.

Re: CocoaPods trunk read-only plan

#72
post #34

Earlier quoted context omitted.

I will never start another Apple platform application without Tuist. If I start work on one I will do my best to get buy-in to switch.

It is also the only good way to use LLMs to manage projects/workspaces You can use it for non-Apple platforms btw. Swift on Linux, Android, Windows, WASM. Projects like https://swiftcrossui.dev (with major contribution from Miguel de Icaza recently) and https://skip.tools for instance make this all the more productive

Neat, I may check that out.

For my Swift backends running on Linux I have just been using SPM and when working on macOS open the manifest directly. I haven't really done anything with a non-web UI with Swift outside of blessed platforms.

Re: CocoaPods trunk read-only plan

#73
post #70

Earlier quoted context omitted.

I am going to start sounding like a dinosaur but I really hate this dev tendency to trash the old way as soon as the new way comes out. I am seeing it with all the devs advocating for mise over asdf, and a year ago they were all singing asdf’s praises. I think we can advocate for better while still thanking those we are building upon. Long winded way of saying: thanks to the cocoapods maintainers, you made iOS dev be…

> and a year ago they were all singing asdf’s praises. This can't be true, many people recognized all the deficiencies contemporaneously and even complained about them publicly?

Not sure what you mean exactly, but what I assume happens is someone finds the new thing and the old things deficiencies become more apparent because they are both called out by creators of the new thing and probably a major reason the new thing exists. The devs that found new thing start advocating for it while bashing the old thing. Like I said I think it is fine and healthy to advocate for and want to improve tooling, it just bugs me when it is done while bashing what was likely a fairly thankless labor of love.

Re: CocoaPods trunk read-only plan

#74

Earlier quoted context omitted.

Yes. There's no ambiguity, no other project uses the name

It was not at all obvious to people that haven’t heard of tuist (presumably the intended audience of your post) that tuist is a product. I thought it was a typo or even possibly an insult (same form as racist, sexist, ableist, ageist, etc)

> I thought it was a typo or even possibly an insult (same form as racist, sexist, ableist, ageist, etc)

That is on you, though.

Re: CocoaPods trunk read-only plan

#75
post #51

Earlier quoted context omitted.

> superior solutions Superior includes actual state of being better. Differences could just be differences. Maybe it’s just homoplastic.

Open source superior just means newer, even if it comes with less features and more bugs

This happens in proprietary software too.

Re: CocoaPods trunk read-only plan

#77

It was useful, but way too delicate. I didn't like the way that it rewrote my project structure. Once Swift Package Manager matured, I stopped using CocoaPods.

As someone with no direct love of CocoaPods... Is there a way to use SPM for mixed ObjC and Swift projects? I'd love to know if I have options :)

As long as the Obj-C and Swift are in separate source or binary targets, SPM supports them being in the same package.

There was a Swift Evolution proposal at one point to go all the way and bring in support for mixed Obj-C and Swift targets [1] but it was returned for revision. It talks about the multiple target workarounds:

> Distribute binary frameworks via binary targets. Drawbacks include that the package will be less portable as it can only support platforms that the binaries support, binary dependencies are only available on Apple platforms, customers cannot view or easily debug the source in their project workspace, and tooling is required to generate the binaries for release.

> Separate a target’s implementation into sub-targets based on language type, adding dependencies where necessary. For example, a target Foo may have Swift-only sources that can call into an underlying target FooObjc that contains Clang-only sources. Drawbacks include needing to depend on the public API surfaces between the targets, increasing the complexity of the package’s manifest and organization for both maintainers and clients, and preventing package developers from incrementally migrating internal implementation from one language to another (e.g. Objective-C to Swift) since there is still a separation across targets based on language.

The upshot is that SPM has a better interoperability story with Swift and C++ [2] and maybe that can serve as a foundation for getting to the same level of interop for Obj-C.

[1]: https://github.com/swiftlang/swift-evolution/blob/main/propo...

[2]: https://www.swift.org/documentation/cxx-interop/

Re: CocoaPods trunk read-only plan

#78

The end of an era! Goodbye xcworkspace. For most of my use cases SPM is now much easier to use and causes less issues but a great effort from all the Cocoapods maintainers over the years. I wonder how interoperable SPM is though with non-Xcode build pipelines (e.g. Unity projects, ReactNative, Flutter, etc)?

React native support for SPM is non-existent for the most part. There's some work on porting to SPM but it's gonna be a while before anything becomes stable. It's going to break a huge amount of 3rd party packages. A bit of shame this wasn't done earlier as the RN ecosystem just went (or, is still going) through a migration to the "new architecture" that required most 3rd party packages that use native code to be "ported" over. Could have been a two-for-one kinda thing!

Re: CocoaPods trunk read-only plan

#79
post #64

The interesting question is what happens to the ~100k+ pods that never migrated to SPM. There's probably a lot of useful but abandoned code that smaller projects still depend on. This creates a bifurcation where legacy projects get stuck on older toolchains.

You'll still be able to use those - the CocoaPods repo will not go away any time soon. If someone wants to provide updates for those, it has to be migrated to SwiftPM. And in the meantime you may have to use both SwiftPM and CocoaPods, or fork & migrate those yourself.

Re: CocoaPods trunk read-only plan

#80

And this, kids, is why you should always vendorize your dependencies

There may be good reasons to do that, but this isn't one. Any project using CocoaPods will still remain working for the foreseeable future - you'll just not get new updates to dependencies at some point. And at that point you can migrate to SwiftPM or vendored dependencies, without losing anything.
Post reply on HN