Code Monkey home page Code Monkey logo

Comments (3)

julesvanrie avatar julesvanrie commented on August 11, 2024

This one is still happening. Windows setup to be precise. All users had it today (6).

Removing single quotes indeed solved the problem.

from data-setup.

gmanchon avatar gmanchon commented on August 11, 2024

slack thread

from data-setup.

julesvanrie avatar julesvanrie commented on August 11, 2024

Spent a bit more time on this (many Windows laptops in my batch).

The problem only occurs when a BROWSER env variable is added to .zshrc.

In the setup, we export BROWSER only for gh, not for jupyter. Later, when students setup dotfiles, we don't have the export BROWSER anymore. On some laptops this works fine (mine doesn't need BROWSER and opens my browser nicely when using gh browse and jupyter notebook. But on some students' laptops this doesn't work, and they need BROWSER to be set. If then the line is used as during the setup, it doesn't work because of the extra quotes.

Underlying problem is that gh and jupyter notebook expect the path in a different format:

  • gh needs export BROWSER="'/mnt/c/Program Files/Google/Chrome/Application/chrome.exe'" (mind the extra quotes)
  • jupyter notebook needs export BROWSER="/mnt/c/Program Files/Google/Chrome/Application/chrome.exe" (no extra quotes)

Fortunately gh now supports an env variable called GH_BROWSER, which has higher prio than BROWSER.

So, adding the following to .zshrc seems to always work:

# Browser
export BROWSER="/mnt/c/Program Files/Google/Chrome/Application/chrome.exe"
export GH_BROWSER="'/mnt/c/Program Files/Google/Chrome/Application/chrome.exe'"

Could be useful to add this to the end of the setup?
Or, in the first part of the setup, where BROWSER is exported for use by gh, maybe replace it with GH_BROWSER to avoid confusion.

from data-setup.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.