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

Add PlatyPS to required modules #715

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

Borgquite
Copy link
Contributor

@Borgquite Borgquite commented Jul 30, 2024

Pull Request (PR) description

As discussed in #714, adding PlatyPS to required modules in an attempt to resolve build errors

This Pull Request (PR) fixes the following issues

Task list

  • Added an entry to the change log under the Unreleased section of the file CHANGELOG.md.
    Entry should say what was changed and how that affects users (if applicable), and
    reference the issue being resolved (if applicable).
  • Resource documentation added/updated in README.md.
  • Resource parameter descriptions added/updated in README.md, schema.mof and comment-based
    help.
  • Comment-based help added/updated.
  • Localization strings added/updated in all localization files as appropriate.
  • Examples appropriately added/updated.
  • Unit tests added/updated. See DSC Community Testing Guidelines.
  • Integration tests added/updated (where possible). See DSC Community Testing Guidelines.
  • New/changed code adheres to DSC Community Style Guidelines.

This change is Reviewable

@Borgquite
Copy link
Contributor Author

@johlju Sorry - not sure why this is failing?

@johlju
Copy link
Member

johlju commented Jul 30, 2024

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@johlju
Copy link
Member

johlju commented Jul 30, 2024

Very strange - not sure either, kicked off the pipeline again. It got GitVersion 6 event if it says it should install v5. 🤔

@johlju
Copy link
Member

johlju commented Jul 30, 2024

Seems to work now, I can't see any errors in the build phase. Seems to work with adding PlatyPS.

This should also update the conceptual help so we should no longer need to have the individual .help.txt for the resources. They are generated automatically in the top en-US folder under ./output. 🤔 Should be less to maintain hopefully?

@johlju johlju added the waiting for author response The pull request is waiting for the author to respond to comments in the pull request. label Jul 30, 2024
Copy link

codecov bot commented Jul 30, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98%. Comparing base (bdde66f) to head (0afcf32).
Report is 3 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@         Coverage Diff         @@
##           main   #715   +/-   ##
===================================
  Coverage    98%    98%           
===================================
  Files        25     25           
  Lines      3475   3512   +37     
===================================
+ Hits       3406   3443   +37     
  Misses       69     69           

@johlju
Copy link
Member

johlju commented Jul 30, 2024

But there seems to a problem with this module, maybe because there is a docs folder in the helper module the auto-doc creates this file?

WARNING: Each file must end with a new line.
WARNING: D:\a\2\s\output\ActiveDirectoryDsc\6.6.0\en-US\ActiveDirectoryDsc.Common.psm1-help.xml does not end with a new
 line.

Solution 1. Moving the docs folder to source/WikiSource -each file add YAML Front Matter (markdown metadata) property Category and set it to Helper command. I think that will make the sidebar be generated with a section Helper command with the .md files that has the Category set to the same. Not tested though.

Solution 2. If the all common command can be made public we can just add a source/Public folder (command not called by resources can be in source/Private) then add each command with its comment-based help to individual script files. This will make the auto-doc automatically generate the docs on each build and automatically deploy it. This will remove the helper module and the resources must import ActiveDrectoryDsc instead. The unit tests must also be changed for the move commands to test the command in the built module.

Solution 3. Move the helper module to it's own repository similar to how DscResource.Common is seperated. Then add it the same way as DscResource.Common is used. Moving relevant commands to DscResource.Common is also an option. 🤔

Guessing solution 1 is easiest - at least moving away the 'docs' folder so it is not part of the generated module. 🙂

@Borgquite
Copy link
Contributor Author

@johlju OK - probably not something I can spend any more time on, sorry (doing this on company time). I'll leave this here in case someone else can pick it up!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting for author response The pull request is waiting for the author to respond to comments in the pull request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build process missing 'Get-MarkdownMetadata' cmdlet
2 participants