Skip to content

Comments

Respect the $BROWSER environment variable when attempting to launch URLs#444

Open
ChristopherJMiller wants to merge 1 commit intoAzureAD:mainfrom
ChristopherJMiller:user/chrmiller/respect-browser-env-var
Open

Respect the $BROWSER environment variable when attempting to launch URLs#444
ChristopherJMiller wants to merge 1 commit intoAzureAD:mainfrom
ChristopherJMiller:user/chrmiller/respect-browser-env-var

Conversation

@ChristopherJMiller
Copy link

Right now, azureauth attempts a known list of browser opening tools (such as xdg-open) in order to launch the oauth authorize url in --mode web, and fails if it can't find one of these tools. This doesn't work in github codespaces, as none of these tools exist! Comparing to how az-cli, and their az login command handles it, they use the $BROWSER environment variable in order to inform what browser to use, rather than attempting to find known browser tools.

This PR moves us to that environment variable model. To provide backwards compatibility for environments that don't have that set, azureauth will still use the static list if nothing is found.

@ChristopherJMiller ChristopherJMiller requested a review from a team as a code owner February 19, 2026 19:51
Copy link
Contributor

@kyle-rader-msft kyle-rader-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants