feat(manifest): initialize manifest

This commit is contained in:
Rodweil, Theodor 2023-07-30 20:04:25 +02:00
parent b8221f9abf
commit 8533997b68
No known key found for this signature in database
GPG key ID: F8BC1B0EB1F9CCF5
3 changed files with 139 additions and 49 deletions

View file

@ -25,11 +25,13 @@ function Get-Manifest
{
try
{
$raw = Get-Content $File
$raw = Get-Content $File | Out-String
}
catch
{
{
Write-Debug $_
$raw = '{"pages":{}, "attachments": {}}'
}
@ -66,6 +68,7 @@ function Set-Manifest
if ($Backup)
{
#FIXME: this always assumes the current working directory
Copy-Item -Path $File -Destination "$(Split-Path -Leaf $File).bck"
}