{
    "version": "4.9.1",
    "description": "A tool to label folders with color-coded / image-coded icon",
    "homepage": "https://foldermarker.com/en/",
    "license": "Freeware",
    "url": "https://foldermarker.com/FolderMarker_Free.exe",
    "hash": "0f7b09301c72aa9dacd233eb8321f9f4fc3c9fc27b9b40ec406a2c7b188caf87",
    "innosetup": true,
    "pre_install": [
        "if (!(is_admin)) { error \"$app requires admin rights to $cmd\"; break }",
        "",
        "Rename-Item \"$dir\\icl\\fColors,3.icl\" 'fColors.icl'; Remove-Item \"$dir\\icl\\fColors,*.icl\"",
        "Rename-Item \"$dir\\icl\\fMain,3.icl\" 'fMain.icl'; Remove-Item \"$dir\\icl\\fMain,*.icl\"",
        "",
        "Invoke-ExternalCommand regsvr32 -ArgumentList @(\"$dir\\FMADM.dll\", '/s') -RunAs | Out-Null",
        "Invoke-ExternalCommand regsvr32 -ArgumentList @(\"$dir\\ShellExt.dll\", '/s') -RunAs | Out-Null",
        "if ($architecture -eq '64bit') {",
        "    Invoke-ExternalCommand regsvr32 -ArgumentList @(\"$dir\\ShellExt64.dll\", '/s') -RunAs | Out-Null",
        "}"
    ],
    "pre_uninstall": [
        "if (!(is_admin)) { error \"$app requires admin rights to $cmd\"; break }",
        "Invoke-ExternalCommand regsvr32 -ArgumentList @('/u', \"$dir\\FMADM.dll\", '/s') -RunAs | Out-Null",
        "Invoke-ExternalCommand regsvr32 -ArgumentList @('/u', \"$dir\\ShellExt.dll\", '/s') -RunAs | Out-Null",
        "if ($architecture -eq '64bit') {",
        "    Invoke-ExternalCommand regsvr32 -ArgumentList @('/u', \"$dir\\ShellExt64.dll\", '/s') -RunAs | Out-Null",
        "}",
        "# Restart explorer so that ShellExt(-64).dll can be removed",
        "Stop-Process -Name 'explorer'; Start-Sleep -Seconds 2",
        "if (!(Get-Process -Name 'explorer' -ErrorAction SilentlyContinue)) { Start-Process 'explorer' }"
    ],
    "env_set": {
        "FOLDER_MARKER_DIR": "$dir"
    },
    "shortcuts": [
        [
            "FolderMarker.exe",
            "Folder Marker"
        ]
    ],
    "checkver": {
        "url": "https://foldermarker.com/en/download/",
        "regex": "Version\\: ([\\d.]+)</p>"
    },
    "autoupdate": {
        "url": "https://foldermarker.com/FolderMarker_Free.exe"
    }
}
