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

Working with multiple targets #177

Closed
hactar opened this issue Apr 16, 2020 · 3 comments
Closed

Working with multiple targets #177

hactar opened this issue Apr 16, 2020 · 3 comments

Comments

@hactar
Copy link
Contributor

hactar commented Apr 16, 2020

We have an app which as multiple targets: The app, the iMessage target and the Apple watch target. Each is in its own subfolder, and each has its own localizable.strings file. If I run bartycrouch on our project, it adds all strings to all localizable.strings file, independent of target. So the iMessage localizable.strings file now contains all strings from the app target too, and vice versa.

How do I set up bartycrouch so it does not do that, or so that runs once per target folder, so that the strings are not mingled?

Thanks for any insights...

@Jeehut
Copy link
Member

Jeehut commented Apr 17, 2020

@hactar I think this is related to #166, please see this comment of mine where I basically suggest that we make the .bartycrouch.toml configuration file path configurable, at the moment it's always assumed to be at the current location. But if you were able to specify it's location, you could simply create one .bartycrouch.toml file for each of your targets (within their directories) and run bartycrouch 3 times, each time specifying a different config file path. That should solve your problem as well.

Note that @ndreisig said he will try to implement this on this weekend, so either wait for him to implement it or do it yourself (and best mention him so he knows). I think it's a good starter contribution task. :)

@hactar
Copy link
Contributor Author

hactar commented Apr 17, 2020

Thanks @Jeehut , had the same idea and tried it over night, works well. I now simply have 1 config file per target folder. As the config files are better when they are slightly different (watch doesnt need code step, watch extension doesnt need interface step) I'd say this is the ideal solution. Will close as I consider it solved :). If this is the suggested solution feel free to comment and I'll contribute some documentation.

@Jeehut
Copy link
Member

Jeehut commented Apr 24, 2020

This was fixed via #181 and released in 4.2.0 and should be available via Homebrew soon. 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants