frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Start all of your commands with a comma

https://rhodesmill.org/brandon/2009/commands-with-comma/
163•theblazehen•2d ago•47 comments

OpenCiv3: Open-source, cross-platform reimagining of Civilization III

https://openciv3.org/
674•klaussilveira•14h ago•202 comments

The Waymo World Model

https://waymo.com/blog/2026/02/the-waymo-world-model-a-new-frontier-for-autonomous-driving-simula...
950•xnx•20h ago•552 comments

How we made geo joins 400× faster with H3 indexes

https://floedb.ai/blog/how-we-made-geo-joins-400-faster-with-h3-indexes
123•matheusalmeida•2d ago•33 comments

Jeffrey Snover: "Welcome to the Room"

https://www.jsnover.com/blog/2026/02/01/welcome-to-the-room/
22•kaonwarb•3d ago•19 comments

Unseen Footage of Atari Battlezone Arcade Cabinet Production

https://arcadeblogger.com/2026/02/02/unseen-footage-of-atari-battlezone-cabinet-production/
58•videotopia•4d ago•2 comments

Show HN: Look Ma, No Linux: Shell, App Installer, Vi, Cc on ESP32-S3 / BreezyBox

https://github.com/valdanylchuk/breezydemo
232•isitcontent•14h ago•25 comments

Monty: A minimal, secure Python interpreter written in Rust for use by AI

https://github.com/pydantic/monty
225•dmpetrov•15h ago•118 comments

Show HN: I spent 4 years building a UI design tool with only the features I use

https://vecti.com
332•vecti•16h ago•144 comments

Hackers (1995) Animated Experience

https://hackers-1995.vercel.app/
495•todsacerdoti•22h ago•243 comments

Sheldon Brown's Bicycle Technical Info

https://www.sheldonbrown.com/
383•ostacke•20h ago•95 comments

Microsoft open-sources LiteBox, a security-focused library OS

https://github.com/microsoft/litebox
360•aktau•21h ago•182 comments

Show HN: If you lose your memory, how to regain access to your computer?

https://eljojo.github.io/rememory/
289•eljojo•17h ago•175 comments

An Update on Heroku

https://www.heroku.com/blog/an-update-on-heroku/
413•lstoll•21h ago•279 comments

Vocal Guide – belt sing without killing yourself

https://jesperordrup.github.io/vocal-guide/
32•jesperordrup•4h ago•16 comments

Was Benoit Mandelbrot a hedgehog or a fox?

https://arxiv.org/abs/2602.01122
20•bikenaga•3d ago•8 comments

Where did all the starships go?

https://www.datawrapper.de/blog/science-fiction-decline
17•speckx•3d ago•7 comments

PC Floppy Copy Protection: Vault Prolok

https://martypc.blogspot.com/2024/09/pc-floppy-copy-protection-vault-prolok.html
63•kmm•5d ago•7 comments

Dark Alley Mathematics

https://blog.szczepan.org/blog/three-points/
91•quibono•4d ago•21 comments

How to effectively write quality code with AI

https://heidenstedt.org/posts/2026/how-to-effectively-write-quality-code-with-ai/
258•i5heu•17h ago•196 comments

Delimited Continuations vs. Lwt for Threads

https://mirageos.org/blog/delimcc-vs-lwt
32•romes•4d ago•3 comments

What Is Ruliology?

https://writings.stephenwolfram.com/2026/01/what-is-ruliology/
44•helloplanets•4d ago•42 comments

Introducing the Developer Knowledge API and MCP Server

https://developers.googleblog.com/introducing-the-developer-knowledge-api-and-mcp-server/
60•gfortaine•12h ago•26 comments

I now assume that all ads on Apple news are scams

https://kirkville.com/i-now-assume-that-all-ads-on-apple-news-are-scams/
1070•cdrnsf•1d ago•446 comments

Female Asian Elephant Calf Born at the Smithsonian National Zoo

https://www.si.edu/newsdesk/releases/female-asian-elephant-calf-born-smithsonians-national-zoo-an...
36•gmays•9h ago•12 comments

I spent 5 years in DevOps – Solutions engineering gave me what I was missing

https://infisical.com/blog/devops-to-solutions-engineering
150•vmatsiiako•19h ago•70 comments

Understanding Neural Network, Visually

https://visualrambling.space/neural-network/
288•surprisetalk•3d ago•43 comments

Why I Joined OpenAI

https://www.brendangregg.com/blog/2026-02-07/why-i-joined-openai.html
150•SerCe•10h ago•142 comments

Learning from context is harder than we thought

https://hy.tencent.com/research/100025?langVersion=en
186•limoce•3d ago•100 comments

Show HN: R3forth, a ColorForth-inspired language with a tiny VM

https://github.com/phreda4/r3
73•phreda4•14h ago•14 comments
Open in hackernews

CocoaPods trunk read-only plan

https://blog.cocoapods.org/CocoaPods-Specs-Repo/
248•matharmin•5mo ago

Comments

nazgu1•5mo ago
Such a big piece of history and a de facto standard for managing dependencies for Apple platforms for years.

Big "thank you" to all maintainers for your great job! And respect that you recognise moment when ecosystem changed and have courage to deprecate library instead of maintaining it forever - to leave place for migrating to new, superior solutions

cnnlives65•5mo ago
> superior solutions

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

nikanj•5mo ago
Open source superior just means newer, even if it comes with less features and more bugs
exe34•5mo ago
Superior means it does 5 new things that the 5 maintainers wanted, but nobody else uses.
orta•5mo ago
OP here, luckily in this case, it means a more supported and vertically integrated alternative. Which does have less features, but actually gets bugs fixed and keeps up to date with the platform - so it's a net win overall IMO
ddlsmurf•5mo ago
Thanks, your work was of huge value to me, way more than you were rewarded for, sorry :/
asveikau•5mo ago
This happens in proprietary software too.
sturza•5mo ago
End of an era.
deadbabe•5mo ago
Was it a good era?
frizlab•5mo ago
No.
gregoriol•5mo ago
Better than the "current" future
Cthulhu_•5mo ago
Probably not, but all modern-day package managers owe a debt to Cocoapods for the things it did right and the things that could have been better.
weego•5mo ago
No pods are an absolute misery and at best a concrete example of what not to do. So at least there's that.
Manfred•5mo ago
You have to understand where we came from. Development for iOS and macOS (then MacOS) meant you had to pluck source files from random places on the internet and weave them into your Xcode build. Xcode and xcodebuild didn't really shine in the department of extensibility.

Eloy designed CocoaPods to be the absolute minimum we needed to deal with dependencies for the projects we were working on. So that meant:

* Rely on GitHub for hosting so nobody would get bankrupted running the repo, with the option to switch over to self-hosted in case that ever became necessary. * Use Git and existing project tools on GitHub to deal with external contributions for pods. * Use Ruby for scripting because that was what people used most at that time. * Use Ruby for pod definitions for flexibility and reduced development time (ie. so CocoaPods didn't need a parser).

For a long time this was a one-person effort.

All of those decision obviously have downsides, even more obvious now you have to power of hindsight given years of incremental improvements on speed and security of dependency managers.

I think Eloy did a great job in general and the popularity gained speaks for itself.

mrbombastic•5mo ago
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 better for a lot of people.
eviks•5mo ago
> 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?

mrbombastic•5mo ago
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.
Copenjin•5mo ago
No.
swiftcoder•5mo ago
It may not have been great, but it was certainly better than the likely alternative (no package management at all for iOS development).
tomashubelbauer•5mo ago
As a very occasional iOS developer, I never enjoyed it. I preferred Carthage and jumped over SPM the moment it became available. I understand SPM didn't or even still doesn't meet the needs of many professional iOS developers, but for my hobby needs, it was the simplest and easiest to use.
jurip•5mo ago
I preferred Carthage in theory, but every time I tried using it in anger I hit enormous stumbling blocks with projects not actually living up to its exacting standards, then spent hours faffing about before going back to CocoaPods.

I'm happy to see the back of CocoaPods, but it kickstarted the library package ecosystem on the Apple platforms, where there was nothing like it before.

rvz•5mo ago
Absolutely No.
K0nserv•5mo ago
Yes! I'm a little biased as someone who worked briefly on CocoaPods, but it was an indispensable tool for many years. This is evident by its massive popularity.

Like with NPM, many people ran into issues ultimately rooted in not understanding the tool. CocoaPods had the extra constraint that correctly setting up a Ruby environment was hard. If you used Ruby with a fixed ruby version, bundler with a Gemfile.lock and then CocoaPods it worked well.

bingemaker•5mo ago
Thoroughly enjoyed while it lasted! Thank you maintainers.
aravindputrevu•5mo ago
Isnt this a old news? I'm thinking of Swift Package manager for all the stuff new.
gregoriol•5mo ago
From my experience, about 20-30% of the packages are not working with swiftpm, either because they don't have a Package.swift file, or because it is not compatible with up-to-date developer tools. On many projects, I had to fork a few repositories just to add or fix the swiftpm integration... while their Pod integration has always been working well.
rTX5CMRXIfFG•5mo ago
That is the cost of using third party libraries, hardly the fault of either SPM or Cocoapods.
manmal•5mo ago
I‘d say it’s 2% now, of the maintained ones? I haven’t seen such a project in a long while now. React Native is the only one I can think of.
gregoriol•5mo ago
This is really sad, because the replacement, Swift Package Manager, is really crap: it lacks some useful features (an "outdated" command, meaningful commandline output, ...), is buggy as hell in xcode (most of the time xcode just crashes when you add/removed a dependency, error messages while getting a repository are not understandable and even often not visible entirely, many repositories have some old Package.swift that current developer tools won't read, ...), and worst of all, it stores the full repositories of all the dependencies with their full history on your machine and downloads them every time when you do CI properly, which often means GBs of data.
wahnfrieden•5mo ago
Tuist
richrichardsson•5mo ago
In spite of search engines being a thing, this comment could have done with a bit more information. I assume you're talking about this: https://docs.tuist.dev/en/
wahnfrieden•5mo ago
Yes. There's no ambiguity, no other project uses the name
MobiusHorizons•5mo ago
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)
johnisgood•5mo ago
> I thought it was a typo or even possibly an insult (same form as racist, sexist, ableist, ageist, etc)

That is on you, though.

MobiusHorizons•5mo ago
I completely agree with you that if I had wanted to I could have put in the effort to decipher the meaning of the post. However, the post left me with absolutely no desire to decipher it's meaning, so I did not. If instead the author had written simply "I use tuist for that" the meaning would have been immediately clear for someone like me, and I would have been much more likely to look up the product.

I don't mean to imply that there is some sort of "should" to this. The author is not required to want their meaning to be understood, even though I'm not really sure what other purpose they would have for posting. But I do think that this class of miscommunication is both common and reasonably avoidable by building up a bit of a mental model of the intended audience. I was trying to provide anecdotal evidence to build up that mental model.

johnisgood•5mo ago
We are talking about a project's name. Why did racism (and friends) came up in your mind, or an insult? Why is this the default norm, now? People are free to down-vote me, but they cannot deny there is no truth to what I am saying. I would have never thought that a project's name was intended to be racist or cause any sort of harm. Why did you?
rafram•5mo ago
Because it was a single word ending in -ist, the common English suffix for a prejudice or preference? There was no context indicating that it was the name of a project.
johnisgood•5mo ago
And you resort to either it being an insult or something about ableist, racism, etc.? That was not something I thought of until I got reminded.
MobiusHorizons•5mo ago
> We are talking about a project's name. Why did racism (and friends) came up in your mind, or an insult?

Please don’t take what I said as any kind of allegation that you were being insulting. Those associations were from trying to parse the word as English, which resulted in some unknown word from the family of words relating to prejudice presumably relating to textual user interfaces vs graphical. Context would have made it clear that it was a project name, in which case the word doesn’t need to be parsed.

johnisgood•5mo ago
It was not me who said the word, FWIW.
adastra22•5mo ago
Another non-iOS developer here. It was absolutely not clear what you meant with a single word reply, and one that honestly looked like a typo or some kind of insult (short + -ist) I didn’t get.
johnisgood•5mo ago
What I meant is that people who are non-ableist, non-racist, etc. do not have racism et al. popped up in their mind.

Why does everything have to do with those things in people's minds? It is tiring, and I am starting to believe they are the racists.

It never crossed my mind based on the name of a project. It is ridiculous.

nxrabl•5mo ago
If you’re not familiar with the experience of browsing the internet and then suddenly having deeply-held parts of your identity deemed undeserving of respect, it’s the kind of thing that the mind naturally develops habits to avoid, in much the same way that you might start to walk differently through a city after getting mugged. It is indeed tiring for everyone, but the solution is not to blame people for doing what they feel like they need to do to protect themselves.
johnisgood•5mo ago
Of course I do, but we are talking about a project's name.
MobiusHorizons•5mo ago
That’s the whole point. If you know we are talking about a project name (for instance by using the word in a sentence) then it makes perfect sense, but with no context one is left to try to use etymology like one might do with any unknown word.
johnisgood•5mo ago
So you admit to it being an unknown word.

I did not, for a second, think, that an unknown word was intended to be racist, ableist, etc.

Why would you?

Also parent's reply:

> If you’re not familiar with the experience of browsing the internet and then suddenly having deeply-held parts of your identity deemed undeserving of respect [...] the solution is not to blame people for doing what they feel like they need to do to protect themselves.

It was a comment under a submission, FWIW.

Seriously though, just stop assuming everything is about race and friends. It is what is tiring. Ask first before making assumptions if it really is not a slur you know of, but an UNKNOWN WORD. If he were to say n***e* then yeah, have at it. That cannot be misunderstood.

And by my reply "That is on you" is down-voted for fuck-all, because people does not realize that the people preoccupied with racism are the ones first to believe it was a racist slur. I did not think it was a racist slur, because 1) it was an unknown word, 2) I am not preoccupied with such stuff, my mind is not filled with racism and such. Thus, the people who say "racist!" usually turn out to be the racists. I have seen it everywhere. Now I saw it on HN, too, which is just splendid. A single search would have sufficed. I do not deny that the person saying the word could have clarified what it is, but defaulting to believing it has to do with racism is one of the reasons for why we have racism. It did not cross my mind. Why did it cross yours, especially if you knew nothing but the unknown word?

I do not see race. Am I the racist one or the people thinking everything is about racism? Do not worry, I see race when it comes to a groups of people, except in that case it does not matter much, a group of people may always be trouble, regardless of race, so no, I did not abandon my self-preservation.

There is a lot to unpack here, my bad.

wahnfrieden•5mo ago
Glad we've cleared it up
myko•5mo ago
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.
wahnfrieden•5mo ago
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

myko•5mo ago
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.

SoKamil•5mo ago
Have you worked with Bazel before? Do you have a comparison to Tuist?
myko•5mo ago
I haven't earnestly used Bazel but my limited experience with it is that it does work fairly well and if your project is multiplatform it might be a better choice than Tuist for the Apple specific pieces. But if your project is all Apple and you're deeply into the ecosystem Tuist would be my recommendation - instead of Bazel's DSL you just write Swift to describe your project.
rTX5CMRXIfFG•5mo ago
I don’t know, I’ve never had those problems and my codebases reach 600k+ LOC. I’ve certainly had plenty of errors to deal with Cocoapods and obsolete frameworks though, though those projects also tend to use pretty much every third-party lib that gets attention on Medium.

Modularizing an Xcode project with local Swift packages has been the best productivity gain in my experience. Doing something similar with Cocoapods is a headache.

gregoriol•5mo ago
Local Swift packages are indeed improving the experience a little bit: better version management, less xcode crashes, slightly more explicit errors, but still highly troublesome. It really feels like Apple's teams are not using any of SwiftPM themselves.
ninkendo•5mo ago
> It really feels like Apple's teams are not using any of SwiftPM themselves.

They probably never will, at least not for anything that ships with the OS. For Apple, binary size is very important, and it’s essential that they have only one of every library (“project”) installed on the device, and that they use dynamic linking everywhere.

SwiftPM uses static linking to the core, and if Apple were to use it, binary sizes would balloon (not to mention there would be potentially mutually incompatible versions of things.) You could fix this by ignoring version specs in the package file and building just one of every project/framework, and changing it to use dynamic linking everywhere… but at some point you’re just contorting swiftpm to become a big mono-build system, which only Apple would really be using as such.

meisel•5mo ago
Yeah, I’ve hit many pain points over the years with SwiftPM. Its restrictions on compiler flags is also problematic.
cosmic_cheese•5mo ago
SwiftPM been little trouble for me, with the most complex project involving a number of external packages and a couple of local ones. No crashes or anything like that.

It’s been way, way less trouble than CocoaPods was before I switched several years ago. CocoaPods was so bad about screwing itself up that I’d just check in its dependencies in a building state and avoid upgrading anything unless I absolutely had to, because inevitably when doing updates or even just resolving my project would somehow hit some number of the many edge cases that’d cause it to blow up.

In contrast with SwiftPM I keep most dependencies pretty close to current because it’s painless to do so.

In fact it’s been good enough to me that I wish it were possible to replace the awful mess that is Gradle with SwiftPM (or a 1:1 JVM counterpart) on the Android side. I need approximately none of Gradle’s flexibility and bells and whistles that make it such a pain in the rear, so something with SwiftPM’s simplicity would be a serious QoL improvement.

secretsatan•5mo ago
Yeah, no, cocoapods was a nightmare compared to SPM, every ios update supplied a new unsolved issue in one pod or another that required dark incantations.

Managing a local pods caused issues so great engineers quit

gwbennett•5mo ago
100% agree!
atommclain•5mo ago
My biggest criticism with SPM is that there doesn't seem to be a way to use it with git worktree since the package cache is centralized as opposed to being at the directory/project/workspace level.
wahnfrieden•5mo ago
Can you elaborate on the use case? I've started putting my local package dependencies into Vendor/ submodules in the repo I'm using them. I can't use worktrees with this setup?
kiliankoe•5mo ago
If you're looking for an outdated command, maybe this works for you? https://github.com/kiliankoe/swift-outdated/

Disclaimer: I wrote this (a while back)

gregoriol•5mo ago
I'm using it, thanks so much for making it :-) It should have been part of the swift base tools, it is very useful.
kiliankoe•5mo ago
Oh fantastic! And yes, I very much agree. I have some ideas for improving it a bit, maybe that'll make it worthwhile to PR into SwiftPM itself (:
tomaskafka•5mo ago
Sounds like Microsoft’s “Embrace Extend Extinguish” approach that everyone hated (and some successfuly sued) has found a new home at Apple.

1 take over the thing 2 succeed at it as a platform owner 3 not put in resources to do it well

AJRF•5mo ago
Doesn't React Native depend on this very heavily for iOS?
mrbombastic•5mo ago
It does, in recent react native versions they show a deprecation warning when running “pod install” directly which is probably a signal they are working on moving to other package managers, but not aware of what the plan is.
oefrha•5mo ago
Yeah, and according to https://expo.dev/blog/precompiled-react-native-for-ios and linked https://github.com/react-native-community/discussions-and-pr..., it seems moving off CocoaPods has barely moved past planning stage. Latest update from two weeks ago links to https://github.com/facebook/react-native/pull/52909 and says it’s very very experimental. Just great…
AJRF•5mo ago
Gosh, that is a worry. Maybe I can help out here (I imagine the politics of a project this large will frustrate me though)
adithyassekhar•5mo ago
Why would you work for free for Facebook
mrbombastic•5mo ago
rn is open source so I don’t personally see it as working for free for facebook but rather working for free for the dev community
adithyassekhar•5mo ago
There is no dev community. Is there a developers organization (unions if you must) which fights for minimum pay or work standards?

No there's not in fact it's actively frowned upon because if salaries are standardized no one will get to enjoy those huge faang pays. It'll be averages. That is not the capitalist way.

You're doing the work highly paid facebook and vercel employees are getting paid for.

robertjpayne•5mo ago
It's not actually that concerning. RN's pods are vended via npm not trunk so trunk going read-only will not have an outsized impact on RN.

The risk is that over time Cocoapods will no longer work to integrate dependencies with ways Xcode wants them to be.

Switching to SPM is a massive undertaking for a large project with many intertwined dependencies and configuration options. It's far less configurable than Cocoapods with basically no scripting options during install.

Their progress already is pretty decent!

oefrha•5mo ago
I think the most concerning part is all the third party libraries already on life support or already abandoned a few years ago will all die during the switch.
oulipo2•5mo ago
Capacitor too, for hybrid mobile apps
cthulberg•5mo ago
Flutter too: https://docs.flutter.dev/get-started/install/macos/mobile-io...
arnath•5mo ago
Flutter has moved to Swift Package Manager, it’s just not enabled by default iirc
tananaev•5mo ago
From the official docs it sounds more like experimental support that's still under development.
chairhairair•5mo ago
Already has complete support for SPM.
everyone•5mo ago
Unity also afaik.
seanalltogether•5mo ago
Apple has always made it painful to step too far off the path with their tooling and frameworks and cocoapods was not immune to that pain. I'm grateful of what they made and the pressure they put on Apple to make things better, but I was very happy to remove yet another 3rd party dependency from our toolchain the moment we were able to.
Terretta•5mo ago
> Apple has always made it painful to step too far off the path

Or, "Apple has always avoided spending dev cycles too far off the path, electing instead to make the path itself easier."

xCode with built-in live rebuild preview simulator plus xCode Cloud with Testflight which auto-builds on git push is a remarkable value for $8.33 a month.

jamil7•5mo ago
> xCode with built-in live rebuild preview simulator

You couldn't have picked a slower, more buggy, opaque feature to highlight here. Its useful for UI work when it works properly but I feel like I have to mentally prepare myself everytime I switch the canvas on to avoid throwing the computer out the window.

I'll agree on Xcode Cloud though, integrated CI, signing and TestFlight builds with minimal hassle is very nice.

karel-3d•5mo ago
The reasoning is here, from 2024

https://blog.cocoapods.org/CocoaPods-Support-Plans/

The timeline in the original article seems very reasonable to me. They go out of their way to avoid breakages.

tonyhart7•5mo ago
good news, react native and flutter piggyback on external deps need to stop
myko•5mo ago
https://docs.flutter.dev/packages-and-plugins/swift-package-...

https://docs.flutter.dev/packages-and-plugins/swift-package-...

no idea if google will nix flutter tomorrow or not but it is extremely well run and seems to stay ahead of things pretty well, even though i'd rather write Swift than Dart (or Kotlin, for that matter)

forgingahead•5mo ago
Sad, truly an end of an era. Big thanks to all maintainers!
ChrisMarshallNY•5mo ago
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.

josteink•5mo ago
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 :)

ChrisMarshallNY•5mo ago
I'm not sure. I suspect so, but I haven't used ObjC since 2014.
kenshi•5mo ago
Yes, you can use SPM to package up Objective-C code.
armadsen•5mo ago
Right, but you can’t have a single package containing both ObjC and Swift. It’s a limitation of SwiftPM that has prevented me from using it for a few projects (I am using it in several others, though).
einsteinx2•5mo ago
You can mix them, it just has to be released as a binary framework which is a bit annoying as I would prefer a pure source release but it does work.
josteink•5mo ago
Since it clearly wasn’t obvious, I was asking in the context of a package consumer, not publisher.

My involvement with MacOS development is somewhat limited and I have no plans publishing any packages yet ;)

einsteinx2•5mo ago
Oh gotcha, yeah they’re absolutely usable as any maintainer mixing the languages and providing SPM support will handle the binary release part. If anything it’s nicer for the consumer (binary releases in general) as it cuts down on full app rebuild times.
josteink•5mo ago
I kept hitting my head against the wall, and getting a million stupid errors trying to resolve header files. But in the end I got it working, and I will no longer be one of the guys pestering the old Cocoapods servers :)

For whoever comes after me... When ChatGPT suggests changing your Objective-C from this:

   #import package.h
To this:

   #import <package/package.h>
Just skip that rabbithole of inifiny-nested failure, and just do this instead:

   @import package;
And you're done. You can thank me later :)
andrewjl•5mo ago
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/

basisword•5mo ago
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)?

gorbypark•5mo ago
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!
cyberax•5mo ago
React-Native is blocked by SwiftPM not supporting mixed ObjC and Swift packages. It needs that to support both the Old Architecture and the New Architecture at the same time.
stevage•5mo ago
>I don't think I'm amenable to moving it forwards, but within reason there's space for backwards.

Side note: not everyone interprets "forwards" and "backwards" in the same way for statements like these. Saying "sooner" or "later" is clearer.

einsteinx2•5mo ago
Finally!! I never liked CocoaPods due to how it “takes over” your Xcode project. I used to prefer Carthage, then just git submodules, then SPM. In my last job I oversaw SDK development and CocoaPods was the bain of my existence. Constant CDN problems causing release delays, annoying extra file in Ruby to maintain, different behavior than our other releases due to how CocoaPods builds projects, etc. SPM was as simple as pushing a git tag and maintaining a simple Swift file, while pushing to CocoaPods was rolling the dice how many times I’d get an error message. Good riddance!
ardit33•5mo ago
lol... you really don't like it, do you. I used it for a couple of my projects, and I kinda agree with you. I didn't like it at all how it took over projects (you have to use a workspace).

For my small personal projects, eventually I ended up into reverting to just downloading the dependencies myself into a lib folder. A bit more work upfront, but simpler builds and you know what's going into your project.

I think it had its use and time, and it is good for the maintainers to mark it deprecated and time to move on.

einsteinx2•5mo ago
Haha I really don’t, but I do get why others liked it, it was just never for me. I also forgot the intermediate step I took between git submodules and SPM where I did exactly what you did with manually adding deps to the project. Git submodules is it’s own frustrating hell lol…

More recently though the lack of maintenance of the CDN causing lots of problems not only publishing but even just pod installs failing was really frustrating, and as an SDK/framework maintainer just having to support multiple package managers was a huge pain in the ass. Especially with React Native requiring CocoaPods and having its own weird problems we have to solve in the pod file.

But yeah glad to see it being sunset now that there’s an officially sanctioned package manager. I know some people will complain that SPM isn’t as full featured as CocoaPods but I’ve found it gets the job done and the fact it’s both run off a simple Swift file and git tags and has official support from Apple is great. Kind of reminds me of Carthage for the modern age, in a good way.

secretsatan•5mo ago
It was a product of it’s time, it highlighted an issue that apple never really addressed, i have much more confidence in the future of SPM because at least it seems to be moving in tandem with Swift
jbverschoor•5mo ago
Finally someone sane.
monocularvision•5mo ago
I agree entirely. I feel like CocoaPods should have done this shortly after iOS 8 was released when dynamic frameworks were added. It was a terrible solution to a problem that way outlived its usefulness and because of that has absolutely polluted the ecosystem.
pbd•5mo ago
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.
matharmin•5mo ago
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.
andrekandre•5mo ago

  > The interesting question is what happens to the ~100k+ pods that never migrated to SPM.
from experience in a few projects that migrated to spm: fork and port to spm (at the same time, mark them as deprecated and slowly wean off them)

  > abandoned code that smaller projects still depend on
there are alot of large commercial projects too that are in the same boat...
jhatemyjob•5mo ago
And this, kids, is why you should always vendorize your dependencies
matharmin•5mo ago
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.
jhatemyjob•5mo ago
Good idea let's punt it to 20 years from now when the CocoaPods server goes down. By then the startup will have been acquired and we will be long gone, so it's the parent company's problem not ours.