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
Support Multiple Header Paths #459
Support Multiple Header Paths #459
Conversation
Generated by 🚫 Danger |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding this @adamkhazi. I have only one comment.
What about adding a new fixture project that contains targets with headers initialized with a string and with an array of strings? Since this is a user-facing feature, having the test there will help us detect breaking changes in the future.
Moreover, don't forget to update the documentation under the /docs
directory to reflect these changes.
Other than that, the code looks great.
1844919
to
e70706a
Compare
Codecov Report
@@ Coverage Diff @@
## master #459 +/- ##
==========================================
+ Coverage 92.11% 92.15% +0.03%
==========================================
Files 319 320 +1
Lines 16567 16650 +83
==========================================
+ Hits 15261 15344 +83
Misses 1306 1306
Continue to review full report at Codecov.
|
Resolves #354
Short description 📝
Add support to specify array of paths / glob patterns for headers such as the case below:
Solution 📦
Similar to the way multiple source file paths/glob patterns were implemented (#266). We can use
FileList
andExpressibleByStringLiteral
to expose public, private and project headers as either a String or Array of Strings. The originalFileList
used for sources was not reused as it containedcompilerFlags
which is specific to source files. A newFileList
containing only paths/glob patterns was created for use with headers. This wayFileList
can be potentially reused elsewhere.Implementation 👩💻👨💻
FileList
type alias fromSourceFilesList
and references to itFileList
withoutcompilerFlags
Headers
to use the newFileList
for public, private and project headersGeneratorModelLoaderTests
to verify newly supported cases workios_app_with_headers
fixture to support new array of strings case for headersios_app_with_headers
fixture targets buildTest Plan
tuist generate
inside theios_app_with_headers
fixture