Ressources/FRPSUGModuleTemplate/plasterManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<plasterManifest
  schemaVersion="1.1"
  templateType="Project" xmlns="http://www.microsoft.com/schemas/PowerShell/Plaster/v1">
  <metadata>
    <name>FRPSUG-ModuleTemplate</name>
    <id>430104ca-eec4-4602-bb82-83a786ee5d5b</id>
    <version>0.0.1</version>
    <title>Full Module Template For FRPSUG</title>
    <description>Full Module Template For French PowerShell and DevOps User Group</description>
    <author>Laurent LIENHARD</author>
    <tags>Module, Complete, FRPSUG</tags>
  </metadata>
  <parameters>
    <parameter name='ModuleName' type='text' prompt='`r`nEnter the name of the module' />
    <parameter name='ModuleDescription' type='text' prompt='`r`nEnter a description of the module (required for publishing to the PowerShell Gallery)' />
    <parameter name='AuthorName' type='user-fullname' prompt='`r`nEnter your full name' />
    <parameter name='AuthorEmail' type='user-email' prompt='`r`nEnter your email address' />
    <parameter name='ModuleVersion' type='text' prompt='`r`nEnter the version number for the module' default='0.0.1' />
    <parameter name='Company' type='text' prompt='`r`nEnter the company name' default='None' />
 
  <parameter name='ModuleFolders' type = 'multichoice' prompt='`r`nPlease select folders to include' default='0'>
    <choice label='&amp;Functions' value='functions' help='Adds a function folder to module'/>
    <choice label='&amp;Classes' value='Classes' help='Adds a Classes folder to module'/>
    <choice label='&amp;Enums' value='Enums' help='Adds a Enums folder to module'/>
    <choice label='&amp;Ressources' value='Ressources' help='Adds a Ressources folder to module'/>
  </parameter>
 
 <parameter name='UnitTests' type = 'choice' prompt='`r`nAdd UnitTests Folder' default='0'>
    <choice label='&amp;Yes' value='Yes' help='Add UnitTests Folder.'/>
    <choice label='&amp;No' value='No' help='No UnitTests support'/>
  </parameter>
 
  <parameter name='Editor' type='choice' default='1' store='text' prompt='`r`nWhich editor do you use'>
    <choice label='&amp;ISE' help='Your editor is PowerShell ISE.' value='ISE'/>
    <choice label='Visual Studio &amp;Code' help='Your editor is Visual Studio Code.' value='VSCode'/>
    <choice label='&amp;None' help='No editor specified.' value='None'/>
  </parameter>
 
  <!-- CI/CD -->
    <parameter name='CICD'
               type='choice'
               default='2'
               store='text'
               prompt='Do you want to include CI/CD support?'>
      <choice label='&amp;AppVeyor'
              help='Adds an AppVeyor yaml file.'
              value="AppVeyor"/>
      <choice label='Azure &amp;Pipelines'
              help='Adds an Azure Pipelines yaml file.'
              value='AzurePipelines'/>
    <choice label='Git&amp;Hub Actions'
              help='Adds a GitHub Actions workflow file.'
              value='GitHubActions'/>
      <choice label='&amp;GitLab CI'
              help='Adds a GitLab CI yaml file.'
              value='GitLabCI'/>
      <choice label='&amp;None'
              help='No license specified.'
              value='None'/>
    </parameter>
  </parameters>
 
  <content>
    <message>____________________________________</message>
    <message>`r`n-> Creating your root folders for module : ${PLASTER_PARAM_ModuleName}</message>
    <message>____________________________________</message>
    <file source='' destination='${PLASTER_PARAM_ModuleName}' />
 
    <message>`r`n-> Creating module manifest</message>
    <newModuleManifest destination='$PLASTER_PARAM_ModuleName\${PLASTER_PARAM_ModuleName}.psd1' moduleVersion='$PLASTER_PARAM_ModuleVersion' rootModule='.\${PLASTER_PARAM_ModuleName}.psm1' author='$PLASTER_PARAM_AuthorName' companyName='${PLASTER_PARAM_Company}' description='$PLASTER_PARAM_ModuleDescription' encoding='UTF8-NoBOM'/>
 
    <message>`r`n-> Creating your source code folders </message>
    <file source='' destination='${PLASTER_PARAM_ModuleName}\Sources\Functions\Private' condition='$PLASTER_PARAM_ModuleFolders -contains "functions"' />
    <file source='github\gitkeep' destination='${PLASTER_PARAM_ModuleName}\Sources\Functions\Private\.gitkeep' condition='$PLASTER_PARAM_ModuleFolders -contains "functions"' />
    <file source='' destination='${PLASTER_PARAM_ModuleName}\Sources\Functions\Public' condition='$PLASTER_PARAM_ModuleFolders -contains "functions"'/>
    <file source='github\gitkeep' destination='${PLASTER_PARAM_ModuleName}\Sources\Functions\Public\.gitkeep' condition='$PLASTER_PARAM_ModuleFolders -contains "functions"'/>
    <file source='' destination='${PLASTER_PARAM_ModuleName}\Sources\Classes' condition='$PLASTER_PARAM_ModuleFolders -contains "Classes"' />
    <file source='github\gitkeep' destination='${PLASTER_PARAM_ModuleName}\Sources\Classes\.gitkeep' condition='$PLASTER_PARAM_ModuleFolders -contains "Classes"' />
    <file source='' destination='${PLASTER_PARAM_ModuleName}\Sources\Enums' condition='$PLASTER_PARAM_ModuleFolders -contains "Enums"' />
    <file source='github\gitkeep' destination='${PLASTER_PARAM_ModuleName}\Sources\Enums\.gitkeep' condition='$PLASTER_PARAM_ModuleFolders -contains "Enums"' />
    <file source='' destination='${PLASTER_PARAM_ModuleName}\Sources\Ressources' condition='$PLASTER_PARAM_ModuleFolders -contains "Ressources"' />
    <file source='github\gitkeep' destination='${PLASTER_PARAM_ModuleName}\Sources\Ressources\Ressource1\.gitkeep' condition='$PLASTER_PARAM_ModuleFolders -contains "Ressources"' />
 
    <message>`r`n-> Creating your github files </message>
    <templateFile source='github\template.gitignore' destination='${PLASTER_PARAM_ModuleName}\.gitignore'/>
 
    <message>`r`n-> Creating BuildTasks Folder </message>
    <file source='' destination='${PLASTER_PARAM_ModuleName}\BuildTasks'/>
    <message>`r`n-> Add BuildTasks Scripts</message>
    <templateFile source='BuildTasks\template.01_SetBuildVariable.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\01_SetBuildVariable.Task.ps1'/>
    <templateFile source='BuildTasks\template.02_Clean.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\02_Clean.Task.ps1'/>
    <templateFile source='BuildTasks\template.03_BuildModule.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\03_BuildModule.Task.ps1'/>
    <templateFile source='BuildTasks\template.04_BuildManifest.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\04_BuildManifest.Task.ps1'/>
    <templateFile source='BuildTasks\template.05_GenerateMarkdown.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\05_GenerateMarkdown.Task.ps1'/>
    <templateFile source='BuildTasks\template.06_GenerateHelp.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\06_GenerateHelp.Task.ps1'/>
    <templateFile source='BuildTasks\template.07_Analyse.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\07_Analyse.Task.ps1'/>
    <templateFile source='BuildTasks\template.08_ImportModule.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\08_ImportModule.Task.ps1'/>
    <templateFile source='BuildTasks\template.09_UnitTests.Task.ps1' destination='${PLASTER_PARAM_ModuleName}\BuildTasks\09_UnitTests.Task.ps1'/>
    <templateFile source='template.Build.ps1' destination='${PLASTER_PARAM_ModuleName}\Build.ps1' />
    <templateFile source='template.requirements.psd1' destination='${PLASTER_PARAM_ModuleName}\requirements.psd1'/>
    <templateFile source='ModuleName.Build.ps1' destination='${PLASTER_PARAM_ModuleName}\${PLASTER_PARAM_ModuleName}.Build.ps1' />
 
 
    <message condition='$PLASTER_PARAM_UnitTests -eq "Yes"'>`r`n-> Creating UnitTests folder</message>
    <file source='' destination='${PLASTER_PARAM_ModuleName}\UnitTests' condition='$PLASTER_PARAM_UnitTests -eq "Yes"' />
    <message condition='$PLASTER_PARAM_UnitTests -eq "Yes"'>`r`n-> Copying UnitTests files</message>
    <templateFile source='UnitTests\*.Tests.ps1' destination='${PLASTER_PARAM_ModuleName}\UnitTests\' condition='$PLASTER_PARAM_UnitTests -eq "Yes"'/>
 
    <message condition='$PLASTER_PARAM_Editor -eq "VSCode"'>`r`n-> Creating VSCode folder</message>
    <file source='' destination='.vscode' condition='$PLASTER_PARAM_Editor -eq "VSCode"' />
    <message condition='$PLASTER_PARAM_Editor -eq "VSCode"'>`r`n-> Creating VSCode files</message>
    <file source='vscode\settings.json' destination='${PLASTER_PARAM_ModuleName}\.vscode\settings.json' condition='$PLASTER_PARAM_Editor -eq "VSCode"' />
    <file source='vscode\launch.json' destination='${PLASTER_PARAM_ModuleName}\.vscode\launch.json' condition='$PLASTER_PARAM_Editor -eq "VSCode"' />
    <file source='vscode\PSScriptAnalyzerSettings.psd1' destination='${PLASTER_PARAM_ModuleName}\.vscode\PSScriptAnalyzerSettings.psd1' condition='$PLASTER_PARAM_Editor -eq "VSCode"' />
    <templateFile source='vscode\tasks_BuildTasks.json' destination='${PLASTER_PARAM_ModuleName}\.vscode\tasks.json' condition='$PLASTER_PARAM_Editor -eq "VSCode"' />
 
    <message condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'>`r`n-> Creating Appveyor file</message>
    <templateFile source='CICD\template.appveyor.yml' destination='${PLASTER_PARAM_ModuleName}\appveyor.yml' condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'/>
    <message condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'>____________________________________</message>
    <message condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'>`r`n-> To add appveyor support you must:</message>
    <message condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'>`r`n-> 1- Add your project on github (https://github.com/)</message>
    <message condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'>`r`n-> 2-Add your Github project on Appveyor (https://www.appveyor.com/)</message>
    <message condition='$PLASTER_PARAM_CICD -contains "AppVeyor"'>____________________________________</message>
 
    <message condition='$PLASTER_PARAM_CICD -contains "GitHubActions"'>`r`n-> Creating Github Actions File</message>
    <file source='CICD\main.yaml' destination='${PLASTER_PARAM_ModuleName}\.github\workflows\main.yaml' condition='$PLASTER_PARAM_CICD -contains "GitHubActions"'/>
 
    <message>`r`n-> Testing require modules </message>
    <requireModule name='Pester' condition='$PLASTER_PARAM_UnitTests -eq "Yes"' minimumVersion='4.7.1' message='Without Pester, you will not be able to run the provided Pester test to validate your module manifest file.`nWithout version 3.4.0, VS Code will not display Pester warnings and errors in the Problems panel.'/>
    <requireModule name='psake' condition='$PLASTER_PARAM_Psake -eq "Yes"' minimumVersion='4.7.4' message='Without psake, you will not be able to run the provided build script to build and/or publish your module.'/>
    <requireModule name='PSScriptAnalyzer' condition='$PLASTER_PARAM_Editor -eq "VSCode"' minimumVersion='1.17.1' message="Without PSScriptAnalyzer, you will not be able to perform script analysis, or use the provided options to control script analysis."/>
    <requireModule name='PSdeploy' condition='$PLASTER_PARAM_CICD -eq "Yes"' minimumVersion='1.0.1' message='Without PSDeploy, you will not be able to automatically deploy your module.'/>
    <requireModule name='PSClassUtils' condition='$PLASTER_PARAM_CICD -eq "Yes"' minimumVersion='2.6.1' message='Without PSClassUtils, you will not be able to run the provided build script to build and/or publish your module.'/>
    <requireModule name='PlatyPS' condition='$PLASTER_PARAM_CICD -eq "Yes"' minimumVersion='0.12.0' message='Without PlatyPS, you will not be able to generate the documentation automatically.'/>
    <requireModule name='BuildHelpers' condition='$PLASTER_PARAM_CICD -eq "Yes"' minimumVersion='2.0.8' message='Without BuilHelpers, you will not be able to use CI/CD scripts.'/>
  </content>
</plasterManifest>