{
    "version": "8.4.20",
    "description": "PHP, a popular general-purpose scripting language that is especially suited to web development. (version 8.4)",
    "homepage": "https://www.php.net",
    "license": "PHP-3.01",
    "suggest": {
        "vcredist": "extras/vcredist2022"
    },
    "architecture": {
        "64bit": {
            "url": "https://downloads.php.net/~windows/releases/archives/php-8.4.20-Win32-vs17-x64.zip",
            "hash": "11f211a3a657962071f967f7e8f2dc1cfc379168093f6bc1d3cd0071eb47e178"
        },
        "32bit": {
            "url": "https://downloads.php.net/~windows/releases/archives/php-8.4.20-Win32-vs17-x86.zip",
            "hash": "8356c87d3f2bb6d96f82f599b4f12788407209dd564c9c5abd073b43715e0199"
        }
    },
    "pre_install": [
        "# Create directory for custom PHP configuration",
        "if (!(Test-Path \"$dir\\cli\\conf.d\")) {",
        "    (New-Item -Type directory \"$dir\\cli\\conf.d\") | Out-Null",
        "}"
    ],
    "post_install": [
        "# Enable extensions to be found in installation-relative folder (the default is to search C:/php)",
        "(Get-Content \"$dir\\cli\\php.ini\") | % { $_ -replace ';\\s?(extension_dir = \"ext\")', '$1' } | Set-Content \"$dir\\cli\\php.ini\""
    ],
    "bin": [
        "php.exe",
        "php-cgi.exe",
        "phpdbg.exe"
    ],
    "env_set": {
        "PHP_INI_SCAN_DIR": "$dir\\cli;$dir\\cli\\conf.d;"
    },
    "persist": [
        "cli",
        [
            "php.ini-production",
            "cli\\php.ini"
        ]
    ],
    "checkver": {
        "url": "https://www.php.net/releases/branches.php",
        "jsonpath": "$.[?(@.branch == '8.4')].latest"
    },
    "autoupdate": {
        "architecture": {
            "64bit": {
                "url": "https://downloads.php.net/~windows/releases/archives/php-$version-Win32-vs17-x64.zip"
            },
            "32bit": {
                "url": "https://downloads.php.net/~windows/releases/archives/php-$version-Win32-vs17-x86.zip"
            }
        },
        "hash": {
            "url": "https://downloads.php.net/~windows/releases/sha256sum.txt"
        }
    }
}
