Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Use xcodes instead of xcversion #440

Closed
4 tasks
defagos opened this issue Jul 10, 2023 · 1 comment
Closed
4 tasks

Use xcodes instead of xcversion #440

defagos opened this issue Jul 10, 2023 · 1 comment
Labels
tooling Issues related to the tools we use

Comments

@defagos
Copy link
Member

defagos commented Jul 10, 2023

As a developer I would like to adopt the new xcodes standard for Fastlane. This is currently not possible for Xcode beta releases.

Acceptance criteria

  • The Fastfile has been updated to use xccodes instead of xcversion.
  • Beta releases are supported.

Context

We already migrated to xcodes in the past (see #245) but sadly beta versions are currently not supported with this setup:

  • Versions provided to xcodes command-line tool are exactly compared to version extracted from local installation information, there is currently no semantic versioning support. If an Xcode beta was installed with xcodes comparison fails since extracted installation metadata is exhaustive and does not match the required information. If an Xcode beta was installed in another way (e.g. xcinfo) then matching will work as the extracted installation metadata is less rich and passes the check (only the major / minor / patch versions are checked, basically).
  • The xcodes Fastlane plugin fails to support betas. Xcodes interprets versions as exact but parses only 15 Beta 3, for example, which fails Ruby Gem versioning validation. This is a regression from xcversion since semantic versioning was supported.

Workaround

A workaround is to use xcversion during the Xcode beta phase and xcodes for releases. We can provide the same .xcode_version file to both with ~> 15.0 as version during the Xcode 15 beta phase.

Pillarbox developer tool setup should not be modified as the long-term goal is to use xcodes.

A companion issue to support Gem:Version beta version format has also be opened, with a dedicated PR.

Next steps

Of course this is a short-term workaround, as xcversion is deprecated and likely to be removed someday. Some ideas:

  • Monitor the already reported issue.
  • If we want to be compatible with semantic versioning we could maybe add support directly to xcodes. This would ensure that xcodes can be truly a replacement for xcversion.

Tasks

  • Check status of the issues listed above.
  • Upgrade xcodes if the PR submitted in Add floating version support to xcodes #442 has been approved.
  • Revert to xcodes in Fastfile.
  • Check that the local .xcode_version file is correctly configured.
@defagos defagos added the tooling Issues related to the tools we use label Jul 10, 2023
@defagos defagos changed the title Use xcodes instead of xcversion Use xcodes instead of xcversion Jul 10, 2023
@defagos
Copy link
Member Author

defagos commented Jul 14, 2023

We can still use .xcode-version and 15 as a version provided there is only a single beta of Xcode 15 installed.

@waliid waliid closed this as completed Jul 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tooling Issues related to the tools we use
Projects
Status: ✅ Done
Development

No branches or pull requests

2 participants