Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/Process-PSModule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,6 @@ permissions:

jobs:
Process-PSModule:
uses: PSModule/Process-PSModule/.github/workflows/workflow.yml@fb1bdb8fefd243292f779d2a856a38db6fe6daf4 # v6.1.13
uses: PSModule/Process-PSModule/.github/workflows/workflow.yml@1653be8d36607d9535f600278c44789979477813 # v6.1.16
secrets:
APIKey: ${{ secrets.APIKEY }}
23 changes: 3 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,12 @@
# Template-PSModule
# Yml

The canonical starting template for new PowerShell modules in the PSModule organization.

## Purpose

Use this template when creating a new PowerShell module repository.
It provides the CI/CD framework wiring, required community files, and starter layout that every PSModule module repository needs.

For step-by-step instructions, see the [template quickstart](https://psmodule.github.io/docs/Modules/Process-PSModule/template-quickstart/).

## After creating a repository from this template

1. Replace the `{{ NAME }}` placeholder with your module name throughout the repository.
2. Replace the starter function, test, and example with your module's first real command.
3. Set the repository description and custom properties on GitHub.
4. Confirm `.github/PSModule.yml` only overrides defaults when your module needs different behavior.
5. Open a draft pull request and run the full CI pipeline.

See [repository defaults](https://psmodule.github.io/docs/Modules/Repository-Defaults/) for the full checklist.
A PowerShell module for working with YAML files and data.

## Prerequisites

Modules built from this template use the [PSModule framework](https://github.com/PSModule/Process-PSModule) for building, testing, and publishing.

## Contributing

To contribute to this template itself, read the [Contribution guidelines](CONTRIBUTING.md).
Read the [Contribution guidelines](CONTRIBUTING.md).
For agents and AI tools, start with [`AGENTS.md`](AGENTS.md).
4 changes: 2 additions & 2 deletions examples/General.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
Basic module usage example.
#>

Import-Module -Name '{{ NAME }}'
Get-PSModuleTest -Name 'World'
Import-Module -Name 'Yml'
ConvertTo-Yml -InputObject @{ Name = 'World' }
39 changes: 39 additions & 0 deletions src/functions/public/ConvertTo-Yml.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
function ConvertTo-Yml {
<#
.SYNOPSIS
Converts a PowerShell object to a YAML string.

.DESCRIPTION
Converts a PowerShell object to a YAML-formatted string.
This is a placeholder function. Full implementation is pending.

.LINK
https://psmodule.io/Yml/Functions/ConvertTo-Yml/

.EXAMPLE
ConvertTo-Yml -InputObject @{ Name = 'World' }

Name: World

.INPUTS
System.Object

You can pipe any object to this function.

.OUTPUTS
System.String

A YAML-formatted string representation of the input object.
#>
[OutputType([string])]
[CmdletBinding()]
param (
# The object to convert to YAML.
[Parameter(Mandatory, ValueFromPipeline)]
[object] $InputObject
)
process {
$null = $InputObject
throw [System.NotImplementedException] 'ConvertTo-Yml is not yet implemented.'
}
}
33 changes: 0 additions & 33 deletions src/functions/public/Get-PSModuleTest.ps1

This file was deleted.

4 changes: 2 additions & 2 deletions tests/PSModuleTest.Tests.ps1 → tests/Yml.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
param()

Describe 'Module' {
It 'Function: Get-PSModuleTest' {
Get-PSModuleTest -Name 'World' | Should -Be 'Hello, World!'
It 'Function: ConvertTo-Yml - is a placeholder and throws NotImplementedException' {
{ ConvertTo-Yml -InputObject @{} } | Should -Throw
}
}
Loading