bpo-39631: Fix file association MIME type in the Windows installer (GH-20205)

Use text/x-python instead of text/plain to avoid issues with tools assuming that "ShellExecute(script)" is a non-executable operation.
This commit is contained in:
Zackery Spytz 2020-05-19 06:20:39 -06:00 committed by GitHub
parent 29251b787b
commit 8c862e5124
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -6,14 +6,14 @@
<RegistryValue KeyPath="yes" Root="HKMU" Key="Software\Python\PyLauncher" Name="AssociateFiles" Value="1" Type="integer" /> <RegistryValue KeyPath="yes" Root="HKMU" Key="Software\Python\PyLauncher" Name="AssociateFiles" Value="1" Type="integer" />
<ProgId Id="Python.File" Description="!(loc.PythonFileDescription)" Advertise="no" Icon="py.exe" IconIndex="1"> <ProgId Id="Python.File" Description="!(loc.PythonFileDescription)" Advertise="no" Icon="py.exe" IconIndex="1">
<Extension Id="py" ContentType="text/plain"> <Extension Id="py" ContentType="text/x-python">
<Verb Id="open" TargetFile="py.exe" Argument="&quot;%L&quot; %*" /> <Verb Id="open" TargetFile="py.exe" Argument="&quot;%L&quot; %*" />
</Extension> </Extension>
</ProgId> </ProgId>
<RegistryValue Root="HKCR" Key="Python.File\shellex\DropHandler" Value="{BEA218D2-6950-497B-9434-61683EC065FE}" Type="string" /> <RegistryValue Root="HKCR" Key="Python.File\shellex\DropHandler" Value="{BEA218D2-6950-497B-9434-61683EC065FE}" Type="string" />
<ProgId Id="Python.NoConFile" Description="!(loc.PythonNoConFileDescription)" Advertise="no" Icon="py.exe" IconIndex="1"> <ProgId Id="Python.NoConFile" Description="!(loc.PythonNoConFileDescription)" Advertise="no" Icon="py.exe" IconIndex="1">
<Extension Id="pyw" ContentType="text/plain"> <Extension Id="pyw" ContentType="text/x-python">
<Verb Id="open" TargetFile="pyw.exe" Argument="&quot;%L&quot; %*" /> <Verb Id="open" TargetFile="pyw.exe" Argument="&quot;%L&quot; %*" />
</Extension> </Extension>
</ProgId> </ProgId>