简体   繁体   中英

Sublime text 3, Package Controll - cant install packages

I realized like a week ago that I cannot install any new packages via Package Control. I tried everything even reinstalling sublime, while cleaning all files /Library/Application Support/ everything. Still the same problem. Any ideas?

ignored packages updated to: ["Emmet", "Vintage"]
reloading settings Packages/User/Package Control.sublime-settings
reloading settings Packages/User/Preferences.sublime-settings
Package Control: Error downloading package. HTTP exception InvalidCertificateException (Host codeload.github.com returned an invalid certificate ([SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:548))) downloading https://codeload.github.com/sergeche/emmet-sublime/zip/master.
error: Package Control

Unable to download Emmet. Please view the console for more details.
ignored packages updated to: ["Vintage"]
reloading settings Packages/User/Package Control.sublime-settings
reloading settings Packages/User/Preferences.sublime-settings
reloading settings Packages/User/Preferences.sublime-settings

You can change the precedence of the downloader in ~/.config/sublime-text-3/Packages/User/Package Control.sublime-settings .

"downloader_precedence":
{
    "linux":
    [
        "urllib",
        "curl",
        "wget"
    ],
    "osx":
    [
        "curl",
        "urllib"
    ],
    "windows":
    [
        "wininet"
    ]
},

Changing urllib to curl has worked for me.

For OSX:

bhanu's answer is correct but my "Package Control Settings - User" file was not at that exact location. More general instructions:

  • Open Command Palette (Cmd+Shift+P on Mac)
  • Type Package Control Settings
  • Open 'Package Control Settings - Default ' and search for downloader_precedence
  • It probably looks like this - note the default osx downloader is "urllib" :
"downloader_precedence": {
        "windows": ["wininet"],
        "osx": ["urllib"],
        "linux": ["urllib", "curl", "wget"]
    },
  • You can't actually edit the Default. Override this setting by going to Command Palette > 'Package Control Settings - User '
  • Copy-paste the snippet above into the User file (correct indentation and add comma after existing settings if needed) and make "curl" the first osx downloader:
"downloader_precedence": {
        "windows": ["wininet"],
        "osx": ["curl", "urllib"],
        "linux": ["urllib", "curl", "wget"]
    },

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM