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

allow additional includes to be specified in the parse config #105

Merged
merged 4 commits into from
Jul 10, 2024

Conversation

stijnveenman
Copy link
Contributor

implements part of #101
This PR adds support for additional includes to be passed to the preprocessor.
This in turn adds support for zmk-helpers as its path can be added to the parser config as follows

parse_config:
    zmk_additional_includes:
      - "zmk-helpers/include"

While this does not parse the west.yaml, i think it should be sufficient for most, if not all, use cases. As most configurations will not have many additional includes.

To fully implement #101 the workflow also has to be updated to pull west modules. I plan on picking this up seperately

@caksoylar
Copy link
Owner

Thanks for the PR! It looks pretty good on an initial glance, I'll properly review it when I am home next week.

@stijnveenman
Copy link
Contributor Author

Quickly fixed formatting and linting. Not sure what a straightforward way to fix the too many arguments warning is.
As during the constructor of DeviceTree we need the additional includes to call _preprocess. Otherwise we would have to pass the entire config object. Happy to change this if you have any preference

@caksoylar
Copy link
Owner

Don't worry about that one, I usually add a disable comment if it will be too inconvenient to obey it.

Copy link
Owner

@caksoylar caksoylar left a comment

Choose a reason for hiding this comment

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

Looks pretty much perfect, thanks again.

CONFIGURATION.md Outdated Show resolved Hide resolved
@caksoylar caksoylar merged commit dfd32fd into caksoylar:main Jul 10, 2024
1 check passed
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.

2 participants