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

feat: resolve metadata type using file extension #750

Merged
merged 12 commits into from
Jan 16, 2024

Conversation

scolladon
Copy link
Owner

@scolladon scolladon commented Jan 3, 2024

Explain your changes


Allow to resolve metadata type using the file extension instead of the folder when possible.

Fallback is to use the folder extension for those types:

  • LightningWebComponent
  • StaticResource

Does this close any currently open issues?


closes #642 #350

  • Jest tests added to cover the fix.
  • NUT tests added to cover the fix.
  • E2E tests added to cover the fix.

Copy link

codecov bot commented Jan 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (e324f00) 100.00% compared to head (43792fa) 100.00%.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #750   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           36        37    +1     
  Lines         1003      1021   +18     
  Branches       100       104    +4     
=========================================
+ Hits          1003      1021   +18     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@scolladon scolladon marked this pull request as ready for review January 5, 2024 13:17
@scolladon scolladon force-pushed the feat/resolve-metadata-type-on-extension branch from 79bd304 to 4f99903 Compare January 5, 2024 14:54
@scolladon
Copy link
Owner Author

Hi @fedegiust, @jverelst & @jjulicher !

We have a first working implementation of the metadata detection based on the extension first !

Could you please help us in validating this feature ?

If you are interested in the spec it is written here.
If you think we can add more cases feel free to suggest !

The code currently handles all the special cases we have found so far. Even the one when we have the same extension but not the same metadata type because it is not contained in the same folder (one of the most tricky to make work with all the other cases)

In order to test it locally, you can follow those steps and install this PR.

Let us know, we will merge it soon and ship a new release asap

@scolladon scolladon force-pushed the feat/resolve-metadata-type-on-extension branch 3 times, most recently from df486c7 to d29105a Compare January 12, 2024 17:16
Copy link
Collaborator

@mehdicherf mehdicherf left a comment

Choose a reason for hiding this comment

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

@scolladon As discussed, let's include this one (and #740 ) in a release candidate, to make it easier to test it extensively 😃

@scolladon scolladon force-pushed the feat/resolve-metadata-type-on-extension branch from d29105a to 43792fa Compare January 16, 2024 12:19
Copy link

codeclimate bot commented Jan 16, 2024

Code Climate has analyzed commit 43792fa and detected 0 issues on this pull request.

View more on Code Climate.

@scolladon scolladon merged commit eb66cfc into main Jan 16, 2024
22 of 23 checks passed
@scolladon scolladon deleted the feat/resolve-metadata-type-on-extension branch January 16, 2024 12:37
Copy link

Shipped in release v5.35.0.
You can install the new version using the version number or the latest-rc channel

$ sfdx plugins:install sfdx-git-delta@latest-rc
$ sfdx plugins:install [email protected]

Happy incremental deployment!

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.

Detect metadata type based on file extension instead of directory
2 participants