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

Option to use a different yaml file #144

Open
marianfoo opened this issue Jun 7, 2024 · 5 comments
Open

Option to use a different yaml file #144

marianfoo opened this issue Jun 7, 2024 · 5 comments
Labels
enhancement New feature or request

Comments

@marianfoo
Copy link

Is your feature request related to a problem? Please describe.

I´d like to run the ui5-linter for my Component. Out of the box this does not work because of the type: module in my ui5.yaml file. Because of this i think this is more a feature request then bug.

Recreate the problem:

git clone https://github.com/spreadsheetimporter/ui5-cc-spreadsheetimporter
cd packages/ui5-cc-spreadsheetimporter
ui5lint

Output when i run ui5lint:

⚠️  Process Failed With Error

Error Message:
Projects of type module have more than one source path

Error comes from https://github.com/SAP/ui5-project/blob/a085232514ebdd8ad11f5fd49323b0c0bb5c240b/lib/specifications/types/Module.js#L31

Describe the solution you'd like

I use the middleware ui5-middleware-ui5 to use the Component in my UI5 App, so use a special yaml file for this anyway ui5-serve.yaml change the type to application.

Most simple solution would that there would be a option so i can use the ui5-serve.yaml instead of the default ui5.yaml. I did not see the option in the cli yet.
Something like ui5lint --configFile ui5-serve.yaml

Additional context

I think i need to change my type in the ui5.yaml anyway, because application fits better to my project, right?
Either way, a option to change the default yaml file would be great

@marianfoo marianfoo added the enhancement New feature or request label Jun 7, 2024
@RandomByte
Copy link
Member

This is a very reasonable enhancement.

We could also add support for projects of type module. But from what I can see this still wouldn't help you since your ui5.yaml only refers to the build result and not the sources (which you would probably want to lint).

I think i need to change my type in the ui5.yaml anyway, because application fits better to my project, right?

I think this is yet another case where the Component type would be a good fit: SAP/ui5-tooling#45

Thanks for reporting!

@marianfoo
Copy link
Author

marianfoo commented Jun 7, 2024

Thank you for confirming the enhancement.

I know the issue and just now remember what I wanted to ask you at UI5con:
When is the Component Type coming? 😃
Would be perfect for 4.0 😉

@RandomByte
Copy link
Member

See SAP/ui5-tooling#45 (comment) 😉

@marianfoo
Copy link
Author

See SAP/ui5-tooling#45 (comment) 😉

Would be great to see it in 4.X :)
If you need any help or testing this feature just shout out

@matz3
Copy link
Member

matz3 commented Jun 10, 2024

Internal reference: CPOUI5FOUNDATION-855

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants