$_myLocation = (Split-Path (Get-Variable MyInvocation -Scope 0).Value.mycommand.path)
. (Join-Path $_myLocation "CWACLogger.ps1")
. (Join-Path $_myLocation "FilePruner.ps1")

function Process-BackupMetadata
{
    [CmdletBinding()]
    Param(
        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $MetadataProcessorExecutable,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $VFS,

        [Parameter(Mandatory=$True)]
        [CWACLogger]
        [ValidateNotNull()]
        $Logger
    )

    $Logger.LogDiag("Getting count of files under $VFS")
    $allFiles = Get-ChildItem -Path $VFS -File -Recurse
    $fileCount = ($allFiles | measure).Count
    $Logger.SendValue("FileCount", $fileCount)

    $Logger.LogDiag("Processing metadata on $fileCount files...")
    For ($i = 0; $i -lt $fileCount; $i++)
    {
        $file = $allFiles[$i]
        $Logger.SendFileData($VFS, $file.FullName)
        $fileWithBackupMetadata = $file.FullName + ".bmd"
        Move-Item -Path $file.FullName -Destination $fileWithBackupMetadata
        & $MetadataProcessorExecutable $fileWithBackupMetadata $file.FullName *> $null
        if (!$?)
        {
            throw "MetadataProcessor failed with exit code $LastExitCode"
        }
        Remove-Item $fileWithBackupMetadata
        $percent = 100 * $i / $fileCount
        Write-Progress -Activity "Processing Metadata" -Status ($percent.ToString("#") + "%") -PercentComplete $percent
    }
    Write-Progress "Done" "Done" -Completed
}

function Convert-Files
{
    [CmdletBinding()]
    Param(
        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $MetadataProcessorExecutable,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $Destination,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $PruneRulesFile,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $KnownFoldersListFile,

        [Parameter(Mandatory=$True)]
        [CWACLogger]
        [ValidateNotNull()]
        $Logger
    )

    $Logger.LogDiag("Renaming 'Files' directory to 'VFS'...")
    $vfs = Join-Path $Destination "VFS"
    Move-Item -Path (Join-Path $Destination "Files") $vfs

    $Logger.LogDiag("Removing VFS noise...")
    Remove-Item (Join-Path $Destination "tombstones.txt")
    Get-ChildItem $Destination -Recurse -Filter '*wcidirs*' | Remove-Item
    $result = Filter-VFS -PruneRulesFile $PruneRulesFile -VFS $vfs -Logger $Logger

    $Logger.LogDiag("Begin stripping unnecessary file metadata...")
    Process-BackupMetadata -MetadataProcessorExecutable $MetadataProcessorExecutable -VFS $vfs -Logger $Logger

    $Logger.LogDiag("Creating VFS layout for KnownFolders")
    Create-KnownFolderLayoutVFS -KnownFoldersListFile $KnownFoldersListFile -VFS $vfs -Logger $Logger

    $vfs
}

function Find-Executable
{
    [CmdletBinding()]
    Param(
        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $VFS,

        [Parameter(Mandatory=$True)]
        [CWACLogger]
        [ValidateNotNull()]
        $Logger
    )
    $Logger.LogDiag("Attempting to determine application executable by finding shortcut (.lnk) in VFS...")

    $programDataStartMenu = Join-Path $VFS "ProgramData\Microsoft\Windows\Start Menu\Programs"
    $userAppDataRoamingStartMenu = Join-Path $VFS "Users\ContainerAdministrator\AppData\Roaming\Microsoft\Windows\Start Menu\Programs"
    $shortcutPaths = $programDataStartMenu, $userAppDataRoamingStartMenu
    
    foreach ($shortcutPath in $shortcutPaths)
    {
        $Logger.LogDiag("Searching for application shortcut in $shortcutPath...")
        $shortcut = $null

        if (Test-Path $shortcutPath)
        {
            $shortcuts = Get-ChildItem -Path $shortcutPath -Filter *.lnk -Recurse
        }

        if (($shortcuts | measure).Count -eq 0)
        {
            $Logger.LogDiag("Shortcut not found in $shortcutPath")
        }
        elseif ($shortcuts)
        {
            foreach ($shortcut in $shortcuts)
            {
                $Logger.LogDiag("Checking shortcut found at $shortcut...")
                $shell = New-Object -ComObject WScript.Shell
                $candidateExecutable = $shell.CreateShortcut($shortcut.FullName).TargetPath
                if ($candidateExecutable.Contains(".exe"))
                {
                    $executable = $candidateExecutable
                    $Logger.LogDiag("Executable determined to be $executable. If this is incorrect, please update the final AppxManifest.xml")
                    $executable
                    break
                }
            }
        }

        if ($executable)
        {
            break
        }
    }

    if (!$executable)
    {
        $Logger.LogDiag("Could not find an executable...please update the final AppxManifest.xml")
    }
}

function Filter-VFS
{
    [CmdletBinding()]
    Param(
        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $PruneRulesFile,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $VFS,

        [Parameter(Mandatory=$True)]
        [CWACLogger]
        [ValidateNotNull()]
        $Logger
    )
    $Logger.LogDiag("Filtering out VFS noise based on rules in $PruneRulesFile")
    $result = Remove-FilesToPrune -PruneRulesFile $PruneRulesFile -Path $VFS
    $VFS
}

function Create-KnownFolderLayoutVFS
{
    [CmdletBinding()]
    Param(
        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $KnownFoldersListFile,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $VFS,

        [Parameter(Mandatory=$False)]
        [CWACLogger]
        [ValidateNotNull()]
        $Logger
    )

    [xml]$knownFoldersListXml = Get-Content -Path $KnownFoldersListFile

    $knownFoldersList = $knownFoldersListXml.ChildNodes.Item(1)

    foreach ($knownFolder in $knownFoldersList.ChildNodes)
    {
        $knownFolderSrcVFSPath = Split-Path -Path $knownFolder.InnerText -NoQualifier
        $knownFolderSrcVFSPath = Join-Path $VFS $knownFolderSrcVFSPath
        $knownFolderDestVFSPath = Join-Path $VFS $knownFolder.Name

        if (($knownFolderSrcVFSPath -ne $knownFolderDestVFSPath) -and
            (Test-Path -Path $knownFolderSrcVFSPath))
        {
            if ($Logger)
            {
                $Logger.LogDiag("Moving contents from `"$knownFolderSrcVFSPath`" to `"$knownFolderDestVFSPath`"")
            }

            Move-Item -Path $knownFolderSrcVFSPath -Destination $knownFolderDestVFSPath -Force
        }
    }
}

function TokenizeVfsRelativePath
{
    [CmdletBinding()]
    Param(
        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $DllPath,

        [Parameter(Mandatory=$True)]
        [string]
        [ValidateNotNullOrEmpty()]
        $VFSRelativePath,

        [Parameter(Mandatory=$False)]
        [string]
        [ValidateNotNullOrEmpty()]
        $KnownFoldersListFile = " "
    )

    [System.Reflection.Assembly]::LoadFile((Join-Path $DllPath "Microsoft.DesktopAppConverter.Common.dll")) > $null
    [System.Reflection.Assembly]::LoadFile((Join-Path $DllPath "Microsoft.DesktopAppConverter.OfflineRegUtils.dll")) > $null
    [System.Reflection.Assembly]::LoadFile((Join-Path $DllPath "Microsoft.WindowsAPICodePack.Shell.dll")) > $null
    [System.Reflection.Assembly]::LoadFile((Join-Path $DllPath "Microsoft.WindowsAPICodePack.dll")) > $null
    [System.Reflection.Assembly]::LoadFile((Join-Path $DllPath "Microsoft.DesktopAppConverter.RegistryManager.dll")) > $null
    $tokenizer = New-Object -TypeName Microsoft.Centennial.Tools.DesktopAppConverter.Tokenizer -ArgumentList $KnownFoldersListFile

    return $tokenizer.TokenizeVfsRelativePath($VFSRelativePath)
}
# SIG # Begin signature block
# MIIkJAYJKoZIhvcNAQcCoIIkFTCCJBECAQExDzANBglghkgBZQMEAgEFADB5Bgor
# BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG
# KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCAyzZKuZ2dOLhb/
# Kif/eSI/g3yJ0V6rppxQsES9tabLhqCCDZIwggYQMIID+KADAgECAhMzAAAAZEeE
# lIbbQRk4AAAAAABkMA0GCSqGSIb3DQEBCwUAMH4xCzAJBgNVBAYTAlVTMRMwEQYD
# VQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYDVQQKExVNaWNy
#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