mac-cain13 / R.swift

Strong typed, autocompleted resources like images, fonts and segues in Swift projects
MIT License
9.5k stars 764 forks source link

How to use SPM plugin and select generators? #868

Closed jalone87 closed 10 months ago

jalone87 commented 12 months ago

Hello, in the documentation it's said i can select the generators i want to use by passing --generators image,string in the build phase. But when integrating Rswift with the SPM Plugin, there is no such a build phase. So where are we supposed to pass the parameters?

Thank you

charlie-dev-ios commented 10 months ago

Hi, @jalone87

The Run Build Tool plugin probably cannot take arguments from Apps at the moment. Also, the plugin does not have the ability to import configuration files such as .swiftlint.yml, so unfortunately there is no way to customize its behaviour.

Another, less straightforward, way of doing this is to implement your own plug-ins, which may give you what you expect. Here is a sample of my own implementation.

https://github.com/charlie-dev-ios/CustomRSwiftPlugin

Please let us know if there are other alternatives or features you plan to implement that will solve this.

jalone87 commented 10 months ago

Thank you @charlie-dev-ios , i ended up not using the plugin sadly, I was also having other issues and using the system wide installation was just cheaper to implement