skip to Main Content

it shows "You must run VS code with admin privileges in order to enable Neon Dreams.".It doesn’t work even after running vs-code as administrator.

2

Answers


  1. The error is caused by the new version of VSCode, the extension normally change the workbench files of electron-browser but electron-browser was removed in the commit https://github.com/microsoft/vscode/tree/f4f1b04d872a2b94d9a5105a1eefb81a213c07f2 and it has been replaced by electron-sandbox.

    So you have 2 choices :

    Or

    • You can stay in 1.70 and modify manually the extension :
    1. Go to "C:/Users/YourUsername/.vscode/extensions/robbowen.synthwave… or wherever your vscode extensions are stored
    2. Go to src/ and open extension.js
    3. You will have to replace all the "electron-browser" with "electron-sandbox" so
          const htmlFile =
            base +
            (isWin
              ? "\electron-browser\workbench\workbench.html"
              : "/electron-browser/workbench/workbench.html");
    
          const templateFile =
            base +
            (isWin
              ? "\electron-browser\workbench\neondreams.js"
              : "/electron-browser/workbench/neondreams.js");
    

    on line 34 become

          const htmlFile =
            base +
            (isWin
              ? "\electron-sandbox\workbench\workbench.html"
              : "/electron-sandbox/workbench/workbench.html");
    
          const templateFile =
            base +
            (isWin
              ? "\electron-sandbox\workbench\neondreams.js"
              : "/electron-sandbox/workbench/neondreams.js");
    

    and same operation at line 149 on

      var htmlFile =
        base +
        (isWin
          ? "\electron-browser\workbench\workbench.html"
          : "/electron-browser/workbench/workbench.html");
    
    
    1. Save extension.js, close VSCode, open VSCode as Administrator and Enable Neon Dreams again.

    Hope it helps !

    Login or Signup to reply.
  2. Following the advise of S.Mollet to find and replace electron-browser with electron-sandbox worked; only difference I was on mac, but principal was same.

    Find vs code extension files, mine were in ~/.vscode/exentions/robb...

    and then to run vs code with admin I ran sudo code --user-data-dir="~/.vscode-root"

    and then in vs code press ⌘-p and select enable dreams.

    I was losing so much productivity while my font wasnt glowing, smh.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search