Swiftly Tooling with Pol Piella Abadia

Swiftly Tooling with Pol Piella Abadia

Leo Dion (host): Welcome to
another episode of Empower Apps.

I'm your host Leo Dion.

Today I'm joined by Pol Piella Abadia.

Pol, thank you so much for coming on.

Pol Piella Abadia (guest): Yeah.

Thank you for having me.

Yeah.

Been

time listener of the podcast.

I'm happy to be here.

Leo Dion (host): well, I'm
happy to have you big fan of

your blog and your newsletter.

And we started using your app,
which we'll talk about QReate.

So I am super excited to have you on.

We met in Italy in person.

And so, yeah, before we get
started, I'll let you go

ahead and introduce yourself.

Pol Piella Abadia (guest): Yeah.

So, Pol I'm yeah, I'm an IS engineer.

I've been for the past about six years.

I've been living in the UK,
I'm originally from Spain,

but I've been living in the
UK for the last nine years.

So I work at the BBC at the moment,
that's all about to change so I'm

gonna move countries in about a month.

So I'm going back to Spain going
back home, and I'm starting, like,

a new chapter, a new adventure
and everything next month.

So that's why...

My background is very
empty at the moment.

I've got boxes all over the place.

So just tidying up my whole life
in this flat and everything.

Yeah, but other than, my iOS
role, I write, as you said, I

write a lot of content online.

I've got my newsletter
and the IOC newsletter.

I've got my blog, which is PolPietro.

dev.

Yeah, just trying to like keep up with,
the community and write as I learn and

as I kind of like do a bunch of stuff.

I focus like mainly as well
on like tooling CICB, which is

like my main kind of like area
of like interest and expertise.

Yeah, I write a lot of like
tooling, talk a lot about

tooling as well at conferences.

So yeah, that's, that's
a bit about, about me.

Leo Dion (host): And we did an
episode a few years ago with Kyle

Newsome and it's, some things have
changed a bit in that space what's

been the big, big changes in the
last few years when it comes to CI,

Pol Piella Abadia (guest): So I think
in terms of like the, like CI, CICD and

how it's like changed over the years,
I think the introduction of things

like GitHub Actions has like really
Opened up like a world of possibilities

for like people wanting to learn
more about what goes like under the

hood and wanted to like make things
for like their own, their own apps.

Like since I started my career, it's
been, it was always like a gray area

that there was one person who was some
form of like wizard in the company or

someone who really knew about CSCD that
all of the work was dumped onto them.

So that was one of my,
my passions was to like.

Learn a lot about it and, properly
understand it and make, everyone in

your team as well involved with it
because we're all like responsible

as part of like, I think mainly big
changes you don't like, there's a

lot of like, things now that you can.

Like find out there, like in the
open, you can do for free as well.

So you've got GitHub actions.

If you've got a public repository,
for example, you can get unlimited

minutes for macros runners.

Arguably it's not the fastest, but
you can literally, there's no barrier

of entry to your, like CICD if
you've got like public repositories.

Leo Dion (host): It doesn't
have the fastest updates.

Let's not forget

Pol Piella Abadia (guest): no, it really
doesn't like they, it probably has the

slowest updates actually, I would say.

So, yeah, and it's actually very
expensive if you want to get the, macOS

runners on like private repos as well.

It's, it's fairly pricey and it
doesn't come with like fast updates

either if you go like GitHub hosted.

But yeah, there's, there's that like
how open like things are becoming,

how much content there is out there.

I feel like.

There is quite a lot of, like, resources
that from people I don't know, one

that comes to mind is Roger, who's one
of the core contributors at Fastlane.

He writes a ton about, like, CICD as
well, and there's, like, Manu Herrera

as well, who I share a lot in my blog,
who also writes a lot about CICD.

And I feel like the, this is one of like
the main like changes I've seen over

the past few years where a lot of people
have seen to be like very interested

and writing a lot of content about the
actual building side of an application.

And obviously the big like game
changer in the past few years

for like iOS apps is Xcode Cloud.

Obviously, I think it was last year
or the year before that it got.

Yeah, I got introduced.

Leo Dion (host): Right.

Pol Piella Abadia (guest): but yeah,
it's made in my, from my point of

view, it's made like deploying apps,
like super, super easy and setting

up a CICD pipeline for your IOS
app is literally just a no brainer

and directly from, from Xcode,
then it's just super, super easy.

So for me, that's in terms of like
IOS CICD, that's the big game changer

over the past couple of years.

Leo Dion (host): What's your thoughts?

Like, if you were gonna get
started today without any

experience, what would you use?

Pol Piella Abadia (guest): So if I,
yeah, if I was a company that was

starting today or if I was an indie
dev and I've actually done that for,

for curate as well I would go for
either Xcode cloud, or I would go for

whatever, like either the company's
using and people are most familiar

with I think there's like options,
which are very, if it's not Xcode

cloud, GitHub actions is risky.

I would probably go with.

If you go in github hosted runners,
it's risky because you're gonna get

pretty slow runners Or you're gonna
have to pay a lot for the fast ones

and you're gonna be waiting a long long
time for updates and Yeah, but if you,

like, this is what we use at the BBC,
it's GitHub Actions with self hosted

runners that seems to be like, a very,
you're in charge of your machines, you

can basically just commission them and
sign them, provision them yourself.

You can also, I think a lot of people
are going down the route of like,

AWS like EC2 instances with, you can
basically spin up, so you don't actually

have to maintain the physical hardware.

So you can just.

Spin up, machines in, in AWS,
personally, I would go for Xcode

cloud if I'm doing a, yeah an app
to be honest, I think I found that

workflow absolutely frictionless.

I'm a big fan of like fast
lane as well and how much it's

improved, like the, code signing,
which is for me, the biggest.

troublemaker when it comes to, CICD and,

Leo Dion (host): Match is amazing.

Pol Piella Abadia (guest):
it really, really is.

And it's made things super easy, but
when you've got Xcode cloud, you forget

that, code signing actually exists.

It all happens.

Under the hood for you.

It's all managed.

They will create like all
your provisioning profiles

everything you need So yeah,
that's that's where I would go.

It's been What i've used for
any like in the kind of like

small apps that I have made.

There is a big Problem with that.

There's a limitation with that At
the moment and the limitation is

that you can't have standalone swift
packages basically on on xcode cloud so

Leo Dion (host): Yeah, right.

That's not their forte.

That makes

Pol Piella Abadia (guest): So
if you're developing a library,

basically and you just want to use
Xcode Cloud for your Swift package

you can't do it, like, standalone.

You need to embed it in an
application and then create a an

app on App Store Connect as well,
so that it can have a link to it.

It's a bit, yeah,

Leo Dion (host): Oh, wow.

That's

Pol Piella Abadia (guest): yeah,

Leo Dion (host): Yeah

Pol Piella Abadia (guest): Yeah.

Yeah.

Leo Dion (host): You're really trying
to put a square peg in a round hole

there Yeah, cuz I mean their interest
is a getting stuff on the App Store.

So it makes total sense Yeah,
so I use github actions for

all my Swift package stuff.

That's just the easiest way to go
Yeah, the headache with versioning

so There's one issue, maybe I don't
know how you'd get around this is

like, how could you do like something
like self hosted on a public repo?

Cause they definitely discourage
that for security reasons.

Like if somebody forks, they can run
on your machine and stuff, but it's

like, I don't know how else to get
around the fact that they don't update

their machines, but then I want to
test my public repo on a modern OS

that's been around for a few months.

You know what I mean?

Pol Piella Abadia (guest): I think you
can, so I think you can I understand

why it would be discouraged, but I think
you can prevent people from running

the actions if they're like on a fork.

I think you can, you
can do certain like.

Security measures around it.

So you can like really be in control
of what gets run on your machine.

I think other than that, I know
it is like, yeah, it's a massive

like limitation that you can't.

Yeah, the versions are so
old, but for my open source,

lots of packages, I just use.

Like github actions with github
hosted runners because they're free

basically and that's something that
I really appreciate But it's not

Leo Dion (host): Right.

Right.

Right.

Pol Piella Abadia (guest):
yeah, it's not great though.

Like the performance.

I think they're intel machines
at the moment I don't know last

time I checked the road map.

It was the fourth quarter
of this year that they were

introducing M1 like silicon.

I don't know if they've done it yet.

But yeah, there's still intel runners
limited to three cores on the free

tier, which is really not ideal.

Yeah, you can go for the

Leo Dion (host): So I
run all my, my apps.

I do get lab cause it's super cheap.

And then I do get lab CI,
whatever they call it.

I forgot what it's called.

And then run fast lane.

What are some besides the simplicity,
what are some advantages or

disadvantages with like Xcode
cloud over using another service?

Pol Piella Abadia (guest):
I think advantages.

It's how Easy it is to set up.

And how, like how fast everything is
in terms of like the support, not that

the runners are actually that fast.

I think the last time this was a long
time ago, but I had a conversation

with someone about the runner still
being like Intel virtual machines.

It was like a, a bit of a
strange set up they had.

So it made like builds a bit slow.

Leo Dion (host): Yeah.

It's whatever they got from BuildBuddy.

Pol Piella Abadia (guest): Yeah so
yeah, I think the main advantage

for me is how quickly they, it makes
sense because it's their tech, right?

Like their tech stack and their versions
and their machines, but how quickly

they actually adopt new, like, beta
versions, new like software releases

for like macOS as well, and how
quickly you can run on an Xcode beta.

And how many options you've got so
yeah, I think that's that's one very

big advantage like probably I've not
really looked into how quickly they do

it But every time I check there's like
the latest beta there's like You know

the the most stable release and you go
back like a couple of versions as well

of xcode usually and so I would say
that's the main like advantage It feels

like it's like the native approach like
they're gonna have access to everything

Before everyone else does in a way.

So they've got like more time to
like prep for it and they're going

to be quicker, like putting out
like workflows, one thing that.

Leo Dion (host): I think they're gonna
financially invest it, being that Apple

is trying to pivot towards service.

It's like, okay, like, they're already
trying to upsell you when you have

Xcode, so it makes total sense.

Pol Piella Abadia (guest):
Disadvantages.

I would say one of them is
the Swift package thing.

I was really, really hoping for, they
actually have some documentation about

how to build Swift packages on Xcode
cloud, but it literally just says

it's not supported, like standalone.

As soon as you click on
it, it's very misleading.

You go on it and it says
you can't do it standalone.

You need to create an app target and
then put your package in it, add it to

the test plan and then run the tests,
which is not what you want to do.

Yeah, another disadvantage I
would say is that it's, it's quite

young, like it as a, as like a
technology, like they was only

released like a couple of years ago.

So there's still like limitations,
for example, with fastlane, you can,

you could do on GitHub actions, you
could do like deliver, like very,

very quickly to, upload metadata and
release notes and all that stuff.

And there was no native way of doing it
in Xcode cloud until fairly recently,

where they introduced, like, a directory
called, I think it's release notes

or text files or something where you
can actually say what you want to put

in your release notes in test flight.

So that was added only recently,
so it's gonna get better over time

and they're gonna invest time, and
the last thing I would say about

disadvantages is there's not.

There's a free tier at the moment,
which is ideal for any like indie devs.

You're not, it's like 25 hours
a month, I think, and you're

probably not going to use them.

Leo Dion (host): Yeah.

Pol Piella Abadia (guest): if you're
like a solo dev but that's some,

something that's in the like little
writing on the pricing page is that

that's ending at the end of this year.

So there's not going to be a free
tier from the beginning of next year.

So you're going to be paying 1499, I
think, the cheapest tier and that will.

Yeah.

Leo Dion (host): Four 99, like 5 or 50.

Pol Piella Abadia (guest):
15, as in 1499.

Yeah.

Leo Dion (host): Got it.

Got it.

Okay.

Okay.

Pol Piella Abadia (guest): So that's a
month for 25 hours of like compute time.

So yeah it's going to be a paid service.

Basically that's, there's not going
to be an option for a, for a free

tier, regardless of the usage.

Yeah,

Leo Dion (host): That kind of sucks.

If you already have an infrastructure
existing infrastructure for CI, like,

like for me, like I use fast lane and I
have custom tools that I have prebuilt.

Like Xcode gen using get
lab and all that stuff.

Is there any reason I should
be switching to Xcode cloud?

Pol Piella Abadia (guest): I, I
wouldn't say so, to be honest, at

the time, if you've got a setup that
works for you and you're adapted to

that workflow and you like you, it
works for you, then I wouldn't say

there is like a reason to do so.

If you were to switch as well.

I don't know how it works with like
Xcode gen, because I think it needs

the Xcode project committed to.

Like to the repository
for Xcode cloud to work.

So

Leo Dion (host): you
can't run any pre stuff.

Pol Piella Abadia (guest):
yeah, it might be a bit tricky.

So I think you can run a post clone.

So maybe you're able to kind
of like generate the project.

Then I think that's where you install
like the third party dependencies.

So maybe you're able to generate
the Xcode project there.

And it might like pick it up.

I'm not, I'm not quite sure
how that, how that will work.

But if you wanted to use your Fastlane
scripts that you already have.

You can like use them still
with with expert cloud.

You can put like little
hooks at different places.

You can install like Fastlane
as well on the runners.

So you can still like reuse
some of the logic you have.

As to whether I would switch or not,
if you've got something that works

for you, to be honest, I probably
wouldn't, like, wouldn't bother.

If you start something fresh and
you want to try it out and see

if it like works for you, I would
maybe like suggest trying it out

because it's, it's pretty good.

But it has to be like,
a specific use case.

It has to be an application.

If you're releasing a, an open source
package or a library or anything

like that, I wouldn't, I wouldn't
bother because it, it doesn't,

you'll be jumping through like
hoops to make things work and it'll

be more painful than, than useful.

Leo Dion (host): So let's talk a
little bit about Xcode 15 and what

do you think are like the biggest?

Game changers that's come
out Last few months that's

gonna like really help Okay.

Pol Piella Abadia (guest): I think
in terms of like project structure

and something that I've been like
frustrated for some time now and with

like modular projects because I, I
work in iPlayer in the BBC, I work in

a very big like modular project and
we've got a bunch of like dependencies

that are internal to the organization
that are still like Cocoapods so we

can't really use Some of our packages,
some of our modules are swift packages.

Some of them, some of the other ones
are Xcode projects like frameworks.

So we, we've got like some dynamic
frameworks and some of the pain

that we actually experienced is that
you can't in like Apple ecosystems

in iOS, you can't really have like
umbrella frameworks that embed

like other frameworks basically.

So you need to embed them.

Link them dynamically on a library
or a framework and then embed them

at the root of your application.

So, say you've got like a feature,
your home feature, and you split

your feature into two different
modules, which is the UI and the core.

Only if everything's dynamic, only
have to import home on your app target.

You also have to import home UI and
home core because like an embed them.

So it can fight, the app
can find them at runtime.

So that was one of the like biggest like
pain points that I always had, because

this, even though you can enforce
it with like some coding practices,

it actually leaks like the, the two
modules, because you have to import them

out and embed them up a target level.

So

Leo Dion (host): Right.

Right.

Pol Piella Abadia (guest): this is all
changing with marriageable libraries.

So we do something that they
introduced with Xcode 15.

I think it's, yeah, I've tried it on,
on a couple of like modules as well.

I worked just on a few, like demo, like
spikes and tests it works very well,

like what you can basically do is you
can tell it to create like a binary.

It works like umbrella frameworks.

You can.

Technically have embedded,
embedded libraries in a framework

in a, in a project and what it
does is it gets the best of like

static and dynamic frameworks.

It does a lot of like magic as well.

And it, it makes like your
dependency list at the app target

level a lot, a lot simpler.

So that's one of the things
that for maybe selfish reasons,

because I work in like modular
applications quite a lot I'm

Leo Dion (host): Yeah.

Yeah.

Yeah.

Pol Piella Abadia (guest): about.

Leo Dion (host): So is this like you
would set up a framework, you set

up frameworks and Xcode and then you
say, make them, make them mergeable

libraries, or how does that work?

Pol Piella Abadia (guest): you
basically do it at the framework,

so there's two ways it can work.

So at the framework level, at the
library level, you tell it whether

you want automatic or manual mergeable
libraries so library merging or

whatever it's called, and it will
grab all of the dependencies, and if

you select automatic, it will try to
merge all of the dependencies into

the final binary of that library.

And then whenever you embed or import
that library into your app, you will

no longer have to embed any of the
dynamic libraries it's linking against.

It will just happen magically.

And the other mode is, I think it's
called manual, and then you choose,

you basically pick and choose
whichever libraries you want to merge

and whichever you actually don't.

So it's a bit like manually
you do it manually.

In that case, it is pretty cool.

It's one of the things
that got like missed.

It didn't get a lot of attention.

But if you've got a modular application
and you're struggling with like massive

dependency lists and embeds in your
app target, this has come to fix it.

Like it's, yeah, it's
absolutely fantastic.

And they've done some, yeah,
pretty amazing work on it.

Leo Dion (host): So with with
Bushel, I think I'm up to like

20 different like targets.

And I, I do all Swift packages.

Is there any advantage I would have with
like mergeable libraries when it comes

to everything being in a Swift package?

Pol Piella Abadia (guest): So I think
you get all of the cool things for

free if you're in a Swift package.

So in a Swift package, you
can declare whether you want

it to be dynamic or static.

You want the type to be dynamic or
static, or you can leave it blank, which

means that Xcode will do some magic for
you, and it will pick what suits best.

So you get, all of this is
free for you on Swift packages.

This is for Xcode frameworks, basically.

Which...

Leo Dion (host): it.

Got it.

So if I'm automatically creating a
project and referring to the product

in my app, then it'll automatically
use whatever it's supposed to use.

Pol Piella Abadia (guest):
Yeah, as a, as a, yeah, exactly.

Yeah.

It's fantastic.

Like, I think the only reason why
we've got Xcode frameworks is because

we've got like some limitations
where we need to import like Cocoapod

dependencies and stuff like that,
which is, yeah, it's a bit annoying.

Leo Dion (host): it.

Objective C.

Python.

God

Pol Piella Abadia (guest): that as well.

Leo Dion (host): One of the
things you have on here is, well,

let's talk about Swift packages.

There's a couple of things
we've got this year.

So macros now is essentially
a part of the Swift packet.

Like there's no way of doing
building your own macro without

going around Swift packages.

You pretty much have
to do it through that.

Correct.

Pol Piella Abadia (guest): Yeah.

Leo Dion (host): What's been
your experience with macros?

Have you built your own yet?

Pol Piella Abadia (guest): So I
tried the like demo URL one, like

the type safe URL and I tried the

Leo Dion (host): Yeah, yeah, yeah.

Pol Piella Abadia (guest):
stringify one as well.

I am still struggling a bit.

I'm not gonna lie.

They're pretty complex to
kind of like understand.

Leo Dion (host): Yeah,

Pol Piella Abadia (guest): Yeah,
I'm working on one that's now

a like little testing library.

So something I did with
like, with sorcery a while

back where you can basically

Leo Dion (host): yeah, that makes

Pol Piella Abadia (guest): Yeah,
directly just trying to do it with

macros just to learn basically and get.

Some more like level of modularity
with those macros, it's pretty

impressive what it can do.

It's yeah, it's, it's very, very cool.

And I do like anything that's
like compile time and build time.

And it kind of like gives you
that compiler safety as well.

And you can even write
like unit tests around it.

I'm a big fan of and it doesn't
require having to go use another tool

to like generate code as well, which
is, yeah, it's pretty impressive.

And obviously.

It makes sense to be familiar
with all of that, right?

Because SwiftData is using that.

And obviously the new observable
stuff, it's all going to

be using macros as well.

So, yeah, it makes a lot of sense
to get as familiar as possible.

I have to say I've been avoiding it a
bit as much as I could, because I feel

like it messes with my head quite a lot.

Like when I start looking at the
syntax trees and all that kind of

thing, I end up just writing...

A ton of strings of code just trying to
like, this is what I want to generate.

Do this for me.

But yeah, how, how

Leo Dion (host): on chat GPT.

Pol Piella Abadia (guest):
Yeah, exactly.

Exactly.

Leo Dion (host): Come on.

Pol Piella Abadia (guest):
How have you found it?

Have you made any macros

Leo Dion (host): so I I am say
I'm a consumer not a like not a

developer of macros I just I just
to once I go down that rabbit hole

I'm just never gonna get out and
the next thing I know I've had like

20 200 macros uploaded to Get hub.

And it's like, no, no,
I need to build an app.

I need to like actually use them.

So in that case, what, what, so
as a user I think I mentioned

this, just a couple of weird
things where like, it messes like

some stuff just doesn't work.

The way you think it would, I have
had some weird issues where I had

like the day before WWDC, I had like
a class or struck called preview.

And then I'm like trying to use new live
previews and it wasn't working because

it was, there was a name conflict.

And of course I didn't know that.

Like, and I'm like, these live previews
don't even work in my version of Xcode.

What's going on?

And then I realized, Oh, it's
because I had a type I put in the

day before without even knowing
they're going to set these up.

And then like there's some weird stuff
if you have still have like avail,

availability markers or availability
attributes that kind of messes with it.

So I have to figure
out a way around that.

But yeah, it works.

I'm glad we have expansion so we can
actually see what the heck is going on.

Cause without that, I think, it'd
be weird, but yeah, I'm using

observation and SwiftData everywhere.

So, I'm totally a consumer
now of macros everywhere.

Pol Piella Abadia (guest): Yeah.

We, yeah, I've, I've started using like
SwiftData in quite a lot of places now

and I think it was yesterday I had like
Twitter rant because So we, yeah, if

you've got like a big chunk of data
that you're loading from the database

and you're doing like expensive stuff
like your UI suffers quite a lot.

And the reason, yeah, the reason
for that, even though they release

like model actors and you can put
everything in like an isolated actor

that runs on a different thread.

The database access is all, has all
been synced up to the main thread.

And that's, yeah, it's, it's very,
very strange, but I think there was

an issue in before beta seven where
you were able to kind of like do

things on the background, but then.

That those changes wouldn't
synchronize to the main thread, so

the UI wouldn't refresh until you
kind of like restarted the app.

And then people like devs complained
about it, and then the solution

seemed to be to put synchronized
changes on like the main thread,

so put all the database access
on the main thread, which is.

Yeah, which is pretty annoying.

That issue is still on the, like, RC
as well, and on that thread, like,

someone replied saying that they were,
like, a few people replied saying they

were experiencing the same issues as
well, and, yeah, I feel like it's been,

it's been a bit frustrating, but I, I
actually love, like, SwiftData and how,

Easy makes everything so I'm hoping
that that gets fixed like at some

point soon before before the release

Leo Dion (host): Wasn't that like
one of the big things with managed

object context was you're supposed
to run it on the background.

So it's like weird, like
SwiftData required, I see,

okay, you're updating the view.

So you want to have the main
thread, but still I could see in

your case that being a pain in the

Pol Piella Abadia (guest): yeah So I
think you're able to run all of the

kind of like code all the way up until
up until the you know It needs to

insert into yeah into the database.

I think all of that can happen in a
in enough in another thread, but It's

just the database access and stuff
that seems to be on the main thread.

I'm not entirely sure why, but
yeah, it's something that we're like

struggling with at the moment, but
yeah, hopefully it'll get fixed.

Leo Dion (host): Do you miss
anything with core data?

Pol Piella Abadia (guest):
I don't, I don't think so.

I wasn't like, I know, like,
QReate still uses Core macOS.

Leo Dion (host): Okay.

Pol Piella Abadia (guest):
But I, I quite like it.

I'm quite happy with
the way Core Data works.

And I, at any of my jobs, we
never really used Core Data.

So my experience is not,
like, amazing with it either.

Like, I've not used it, like,
extensively other than my own apps.

And my experience has been alright,
apart from, like, some weird

crashes that you get every so
often that you need to look into.

But yeah, other than that, I'm
quite, yeah, quite happy with it.

There's nothing, and I
think there was a Swift

Leo Dion (host): yeah.

No, I like SwiftData.

I feel like now it's like I don't feel
apprehensive about using core data.

Like I didn't have anything
against it, but I was like, I

don't really want to put this in
if they're going to replace it.

So to finally have that replacement,
it's like, okay, now I can, like, I

don't care if there's bugs with it.

I'd rather work with this and
know Apple's going to maintain it.

As opposed to like core
data, which is like, yeah,

Pol Piella Abadia (guest): I think

Leo Dion (host): in
the neck to deal with.

And, and the interface is
still so object objective.

See, like, it's just like, yeah.

Pol Piella Abadia (guest): Yeah,
I think if there's something that

you're missing from core data that
you don't have in, in SwiftData, I

think someone made I read it in like,
ISDev Weekly a couple of weeks ago.

Someone made a Swift
package called SwiftDataKit.

Which kind of like bridges the gap and
gives you like some extra functionality.

Then you, it exposes some like core
data, more like, complex functionality

that's not available to Swift.

SwiftData, I've not tried it yet, but
it sounds pretty interesting as well.

If you want like some, some extra
bits or there's, there's something

that you, you, like you wish
SwiftData had that core data.

Leo Dion (host): Yeah.

Any other developer stuff you
want to talk about before we

hop in and talk about some of
the projects you're working on?

Pol Piella Abadia (guest): I think, I
think that's that's about everything.

I think other like Xcode 15, well,
that's more of a, like a Swift 5.

9 feature that I think it's great.

Is the fact that you're now going
to be able to do a network requests

from like Swift package management.

Leo Dion (host): Explain
that a little bit.

What does that mean?

Pol Piella Abadia (guest): so basically
the way plugins used to work, so they're

the equivalent to, like, build cases in
in Xcode projects, so you can run build

scripts where, or even command plugins
where you either run them as part of the

build process, or you run them manually
when, within a soft package, basically.

So SwiftPackage plugins for like the
safety of the developer and for, for

safety reasons, they run on a very
tight like sandboxing environment,

which means that you need to, you can
only write to a specific directory.

If you've got a command plugin, if you
want to write to the package director,

you for permissions, basically.

But from Swift, they also don't
allow you to do any network requests

to either like a local server or
to a remote server, basically.

And from Swift 5.

9, there's a new permission you can ask.

So you can ask the user for
permissions to make network requests.

So it's going to make like
command plugins super, super.

Useful because you'll be able to make
a network request you want and this

is an example of this is the I don't
know if you've used the swift aws

lambda runtime project so they've got a

Leo Dion (host): Yeah.

I did a client project with that.

So yeah.

Pol Piella Abadia (guest): so they've
got a command plug in to Package

your, your Swift Lambda into a
zip file which is called archive.

And that requires you to disable
the sandbox so that you can

make requests to like a Docker
daemon to build the application.

Leo Dion (host): Hmm.

Yeah.

Pol Piella Abadia (guest):
So you're no longer going to

have to disable the sandbox.

You'll, they'll just need to
add a permission from Swift 5.

9 that says.

We need your permission to make
contact with the Drer Damon and

it will be like a lot simpler and
you'll build a bit more like trust.

You won't have to ask the user to
be like, oh yeah, disabled like your

sandbox to, for us to run all this code.

You'll be able to say why you
wanna disable the sandbox and

only for that specific reason.

So I think that's a big like game
changer for tools like that that

need to make network requests either
to like a local server remote or

like to a Docker like Damon as well.

So yeah, that's another
big thing coming in.

Yeah, so it's 5.

9.

Leo Dion (host): We're talking
about us with packages.

Like what kind of stuff do you
do in your CI to make sure that

your, your packages are easily
consumable and working properly?

Pol Piella Abadia (guest): So I
think in my like CICD, what I do

is I tend to run them in like, if
I support like multiple platforms,

I tend to just run them in both.

Like I usually tend to
support like macOS and Linux.

So I just run them on like both and
I spin up like a couple of workflows.

Tend to have like automated,
like release workflows as well.

I've written like a bunch of
blogs about how you can automate

like, all this kind of stuff.

Leo Dion (host): Okay.

Pol Piella Abadia (guest): and I think
in terms of like making sure that

everything still works, like having
tests and actually running them on ci

on all the platforms you support is
the only way you can actually achieve,

like, make sure that everything works.

And I'm a very, very forgetful person
and I think the passion for like

tooling and CSV comes from that.

From like,

Leo Dion (host): Yeah.

Pol Piella Abadia (guest):
yeah, mistakes I have done.

Yeah, I've done in the past
that I want to fix basically.

Leo Dion (host): Yeah.

So I've got like, yeah,
I'm doing the same thing.

I'll run, I'll set up a matrix for
Linux Ubuntu to run, a couple of

versions of Ubuntu, a few versions
of Swift, whatever I support.

And then like, same thing, try to
do the whole gamut of macOS versions

and then you do like Xcode build
for iOS Or else I want to support.

So yeah, I'm on the same page as you.

Pol Piella Abadia (guest): Nice.

Leo Dion (host): What's this thing
about automated accessibility audits?

Pol Piella Abadia (guest): Yeah.

So that's, that's another of the
things I was like super excited

about because we so at, at the BBC,
we've got like a very big focus on

like accessibility for, for our app.

And one thing that I wanted to
do a while ago, and there's an

amazing like library that it's no
longer maintained anymore, but.

By Rob Whittaker who speaks a
lot about like accessibility and

he's yeah absolutely amazing.

He made a library to automate
accessibility checks on UI tests.

So it would just spin up a screen in
your app and you could check for like,

whether your controls had enough,
like target size that were big enough,

like, enough of a like a touch area.

And whether your images were labeled
accordingly, whether you were

missing like some accessibility
labels, all that kind of thing.

But yeah, it was still like
a third party library and you

had to kind of like import it.

That is all now part of XE UI test or XE
UI test element, whatever it's called.

So yes, as with with Xcode 15,
you're going to be able to run

accessibility audits basically.

So you can spin up your
application in a specific screen.

And you can call on XE UI
application, you can call

perform audit, I think, or check
accessibility or something like that.

And then it will just check for
whether you've got clipped text,

whether your app resizes for
like dynamic type whether there's

sufficient like color contrast for
all of your texts and elements.

It's.

Literally zero effort.

Like it's minimal effort to
set it up and it can save you

like a lot of like trouble.

You can automate it on C I C D and
if you've implemented a new feature

like a UI and you've made a mistake,
you've not, for example, not you've

made your text like a color that's not
got enough contrast, it will just flag

it up and fail your, your bill before
you release so you can go and fix it.

Leo Dion (host): okay.

Pol Piella Abadia (guest):
cool and there's no need for

like a third party library.

I guess it's all inspired by projects
that you know Open source project

that existed before I guess so yeah

Leo Dion (host): Rob, Rob
was happily Sherlocked as a

Pol Piella Abadia (guest):
yeah But yeah,

Leo Dion (host): So, yeah.

Pol Piella Abadia (guest):
Amazing project to be honest, so

Leo Dion (host): Yeah,
Rob's, Rob's amazing.

I met him, and He's, yeah, like
you said, he's really dedicated

to accessibility and stuff, so
Yeah, maybe I need to have him on,

okay, what have you been working on?

Well, first of all, let's plug your
app that I've been using if you're

watching this on YouTube, if you
look, I think I'm going to put it

on the lower end, assuming you're,
we're on the top, usually it's one

of the two you'll see a QR code
there that I always put that goes to

either the transistor Social media
page for this episode, or it'll go.

I've been lately linking them to
break digit podcast episode page.

And I always have that there on YouTube.

So people who want to subscribe
to the podcast can do that.

And if you want to subscribe to
the YouTube page, that's good too.

So.

Do that right now while
you're listening to this.

But yeah, I had been
just pulling them up.

There was a website I used
to create the QR codes.

It was fine.

There was always finagling
to get it to work properly.

And then I'm like, Oh, Pol, you did it.

You created what I've been looking for.

Cause I was like, it was on my bucket
list of apps to create, but I'm super

glad in this case, I'm super glad
somebody else has done it for me.

We have curiate, curate, curate, curate.

Pol Piella Abadia (guest): I, I
think it, yeah, however you want to

pronounce it, I feel like I don't
even know how to pronounce it myself.

So yeah.

Leo Dion (host): But it's awesome.

It's been a great tool, a great
asset for the production of the show.

So, I'll let you explain
it and why you made it.

And what are some bells and whistles
that you really love about it?

Pol Piella Abadia (guest): Yeah.

So I, the reason why I made it, so for
anyone who doesn't know the app, it's,

yeah, it's Curate, QR8, however you
want to call it, you can call it that.

Leo Dion (host): Curate.

I like curate.

Like curating.

Yeah.

No, that's

Pol Piella Abadia (guest):
So yeah, curate is a QR

code generator, basically.

So you can create any QR codes, give
it some content, choose the, it's pre

customizable at the moment, so you
can choose like the shape of your...

QR code, the color, background color,
all that, all that kind of stuff.

And you can quickly export it to like
your clipboard or put into like an

image like jpeg Or I think it's png
as well that I allow to export and

it's got no tracking no anything like
that Everything stays on on device

as well, which is something that
people people love and something I

wanted to make Because one of the
frustrating parts is that finding

a QR code service or website that
actually works well, it's pretty hard.

And sometimes you don't really
want to, and most of them

offer like tracking by default.

So it basically will give you,
they're either like paid services

or they give you like some.

Leo Dion (host): a UTM type

Pol Piella Abadia (guest):
Yeah, yeah, awesome.

Like,

Leo Dion (host): yeah,

Pol Piella Abadia (guest): yeah, some
specific, like how many people have

viewed it, all that kind of stuff,
which is, which can be useful, but

sometimes you don't actually need it.

Like, for example, I, the reason why
I made it was because I wanted to

create like QR codes for my talks,
for the talks I give conferences

and for like Twitter sometimes.

And I just wanted something
very, very simple.

And yes, I, I honestly thought
no one was going to use it.

It was just going to be me.

And I was happy about that because I
needed the app and it turns out like

it got a very like nice reception, like
people that have been using it a lot.

I, every time I go to like
conference people like I went to

ISWK a to speak and the organizers.

Yeah, the organizers were using like
use create for all the like QR codes

in the slides for the introduction
and they were like, oh, yeah, we

used your app and I was like, oh,
yeah, that's that's very nice.

And then I got a message today
as well that someone was used

my app to create QR codes for
the slides in Spain as well.

So yeah, it's pretty nice.

It fits like the use case that
I had, which is, creating QR

codes for Presentations and for
like sharing your your work.

Basically.

I think that's how I brand it
like a simple way of like just

sharing what you do So yeah

Leo Dion (host): could put
a little logo in the middle,

which is what I do if you see.

And it's like super simple.

It's just exactly what I need.

It's like all I want is something
I can import into Final Cut

and put it in my videos.

And

Pol Piella Abadia (guest):
Yeah, and there's

Leo Dion (host): there, there it is.

There it is.

Yeah.

Yeah, and it worked great.

Pol Piella Abadia (guest): there's
nothing in the middle either So like

it's all just a qr code with a url.

So and the url you provide so there's
no proxy or anything in the middle

So the qr codes are not gonna stop
working like ever so yeah, that that's

one of the things that I like because
I I went back to like a presentation

I did last year and I grabbed all the
QR codes that I had and none of them

worked because I was using like some
service that I had a free trial on.

And so they all stopped working because
they pointed to either the redirected

to the URL, which is quite annoying.

Don't want people to have to do that.

And I think I got asked when I launched,
someone asked, does it have tracking?

And I was like, Oh no, I might implement
it in the future if people want it.

And they were like, no, no,
no, please don't like we

don't, I don't want tracking.

Like I don't care about it.

I really don't want it.

Like it's fine as it is.

So yeah, that was some nice, like
feedback less work for me as well,

Leo Dion (host): what what was like
so QR codes like I assume there's a

tunnel is there any native libraries
to generate those I know there's

obviously native stuff to read them.

Pol Piella Abadia (guest): I think there
is a way you can, and Paul Hudson has

a way of like, some article on how you
can generate like QR codes natively.

I don't think it's very
customizable though.

So you can generate like a
box standard like QR code that

then you can share with people.

But I've used a library
called, I think it's called qr.

Code?

I can't remember what it's called.

I can share it, like, with you
later and you can put it in

Leo Dion (host): Yeah,
we'll put it in the

Pol Piella Abadia (guest): yeah.

But it's pretty cool,

Leo Dion (host): What was the
biggest challenge with building

this app or what was the challenge
that surprised you the most?

Pol Piella Abadia (guest):
I think the challenge was my

lack of experience with macOS.

I think that was my biggest challenge.

I use SwiftUI, like, for the
whole thing, to be honest.

Leo Dion (host): Yeah.

Pol Piella Abadia (guest): up the
core data stack was a bit off and

then getting it to sync with like
cloud kit because I'm working on

the IOS version at the moment.

So that that was the biggest
like challenge for me.

I had very little experience with
core data and I thought it was a

bit of a pain to get it all set up.

Leo Dion (host): Yeah, yeah.

Pol Piella Abadia (guest): I think
that was the biggest like thing and

my lack of experience again with with
Mac OS made it a bit hard to kind of

like, just how do I, make this like
split view and all that kind of thing.

Turns out with SwiftUI it's pretty
simple but I think once I get

to more complicated stuff And
that's what I have been dreading.

So I'm currently working on the iOS
part and also working on like templates.

So someone requested, if you wanted
to kind of like share a wifi password,

QR code, so you could generate
like a template that would just.

Have the fields already for you
rather than having to hard code like

the URL and type it out yourself.

I think, I don't know how I'm going
to model the core data stack at

the moment, but I'll figure it out.

It's going to be a bit tricky.

Maybe I'll wait until

Leo Dion (host): yeah.

Yeah, yeah,

Pol Piella Abadia (guest): a
thing and it's live and I don't

know how I'm going to do it.

I'll figure it out.

It's one of the beautiful things
about like being a developer, right?

It's just fun.

Find solutions to problems.

Leo Dion (host): Yay!

So, what else have you
been working on lately?

Pol Piella Abadia (guest): So yeah,
apart from Curate, I think about a month

ago, I started working with Hide, who
I think you you met in Turin as well.

And

Leo Dion (host): Yeah, we did an
episode about the Watch OS X, so yeah.

Pol Piella Abadia (guest): So yeah,
I've been, yeah, I've joined him

in an app called NowPlaying, so
we're now both working on it and

yeah, just working with him on the
iOS 17 update as well and we're,

Leo Dion (host): What's now playing?

Pol Piella Abadia (guest): NowPlaying
is an app it's a music app basically

that allows you to discover data
and trivia about songs and you

can, like, save songs as well into
your, like, collection and you can

basically, like, create your own
little collection of music as well.

You can see for a song if you're playing
on Apple Music and you jump over to...

To now playing as well.

It will show what you're currently
playing so you can tap on it.

And it makes sense because
it's called now playing, right?

So it shows you what it's playing now.

And then you can jump on it and you
can see how many awards it's got.

We collect data from like a
bunch of different APIs as well.

And we show lyrics, we show like
certain notes and trivia and

facts about the song itself.

Who wrote it, like other
than just like the...

The artists themselves, where it was
recorded, all that kind of things.

So it's...

Like your companion kind of
to Apple music at the moment.

So yeah, we're just
working together on it,

Leo Dion (host): Does it plug
into Apple Music or the Apple

Music API or any of that

Pol Piella Abadia (guest): yeah,
so it does, it does work with

the music kit basically alongside
other other APIs as well.

But the main source is music kit for,

Leo Dion (host): If you're
listening to something in Apple

Music, does it give you the, the
trivia or you have to pull up the

Pol Piella Abadia (guest): so you need
to go to the app to give you the trivia.

So yeah, it,

Leo Dion (host): and you listen you can
listen to music through the app itself

Pol Piella Abadia (guest): You can't
at the moment, you can listen to small.

Previews and snippets, but it all I
can say is it might in the future.

We'll see.

Yeah, we'll see It's one of the things

Leo Dion (host): Maybe maybe
some Shazam kit where I can see

in the future or do you already

Pol Piella Abadia (guest): we've got
that so we've got some kits so you

can basically listen So it's it was
built as well as like the watch app

was built as like a party companion
as well so you could just like have it

listening to songs and it would just
like give you, facts about them as

well as you were in a party and stuff.

So yeah, that's, that's very exciting.

I think yeah, so he had the app before
he released it, like on his own.

And then we, yeah, we met in
Amsterdam last year and we got

on like very well together.

We both like have a
passion for music as well.

We both like collect records.

And then he moved to Manchester
where I lived as well from Amsterdam.

So it was like the, a lot of things
fell, like fell into place as well.

And then after a while we were
discussing and he was like, Oh, I

would love to just continue building
this, like, but with you in this case.

So we kind of like, just decided to
both like take ownership of the app

and work on it together and just take
it forward and kind of like take it

to, to the next like step, and that's.

Yeah, that's

Leo Dion (host): lot of, a lot
of devs love buying records.

Like Adam had his

Pol Piella Abadia (guest):
oh yeah, yeah, the albums.

Yeah.

Leo Dion (host): Like, that's
like, yeah, that must be a thing.

Which I appreciate but
yeah, that's, that's great.

Pol Piella Abadia (guest):
feels, feels a bit weird, right?

That we, as like tech people
and like developers, we go back

to analog stuff quite a lot.

Yeah.

It does feel a bit weird,
but yeah, I don't know.

Leo Dion (host): Just to plug our
next episode Casey list is going to

come on and talk about call sheet,
a very similar app to now playing.

So, just basically like
a movie counterparts of

beyond the look for that.

Yeah, yeah, yeah.

So yeah, that seems like
a thing people want.

It's like, what do they call it?

We talked, I think I talked to
Hiday about this, like the, I

think we did talk about this app.

So it was like the x ray on
Amazon, like that kind of thing.

Yeah, yeah, yeah.

So, and I, that sounds like kind
of what Casey's doing as well.

So, cool.

Yeah, yeah, I love that stuff.

So, nice.

So before we close out, I do want
to geek out about one more topic.

You want to build a ready to use
UI components for CLIs and Swift.

This is something that
I've geeked out about.

There was a really forgot the name,
but I'll post the link to the repo.

I mentioned it to you, but there's
like a ton of projects out there where

people have been trying to do this.

I've been trying to do this.

How's that doing going?

And you want to explain what
you're trying to do exactly.

Pol Piella Abadia (guest): Yeah.

So my work has been like, so I'm very,
when I started like developing command

line applications before I went to just
making everything with like Swift, I did

a lot of like JavaScript for like CLIs.

And I was very, very jealous
when I moved over to Swift about

how many libraries there were
to do like pretty, like, like

stunning UI on like the terminal.

You could even have like
react components as well.

Like some form of like react components,
like a very obviously like narrowed down

version of reacting in the terminal.

That's what kind of like inspired
me to, yeah, to like migrate.

And the reason why I did it was because
I wanted to use a library called Clack

which is a JavaScript library that
allows you to do a like step by step

form of you can, I can send you the link
and you can put it on the show notes

as well, but it's like a step by step
form with like async, like spinners

and loaders and like, text fields and.

Like placeholders, like it's got
selects, like multi select speakers.

It's pretty amazing, like all it can do.

And, and I want just to build
like a Swift port that I can use.

Cause I really, really like the library.

It's made by one of the creators
of Astro, the web framework who's

called Nate Moore, I think, so yeah,
it's it's got like a lot of backing.

I think astro used it.

I don't know if they still use it
Cloudflare the cli also uses clack

under the hood, I believe so yeah,
there's a bunch of like people using it.

But I have recently so i'm giving a
talk next month in leets about like

cli applications and i'm going to be
talking a lot about How to make like

a beautiful, like UI on the terminal.

So I'm going to be talking about like
all of these geeky things you can do.

And I've come across like
a ton of like libraries.

I hadn't come across the one you
showed me and I'm going to be trying it

Leo Dion (host): Rens Brewer
who posted it on on the Swift

UI or the Swift subreddit.

A while ago, and I'm like, I've been
looking for something like this.

Cause there's like a
lot of tools out there.

I used to be subscribing to
forgot the subreddit where it

was like basically a showcase of
like different terminal tools.

And I'm just like, I wish, so we have
argument parser, which is awesome

and fantastic, but I wish there
were something like to build these

really cool terminal applications.

And I'm just like waiting
for the use case to use this.

And like, I think.

I think I'm thinking like maybe one
use case is like when you're running

a vapor server, it'd be nice to have
an interface, like a dashboard to

show you what's going on on vapor.

That's one thing I've had
in the back of my head.

I have a few ideas, but
like, yeah, it's just like.

The, the ability to see progress,
the ability to like do colors.

And it's all like, like
I started playing around

like ASCII codes and stuff.

So I've definitely gone down that rabbit

Pol Piella Abadia (guest): Yeah.

Leo Dion (host): like, you're like,
okay, so that stuff is actually easy.

It's when I start doing like,
okay, how do I use, like, how

does, how the heck does Swift UI?

do view builders and how do they
do states and how do they do

like all this stuff that's just
like like what is going on here?

And how do they build these views?

Cause I want to do something like that.

Like I know how to do it with
characters, but I don't know how to do,

make it as friendly as with two eyes.

You know what I mean?

Pol Piella Abadia (guest):
I know what you mean.

I.

Leo Dion (host): So yeah,
that's where I got stuck.

Pol Piella Abadia (guest):
It's yeah, that, that project

looks super, super promising.

Like I'll be trying it out
is what I'm doing for the,

for my Tolkien Swift leads.

I'm doing a command line
tool that uses music kit to

like fetch song information.

So similar to now playing basically
where we, yeah, I get a ton of like,

songs information from like a text
field where the user can type in,

and then I'm going to do a list where
the user can like scroll and pick.

From that list, and then it's going
to launch an application and it's

going to like play the song basically.

So it's like a heavy, like
involved, like, Swift CLI.

And,

Leo Dion (host): what are they, so he
works, Renz works at SoundCloud and

he has an example of using SoundCloud.

Pol Piella Abadia (guest): oh, nice.

Leo Dion (host): So,

Pol Piella Abadia (guest):
That is pretty cool.

Leo Dion (host): gotta, you gotta,
you gotta, you gotta starter

Pol Piella Abadia (guest): Nice.

I'll have a look.

Yeah, I'll have a look.

Amazing.

But yeah, there's, there's
some like projects out there.

I don't know if you've come
across and see terminal.

There's like a, it's a swift
package that you can, it simplifies

all of the changing colors and
making things like bold and stuff.

And you can also read like
the cursor position as well.

And you can like jump around,
you can move the cursor.

It's.

Pretty entertaining.

It's pretty cool, but your code
gets very messy very quickly

and it's very easy to kind

Leo Dion (host): does.

It does.

Yeah.

Yeah.

Yeah.

So, yeah, that's awesome.

So yeah, we've, we've got
to keep trading notes on

Pol Piella Abadia (guest):
yeah, absolutely.

Yeah.

I was going to say, give me, give
me updated with how you get on and

stuff like that, because I'd be
super interested to hear what you do

Leo Dion (host): And if you're
somebody who's also interested

listener, let us know in the notes.

We'd,

Pol Piella Abadia (guest): Absolutely.

Yeah.

Leo Dion (host): So anything
else before we close out?

Pol Piella Abadia (guest):
I don't think so.

Yeah, no.

Well, obviously thanks for having me.

Like I, yeah, I've been, as I
said before, I've been a fan of

the podcast and I got, yeah, I
met you in, in Turin as well.

And we, yeah, we spoke for a bit and
yeah, it's a pleasure to be here.

Really, really enjoyed it.

Leo Dion (host): Where
can people find you, Pol?

Okay.

Pol Piella Abadia (guest):
pretty much everywhere now.

I'm completely overwhelmed
with social media.

So you can find me on run
a newsletter called the...

Well, actually, there's one link
where you can find everything.

So you can either go to bento.

me slash poll, or you can go to a
little service that I have called poll.

link.

If you go to that, it will
show you all of my links.

So you can find me everywhere
there and whatever suits you,

whatever social media you're
on, you can like find me there.

I'll probably be, I'm not on blue
sky or threads in the other ones.

I think I am.

I think I have enough social
media now can't cope with anymore.

Leo Dion (host): So if you want
to find Pol's MySpace or AOL

instant messenger name, go there.

Thank you, Pol.

Really appreciate it.

Pol Piella Abadia (guest): Yeah.

Same.

Thank you so much for having me.

Leo Dion (host): People can find
me on, I'm still not used to saying

this X at Leo G Dion mass and I'll
at Leo G Dion dot C at C dot I am.

My company is bright digit.

You can find all my links there as well.

Thank you so much for joining
us for this episode and I look

forward to talking to you again.

Bye everyone.

Creators and Guests

Leo Dion
Host
Leo Dion
Swift developer for Apple devices and more; Founder of BrightDigit; husband and father of 6 adorable kids
Pol Piella
Guest
Pol Piella
Weekly articles on https://t.co/S5HQah0jDV | Curating the iOS CI Newsletter | Used to help build @BBCiPlayer | Speaking at https://t.co/fvrLNOJ4cC

Join our newsletter

checkmark Got it. You're on the list!
image of podcast supporter
Join 1 supporters
Mastodon © Bright Digit, LLC 2018