We love your input! We want to make contributing to this project as easy and transparent as possible, whether it's:
- Reporting a bug
- Discussing the current state of the code
- Submitting a fix
- Proposing new features
- Becoming a maintainer
function Write-OutputPadded { | |
<# | |
.SYNOPSIS | |
Writes colorized and formatted output to the console. | |
.DESCRIPTION | |
The Write-OutputPadded function writes colorized and formatted output to the console. It supports indentation, centering, and different types of messages (Error, Warning, Success, Information, Data, Debug, Important). | |
.PARAMETER Text | |
The text to be written to the console. |
function Connect-ToAzureSubscription { | |
[CmdletBinding()] | |
param( | |
[Parameter(Mandatory = $true, Position = 0)] | |
[ValidateNotNullOrEmpty()] | |
[guid]$TenantId, | |
[Parameter(Mandatory = $true, Position = 1)] | |
[ValidateNotNullOrEmpty()] | |
[guid]$SubscriptionId, |
# # Import the DotFiles | |
$helpersPath = Join-Path $PSScriptRoot "helpers" | |
Get-ChildItem -Path $helpersPath -Filter *.ps1 | ForEach-Object { . $_.FullName } |
function New-Folder { | |
param ( | |
[Parameter(Position = 0, Mandatory = $true)] | |
[string] | |
$Path | |
) | |
if (Get-Item $path -ErrorAction Ignore) { | |
Write-Verbose "Folder $path already exists." | |
} |
function New-File { | |
param ( | |
$Path | |
) | |
if (Get-Item $path -ErrorAction Ignore) { | |
Write-Verbose "File $path already exists." | |
} | |
else { | |
New-Item -Path $path -ItemType File | Out-Null |
function Set-ScriptExecutionPreference { | |
<# | |
.SYNOPSIS | |
Sets the script execution preference. | |
.DESCRIPTION | |
The Set-ScriptExecutionPreference function sets the script execution preference. It supports three levels of verbosity: "Information", "Verbose", and "Debug". | |
.PARAMETER ExecutionPreference | |
The execution preference to be set. It can be one of the following: "Information", "Verbose", "Debug". Default is "Information". |