Closed johlju closed 1 year ago
This makes it easier to create a simple module that can be built and tested when answering No (default value) on all questions.
PS> New-SampleModule -DestinationPath '.' -ModuleType 'SimpleModule' -ModuleAuthor 'Johan Ljunggren' -ModuleName 'ExampleModuleDsc' -ModuleDescription 'My description.'
Will you use Git for source control?
[Y] Yes [N] No [?] Help (default is "N"):
Do you want to use Azure Pipelines to run the the build, test and or deploy pipeline?
[Y] Yes [N] No [?] Help (default is "N"):
Will you use Visual Studio Code as the code editor for the project?
[Y] Yes [N] No [?] Help (default is "N"):
Destination path: /Users/johlju/source
Create ExampleModuleDsc/source/
Create ExampleModuleDsc/source/Private/
Create ExampleModuleDsc/source/Public/
Create ExampleModuleDsc/tests/
Create ExampleModuleDsc/tests/QA/module.tests.ps1
Create ExampleModuleDsc/output/
Create ExampleModuleDsc/output/RequiredModules/
Create ExampleModuleDsc/build.ps1
Create ExampleModuleDsc/RequiredModules.psd1
Create ExampleModuleDsc/Resolve-Dependency.ps1
Create ExampleModuleDsc/Resolve-Dependency.psd1
Create ExampleModuleDsc/build.yaml
Create ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Create ExampleModuleDsc/source/ExampleModuleDsc.psm1
Create ExampleModuleDsc/README.md
Create ExampleModuleDsc/source/en-US/about_ExampleModuleDsc.help.txt
Create ExampleModuleDsc/CHANGELOG.md
If answering Yes on a question results in other questions to be asked, resulting in additional files will be added to the project.
PS> New-SampleModule -DestinationPath '.' -ModuleType 'SimpleModule' -ModuleAuthor 'Johan Ljunggren' -ModuleName 'ExampleModuleDsc' -ModuleDescription 'My description.'
Will you use Git for source control?
[Y] Yes [N] No [?] Help (default is "N"): Y
Name of your default branch (main):
Do you want to add configuration for GitVersion to handle automatic versioning for your project?
[Y] Yes [N] No [?] Help (default is "Y"):
Do you want to use the service CodeCov.io for code coverage reporting?
[Y] Yes [N] No [?] Help (default is "N"): Y
Will you use GitHub.com as the collaboration platform for the project?
[Y] Yes [N] No [?] Help (default is "N"): Y
Do you want to use Azure Pipelines to run the the build, test and or deploy pipeline?
[Y] Yes [N] No [?] Help (default is "N"): Y
What is the name of the GitHub owner (personal or organization account) that will publish the module? (MyOrgName):
Will you use Visual Studio Code as the code editor for the project?
[Y] Yes [N] No [?] Help (default is "N"): Y
Destination path: /Users/johlju/source
Create ExampleModuleDsc/source/
Create ExampleModuleDsc/source/Private/
Create ExampleModuleDsc/source/Public/
Create ExampleModuleDsc/tests/
Create ExampleModuleDsc/tests/QA/module.tests.ps1
Create ExampleModuleDsc/output/
Create ExampleModuleDsc/output/RequiredModules/
Create ExampleModuleDsc/.gitignore
Create ExampleModuleDsc/.gitattributes
Create ExampleModuleDsc/build.ps1
Create ExampleModuleDsc/RequiredModules.psd1
Create ExampleModuleDsc/Resolve-Dependency.ps1
Create ExampleModuleDsc/Resolve-Dependency.psd1
Create ExampleModuleDsc/build.yaml
Create ExampleModuleDsc/azure-pipelines.yml
Create ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Modify ExampleModuleDsc/source/ExampleModuleDsc.psd1 into temp file before copying to destination
Update ExampleModuleDsc/source/ExampleModuleDsc.psd1
Create ExampleModuleDsc/source/ExampleModuleDsc.psm1
Create ExampleModuleDsc/README.md
Create ExampleModuleDsc/source/en-US/about_ExampleModuleDsc.help.txt
Create ExampleModuleDsc/CHANGELOG.md
Create ExampleModuleDsc/GitVersion.yml
Create ExampleModuleDsc/.vscode/tasks.json
Create ExampleModuleDsc/codecov.yml
@raandree might you have some time to help review this? Would love your input if there is more to be done that I missed.
Merging #412 (02592c3) into main (2ac6eff) will decrease coverage by
1%
. The diff coverage isn/a
.:exclamation: Current head 02592c3 differs from pull request most recent head 80ba5d0. Consider uploading reports for the commit 80ba5d0 to get more accurate results
@@ Coverage Diff @@
## main #412 +/- ##
===================================
- Coverage 81% 81% -1%
===================================
Files 44 42 -2
Lines 2317 2248 -69
===================================
- Hits 1897 1835 -62
+ Misses 420 413 -7
Impacted Files | Coverage Δ | |
---|---|---|
Sampler/scripts/Set-SamplerTaskVariable.ps1 | 96% <0%> (-1%) |
:arrow_down: |
.build/tasks/SetPsModulePath.build.ps1 | ||
Sampler/Public/Set-SamplerPSModulePath.ps1 |
Thanks for merging this!
Pull Request
Pull Request (PR) description
Changed
SimpleModule
UseGit
- This parameter enables project files that helps with the use of Git for the project. The template will ask if Git should be used, default is No.UseGitVersion
- This parameter adds project files that helps with the use of GitVersion for the project. GitVersion is dependent on Git being used for the project. The template will ask if GitVersion should be used if the use of Git was chosen, default is No.UseCodeCovIo
- This parameter adds project files that helps with the use of CodeCov.io for the project. CodeCov.io is dependent on Git being used for the project. The template will ask if CodeCov.io should be used if the use of Git was chosen, default is No.UseGitHub
- This parameter adds project files that helps with the use of GitHb.com for the project. GitHub.com is dependent on Git being used for the project. The template will ask if GitHub.com should be used if the use of Git was chosen, default is No.UseAzurePipelines
- This parameter adds project files that enables the project to run the pipeline in Azure Pipelines (in Azure DevOps). The template will ask if Azure Pipelines should be used, default is No.UseVSCode
- This parameter adds project files that helps when using Visual Studio Code as the project code editor. The template will ask if Visual Studio Code should be used, default is No.build.yaml
will only contain tasks fromSampler.GitHubTasks
if template parameterUseGitHub
is set to true (the answer to the template question is Yes).RequiredModules.psd1
will only contain the moduleSampler.GitHubTasks
if template parameterUseGitHub
is set to true (the answer to the template question is Yes).UseGit
is false) the QA test that uses Git is removed for the generated filemodule.tests.ps1
.RequiredModules.psd1.template
since it is not direct requirement for any project. It will still be saved tooutput/RequiredModules
for a project as it is defined as a required module in Sampler's module manifest, and Sampler is still a required modul.Fixed
README.md.template
.about_ModuleName.help.template
and inmodule.template
.CodeCoverage
in the filebuild.yaml.template
. Fixes #359.Task list
build.ps1 -ResolveDependency
).This change is