Social networks come and go, and I really like posting social media. In this section, I’m trying to mirror the stuff I post to social networks.
6 December 2019
Tagged with: swift
Just a few days ago I learned about the argument to generate Xcode projects from Swift packages that don't contain additional files:
swift package generate-xcodeproj --skip-extra-files
The generated Xcode project took a lot of time to open because it's a monorepo with other projects and I didn't know why. I'm very glad that I found it because Xcode was significantly slow indexing things.
I scratched my social itch again by installing Twitter and scrolling through it compulsively. Damn, how is it possible that social networks make us so addicted to their sugar?
Best way to structure one's ideas? Open a document and start dumping thoughts off your brain. I started doing that this morning to come up with a vision for mobile development at Shopify.
A new Coldplay album was released today! I'm a huge fan of this band since they released "Viva la vida", a song that means a lot to me and that keeps giving me that boost of energy when I need it. The song below is from the new album.
A challenge I often face when working at Shopify and in open source projects is that we engineers have the tendency of answering to complexity with complexity in a different language. The mindset that I adopt and foster in my team is seeing complexities and opportunities for streamlining things and making them easier.
These days's I'm working on using the technology mindfully to support my life goals instead of wasting my time, and most importantly attention, on things that don't help me pursue those goals. As I mentioned yesterday, I started by not wasting time catching up with the unceasing amount of activity that we find nowadays in the social networks and in particular, in our industry.
I feel more focused and energized and I'm funneling that into my passions, like Tuist.
Today I worked for a bit on Galaxy, a service for Tuist's users to provide caching and speed up their builds. I'm focusing on the backend at the moment, which is for instance a Rails app with GitHub's Primer design system
20 November 2019
Tagged with: tuist
Seeing users of Tuist talking about their experience using the tool as something fun and very useful is really amazing. What's even better is seeing Bloomberg, SoundCloud, and MyTaxi giving Tuist a try to make scaling up their projects and easy task.
I think one of the reasons why companies might move slower than what they could is because they have people that are excellent at one thing but that see other domains as areas to which they are not capable of contributing.
That's just a mental barrier that we are all imposing to us. We are engineers, and despite other domains feeling uncomfortable because we don't know them that much, we should push ourselves out of our comfort zone.
I uninstalled work and social media related apps from my phone and I have no words to describe the peace that that creates in my mind. Interestingly, I’m more connected, but not with the world, with myself. I don’t feel the need of having to keep us with the latest articles, open source projects, or talks people are talking about. Moreover the feeling of having to craft a thought-provoking piece or software to craft people’s attention is fading away. That helps me have more focus on the things that I like doing, which in the context of software, it’s Tuist.
I finally found some time to write a blog post about Tuist's 0.19.0 release. Besides a handful of minor improvements and fixes, it adds support for watch and sticker apps and extensions. My plan now is to focus on Galaxy, a service that will take Tuist to a whole new level by providing cache and insight to Tuist's users. It's exciting times for the project!
In case anyone faces the need of having to compile a Swift Package with an stable ABI interface, passing the
-emit-module-interface argument is not enough. Below there's an example of the command that we are using to compile Tuist's
--product ProjectDescription \
--configuration release \
-Xswiftc -enable-library-evolution \
-Xswiftc -emit-module-interface \
-Xswiftc -emit-module-interface-path \
With that generated
.swiftinterface, consumers of the framework should be able to compile it with newer Swift versions.
I finished adding a new section to my website, photos. The new section replicates Instagram but without all the attention-driven features like likes or views. The idea is having a place where I can share my photos publicly without giving them to a third-party company.
We are exploring the idea of adding an edit command to Tuist. The command would create and open a temporary Xcode project o edit your project. After finishing the edition, Tuist would prompt the user if they would like to generate the projects if changes have been detected.
I think is another step towards decoupling the generated projects from Tuist. The projects will have no knowledge about Tuist.
It's great to see the ideas that I dream for to slowly become real. Today I just merged a PR into Tuist that makes the definition of projects just a one line. How cool is that? This is something that I always believed that Tuist would end up doing and here we are. It's simple, convenient, and most importantly, makes extending projects a task in which everyone can participate.
The PR to add support for Linux to Tuist is coming along very well. The library is already compiling and running the tests in a Linux environment. There's just one more thing missing, listing all the tests in the
LinuxMain.swift. Once we are done with it, the pull request should be ready to be merged.
What I find great about this new feature landing to the project is that developers will be able to build tools that can run in a Linux environment. The question that pops in my mind now is: does it make sense to support running Tuist on Linux?
7 November 2019
Tagged with: macos, ci
This is a note to self because I've been searching for the commands below so many times in the last months. They serve to know how much disk space is available in a macOS environment, and how much disk space each folder takes:
df -h: Disk space available and used.
du -sh ~: Disk space taken by a folder.
I have just published a new version of XcodeProj, 7.3.0 that removes the Swift Package Manager as a dependency, making it possible to consume the package, and extends a utility class that generates base build settings to support app extensions.
Support for Watch apps is coming along to Tuist. Kas did a great job at extending the convenience of Tuist's DSL to the definition of watch apps too. He even implemented a check to ensure that the bundle identifier of the companion extension follows the right convention
One of the terms that I'm trying to avoid lately is scale. I think is a vague term that leaves you wondering what it means. It's like saying that something is good or bad. Good in the eyes of who? Or bad in regards to what criteria? I'd rather talk in terms of problems and how to tackle them. In the context of software development, we can talk in terms of maintenance costs, interdependency between in code and between team, the testability or extensibility of the code. Those are more concrete examples that give the people that we talk to or the audience of our talks a better sense of what we are talking about.
For those of you who ran into an issue with expired certificates in macOS and can't find installers of older macOS versions, this tool is just gold. It saved me some time wandering around the internet to find the link.e
27 October 2019
Tagged with: web, a11y
I can say I'm new to web development. Over the last months I've been playing a lot with frameworks, tools and programming languages that are mostly used in web development. This website for instance is developed with Gatsby & React.
I decided to spend some time this morning to revisit the accesibility of the website and make sure that all the content that I make available is accessible by anyone. Firefox has great tooling built-in to assess the accessibility of your website. Let's see what I find out and the areas of improvements.
My relationship with the social networks is a love & hate relationship. I'm again pondering the idea of giving up social networks. The reasons? Well... the same as always. I keep falling into the trap of seeking recognition and approval by the community and the people that follow my work. What's wrong with that? That instead of doing things for the sake of being motivated, I do it to prove things or show off things to people, and I don't like having that attitude.
Just as a note to self, the following one-line Docker command is very useful to build/test Swift packages in a Docker container:
docker run --rm \
--volume "$(pwd):/package" \
--workdir "/package" \
/bin/bash -c \
"swift package fetch && swift test --build-path ./.build/linux"
25 October 2019
Tagged with: tuist
I'm incredibly excited to start building Galaxy, a web app for Tuist projects that provides teams with insights that help them make informed decisions about the project structure. Just recently Apple announce a framework to collect metrics from your apps, which is great to optimize things in your apps, but what about projects? Teams don't know how many warnings their builds are throwing, the number of modules, the size of them... What if a developer introduced a regression in build times, who is going to catch that on a PR unless there's a third-party element that keeps track of that information, compares, and alerts you if something is very bad.
One of the most bitter moments when I got very into the iOS community was realizing that very admired community members completely refused to debate opinions other than theirs. Some even tried to hurt me when they perceived my opinions as a risk for the idolatry they had been working for years.
I decided to distance myself from such a toxic environment and now in hindsight I think it was a great decision. Now I can see all of it from outside.
13 October 2019
Tagged with: indie web
It feels so great being in control of the content that I produce and decide on how I'd like it to be presented on my website. I'm considering adding a gallery section akin to Instagram to share photos taken from my phone.
But before that, I'd like to build an app to write and share posts. Right now I'm writing this from an iOS Git client and the process is not very straightforward.
What does working on paid product would mean for Tuist, a project some companies depend on and that I've been maintaining for the last 3 years? I'd still maintain it, but it will no longer be my main priority. I'll develop features that support my work and enable other developers to contribute to Tuist to support their projects too.
Tuist will be to my projects what Ruby on Rails is to Basecamp.
Most of my career I've invested a lot of time into open source, which is great from the altruistic point of view, but this morning I was pondering if it'd make sense to invest all that time into building useful products that I can sell to developers. At the end of the day, it's money what we need for living. Open source has many positive things, but it also has frustrations and challenges that are tough to go through when it's your free time what you need for it.
9 October 2019
Tagged with: swift
TIL from Vytis, release engineer at Zalando, that
XCTest creates an instance of
XCTestCase per method, and for that reason if the instance variables of the class are not set to
nil in the
teardown method they remain in memory until the execution of the tests suite finishes.
9 October 2019
Tagged with: opensource
I really miss having an iOS app to post entries in the website journal. Every time I do it, I have to create a folder in the repository with the unix timestamp as the name, a
post.mdx file, add the content to it, and then commit and push the changes.
Although not very inconvenient, I'd like to be able to do it on the go. Pick up my phone, open an app, write what I want to share, and hit share. I did some groundwork to start building the app but I couldn't find time lately to work on it.
I really like the process of defining abstractions to make things easier for developers.
Devising, and implementing such abstraction for iOS developers is what led me to build Tuist.
Developers keep comparing Tuist with XcodeGen saying that Tuist is a limited version of XcodeGen.
It shares with XcodeGen the project generation,
but those limitations are thoughtfully designed to make iOS developers life easier.
Instead of translating concepts from XcodeProj domain to a YAML domain,
Tuist takes the opportunity to simplify most intricacies,
leaving the user with a beautiful declarative API that defaults to some pre-defined conventions.
I'm looking forward to keep pushing the abstraction idea beyond project generation,
and a bit sad that I can't put more time into it.
If I just got Shopify to use it.
A few years ago,
I called myself iOS developer.
I felt very comfortable with the platform and did not see myself developing for a platform other than iOS,
or a programming language other than Swift.
and nowadays I find myself doing frontend development,
developing command line tools,
and implementing a web API with Rails.
Not only that,
I also like designing the user interface of the software that I develop.
I learned that software is more than just writing some code,
putting it on a GitHub repository,
and creating some hype around it.
In order for users to love our craft, the software needs an identity and tell a story.
That's why I worked on designing an implementing a website for Tuist;
a website where we could share those stories with users.
We also worked on writing up documentation that helped users understand the motivations behind the tool,
and how to contribute to it if they are interested in doing so.
Adding dark mode to a website is the most bike-shedding activity but damm it! I like like doing it a lot.
After a handful of hours debugging a FOUC content on this Gatsby website, and even opening an issue on the theme-ui repository, I found out what was the problem. I was using a
<body> tag inside another
<body> tag. That caused the browser to apply styles after having already loaded most of the content.
The advantage of owning your content, is that you can decide its format. I just added support for inlining code snippets:
let message = "Hello world"
23 September 2019
Tagged with: life
Last Saturday, we celebrated what I can consider one of the happiest days in my life, my wedding with María José. Being surrounded with family and friends from Spain and Berlin, all of us celebrating love together is something that I can't describe with words. I wanted to talk to everyone, telling them how happy I was to celebrate such important moment with them. María José was so beautiful. She made me feel very nervous when I saw her coming with her father.
20 September 2019
Tagged with: design, web
If there's one craft that I'd like to get better at, that's desining and implementing beautiful web interfaces. I look at interfaces like GitHub, NextJS, or Stripe and I wonder what's needed to be there. I think all it takes is observations and imitation.
I'm working on the generation and distribution of a design system's icons to iOS and Android apps.
This not-so-difficult task showed me a core difference between the Android and iOS build systems:
iOS: The inputs of its build process are static: x sources and y resources will be used and they need to be part of the target. As a consquence, I got a lot of pushback from iOS developers that disagreed with having all the icons as part of their project target. Why am I having all those icons if I'm not using then?
Android: Conversely, Gradle is more dynamic and supports manipulating the build elements along the process. That makes it possible to shrink unused resources by just setting a flag to true. There was no pushback in this platform because developers trust the build system on doing its job.
And all of that made me think about Tuist,
which brings some dynamism to the iOS ecosystem by generating the project dynamically.
After a long time hearing about Cloudflare,
I enabled it on my webiste to be able to serve web assets faster with their CDN network and caching.
I have to say the configuration process was very straightforward,
and that I was fascinated by all the services that they provide with the basic idea of a web proxy.
I couldn't have imagined how stressful organizing a wedding will be. Mine is in 3 days and it seems there's always something to be organized. Hopefully everything will turn great and we'll have a wonderful day surrounded with family and friends.
18 September 2019
Tagged with: life
One of the things that I'm struggling to become better at is not letting things around me make me feel outraged or angry. Why? Because anger and outrage are not worth my energy. Here are some recent examples:
- Wedding organization turning into a complete chaos a week before because our wedding planner hasn't organized the work well since we started working with her a few months ago.
- Comments on PRs that question everything but without proposing anything at all. Just inthe mood of that's bad, that other line too, what about this? How do you dare to do that?
Today I just read this blog post about Internet relying on the work that many people do in the open for free. Two thoughts pop in my mind:
- Wow. 20 years maintaining such a successful and robust project is remarkable. Nowadays, developers are seeking new projects frequently to keep feeding their need of recognition. I fall a bit in the latter group, but with Tuist I'm learning to put passion upfront and forget about the rest.
- It's really bad that most companies don't give back for the value that they receive from the tools that they use for free. cURL is an example, but certainly not the only one. It's great to see GitHub helping with sponsors, but we need to raise more awareness agains this unbalanced open source economy.
I started XcodeProj as a building block for Tuist and around 3 years later the library continues to evolve and serve as an API to Xcode projects in many different open source projects. I'm so glad of having put that seed and help all those projects and companies using it.
The last days I've been working on Angle, a macOS app that I'm developing with friends that eases and speeds up the process of trying out changes introduced to an iOS app. It's as easy as clicking a link, and the tool will make sure that the environment is ready to open it, and then launch it in a matter of seconds.
We are working on some final polishing to make sure the app works smoothly without bugs that impoverish the user experience. Can't wait to share more about it!
13 September 2019
Tagged with: tuist
TIL is not a good practice to format the output of a process when the terminal is not interactive or the user hasn't indicated so. For instance, Swift's Process class is not seeing as interactive by the underlying command.
13 September 2019
Tagged with: tuist
Pondering the idea of kicking off a second milestone in the evolution of Tuist, providing a standard CLI for Xcode projects. I'm considering introducing a new manifest file type,
Tasks.swift, where developers can define what's runnable, buildable, testable, and releasable.
I just came across three interesting Swift libraries that I might use at some point. The downside of the Swift Package Manager being decentralized is that is hard to find hidden gems through Github's gems:
- Bouncer: A command line argument parser.
Execute shell command and get output. Simple and robust.
Swift cli spinner. Simple and fully customizable.
12 September 2019
I added a micro blog section to my website using this Gatsby theme that I developed for Tuist. Why am I doing this when I could be publishing those posts on Twitter? I'll continue posting on Twitter, but I want to own the content that I share on the Internet. Twitter, like Facebook or Medium, might have a turn in their platform and put the content behind a wall.
12 September 2019
Tagged with: open source