R.swift icon indicating copy to clipboard operation
R.swift copied to clipboard

Fix unable to build using Xcode Cloud

Open Keitaro0226 opened this issue 2 years ago • 0 comments

Fixes https://github.com/mac-cain13/R.swift/issues/862

The RswiftCore implementation can be found at try contents.write(to: outputURL, atomically: true, encoding: .utf8) is used to write the generated code; if atomically is true, the content is written to an intermediate file and then moved to the outputURL. However, XocdeCloud does not seem to allow writing outside of the pluginWorkDirectory, even for temporary files created by the Foundation framework.

The easiest way to make Build succeed on Xcode Cloud seems to be to change "atomically" to false.

What do you think about changing it?

References https://github.com/liamnichols/xcstrings-tool/pull/36

https://zenn.dev/hiragram/articles/49f178b58a36bc (Written in Japanese)

Keitaro0226 avatar Jan 07 '24 10:01 Keitaro0226