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

Xcode 15 supporting #25

Merged
merged 4 commits into from
Sep 20, 2023
Merged

Xcode 15 supporting #25

merged 4 commits into from
Sep 20, 2023

Conversation

BarredEwe
Copy link
Owner

Added support for working with Xcode 15.

Xcode 15 does not give plugins permission to write to the project directory 🥲

As a quick solution, I can recommend writing in DerivedData.
To do this, remove the test_file_path parameter from the .prefier.yml file.

Now I'm trying to find another solution, but so far there are difficulties with this. To be honest, I'm not sure that it can be possible now: swiftlang/swift-package-manager#6814

@BarredEwe BarredEwe merged commit 898a4a9 into main Sep 20, 2023
2 checks passed
@markst
Copy link
Contributor

markst commented Feb 7, 2024

@BarredEwe what about supporting DERIVED_SOURCES_DIR like swift gen

output_dir: ${DERIVED_SOURCES_DIR}

https://github.com/SwiftGen/SwiftGenPlugin?tab=readme-ov-file#add-a-swiftgen-config

@@ -283,6 +279,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this a requirement to support? otherwise how do we get Xcode to pickup the generated PreviewTests in the build directory without creating a subclass:

final class MyPreviewTests: PreviewTests {

}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah scratch that. it has picked it up

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this a requirement to support? otherwise how do we get Xcode to pickup the generated PreviewTests in the build directory without creating a subclass:

final class MyPreviewTests: PreviewTests {

}

This is the easiest way to navigate to the generated tests that I have found. Of course, there is an option without creating a subclass - run the tests and then you can use them to go to the file.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah scratch that. it has picked it up

You're right

@BarredEwe BarredEwe deleted the xcode_15_supporing branch February 14, 2024 09:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants