mirror of
				https://github.com/ScoopInstaller/Main.git
				synced 2025-11-03 23:31:20 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			105 lines
		
	
	
		
			4.1 KiB
		
	
	
	
		
			JSON
		
	
	
	
	
	
			
		
		
	
	
			105 lines
		
	
	
		
			4.1 KiB
		
	
	
	
		
			JSON
		
	
	
	
	
	
{
 | 
						|
    "homepage": "https://www.python.org/",
 | 
						|
    "description": "A programming language that lets you work quickly and integrate systems more effectively.",
 | 
						|
    "license": "Python-2.0",
 | 
						|
    "version": "3.9.0",
 | 
						|
    "notes": "Allow applications and third-party installers to find python by running: \"$dir\\install-pep-514.reg\"",
 | 
						|
    "architecture": {
 | 
						|
        "64bit": {
 | 
						|
            "url": [
 | 
						|
                "https://www.python.org/ftp/python/3.9.0/python-3.9.0-amd64.exe#/setup.exe",
 | 
						|
                "https://raw.githubusercontent.com/ScoopInstaller/Main/master/scripts/python/install-pep-514.reg",
 | 
						|
                "https://raw.githubusercontent.com/ScoopInstaller/Main/master/scripts/python/uninstall-pep-514.reg"
 | 
						|
            ],
 | 
						|
            "hash": [
 | 
						|
                "md5:b61a33dc28f13b561452f3089c87eb63",
 | 
						|
                "5d9d7a604c057e67973e1d4b3b488ae20a0e5ee5496d03b5cf091410e33e39ed",
 | 
						|
                "d9309423b693ed63aea6b1fbfc0c34f16842cdca22a1b3edef283b87567a53b9"
 | 
						|
            ]
 | 
						|
        },
 | 
						|
        "32bit": {
 | 
						|
            "url": [
 | 
						|
                "https://www.python.org/ftp/python/3.9.0/python-3.9.0.exe#/setup.exe",
 | 
						|
                "https://raw.githubusercontent.com/ScoopInstaller/Main/master/scripts/python/install-pep-514.reg",
 | 
						|
                "https://raw.githubusercontent.com/ScoopInstaller/Main/master/scripts/python/uninstall-pep-514.reg"
 | 
						|
            ],
 | 
						|
            "hash": [
 | 
						|
                "md5:4a2812db8ab9f2e522c96c7728cfcccb",
 | 
						|
                "5d9d7a604c057e67973e1d4b3b488ae20a0e5ee5496d03b5cf091410e33e39ed",
 | 
						|
                "d9309423b693ed63aea6b1fbfc0c34f16842cdca22a1b3edef283b87567a53b9"
 | 
						|
            ]
 | 
						|
        }
 | 
						|
    },
 | 
						|
    "pre_install": [
 | 
						|
        "$py_root = \"$dir\".Replace('\\', '\\\\')",
 | 
						|
        "'install-pep-514.reg', 'uninstall-pep-514.reg' | ForEach-Object {",
 | 
						|
        "    $py_version = ($version -split '\\.')[0..1] -join '.'",
 | 
						|
        "    $content = Get-Content \"$dir\\$_\"",
 | 
						|
        "    $content = $content.Replace('$py_root', $py_root)",
 | 
						|
        "    $content = $content.Replace('$py_version', $py_version)",
 | 
						|
        "    if ($global) {",
 | 
						|
        "       $content = $content.Replace('HKEY_CURRENT_USER', 'HKEY_LOCAL_MACHINE')",
 | 
						|
        "    }",
 | 
						|
        "    Set-Content \"$dir\\$_\" $content -Encoding Ascii",
 | 
						|
        "}"
 | 
						|
    ],
 | 
						|
    "installer": {
 | 
						|
        "script": [
 | 
						|
            "Expand-DarkArchive \"$dir\\setup.exe\" \"$dir\\_tmp\"",
 | 
						|
            "@('launcher.msi', 'path.msi', 'pip.msi') | ForEach-Object {",
 | 
						|
            "    Remove-Item \"$dir\\_tmp\\AttachedContainer\\$_\"",
 | 
						|
            "}",
 | 
						|
            "(Get-ChildItem \"$dir\\_tmp\\AttachedContainer\\*.msi\").FullName | ForEach-Object { Expand-MsiArchive $_ \"$dir\" }",
 | 
						|
            "Remove-Item \"$dir\\_tmp\", \"$dir\\setup.exe\" -Force -Recurse",
 | 
						|
            "& \"$dir\\python.exe\" -E -s -m ensurepip -U --default-pip | Out-Null",
 | 
						|
            "if ($global) {",
 | 
						|
            "    $pathext = (env 'PATHEXT' $true) -replace ';.PYW?', ''",
 | 
						|
            "    env 'PATHEXT' $true \"$pathext;.PY;.PYW\"",
 | 
						|
            "}"
 | 
						|
        ]
 | 
						|
    },
 | 
						|
    "uninstaller": {
 | 
						|
        "script": [
 | 
						|
            "if ($global) {",
 | 
						|
            "    $pathext = (env 'PATHEXT' $true) -replace ';.PYW?', ''",
 | 
						|
            "    env 'PATHEXT' $true \"$pathext\"",
 | 
						|
            "}"
 | 
						|
        ]
 | 
						|
    },
 | 
						|
    "bin": [
 | 
						|
        "python.exe",
 | 
						|
        "pythonw.exe",
 | 
						|
        [
 | 
						|
            "python.exe",
 | 
						|
            "python3"
 | 
						|
        ],
 | 
						|
        "Lib\\idlelib\\idle.bat",
 | 
						|
        [
 | 
						|
            "Lib\\idlelib\\idle.bat",
 | 
						|
            "idle3"
 | 
						|
        ]
 | 
						|
    ],
 | 
						|
    "env_add_path": [
 | 
						|
        "Scripts",
 | 
						|
        "."
 | 
						|
    ],
 | 
						|
    "checkver": {
 | 
						|
        "url": "https://www.python.org/downloads/windows/",
 | 
						|
        "re": "Latest Python 3 Release - Python ([\\d\\.]+)"
 | 
						|
    },
 | 
						|
    "autoupdate": {
 | 
						|
        "architecture": {
 | 
						|
            "64bit": {
 | 
						|
                "url": "https://www.python.org/ftp/python/$version/python-$version-amd64.exe#/setup.exe"
 | 
						|
            },
 | 
						|
            "32bit": {
 | 
						|
                "url": "https://www.python.org/ftp/python/$version/python-$version.exe#/setup.exe"
 | 
						|
            }
 | 
						|
        },
 | 
						|
        "hash": {
 | 
						|
            "url": "https://www.python.org/downloads/release/python-$cleanVersion/",
 | 
						|
            "find": "(?sm)$basename.*?$md5"
 | 
						|
        }
 | 
						|
    }
 | 
						|
}
 |