Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C create-react-app
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,547
    • Issues 1,547
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 417
    • Merge requests 417
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • create-react-app
  • Issues
  • #1213
Closed
Open
Issue created Dec 08, 2016 by Administrator@rootContributor

Opens Chrome stable if Chrome Canary is running

Created by: kornelski

Description

npm start opens wrong browser. I have both Chrome and Chrome Canary on my system, but I only use Canary (which is set as my default browser system-wide).

Expected behavior

npm start should open my default browser.

Actual behavior

Ignores my default browser setting, and opens Chrome (stable).

Reproducible Demo

  1. Start Google Chrome Canary.app
  2. run npm start

Cause of the bug

node_modules/react-dev-utils/openBrowser.js:

execSync('ps cax | grep "Google Chrome"');

grep incorrectly matches "Google Chrome Canary". Probably the same error would happen with Beta.

execSync('ps cax | grep "Google Chrome$"');

seems to fix the problem (tested on OS X 10.11). Alternatively, pgrep -x "Google Chrome" may give more precise result.

Assignee
Assign to
Time tracking