Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added new info command #3068

Merged
merged 2 commits into from May 23, 2019

Conversation

jamesgeorge007
Copy link
Contributor

↪️ Pull Request

Added a new info command which prints out information about the local environment (proves to be useful while submitting bug reports).

💻 Examples

parcel info

Environment Info:

  System:
    OS: Linux 4.18 Ubuntu 18.10 (Cosmic Cuttlefish)
    CPU: (4) x64 Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz
  Binaries:
    Node: 8.11.4 - /usr/bin/node
    Yarn: 1.17.0-0 - /usr/local/bin/yarn
    npm: 6.9.0 - /usr/local/bin/npm
  Browsers:
    Chrome: 74.0.3729.157
    Firefox: 66.0.5
  npmGlobalPackages:
    parcel-bundler: 1.12.3

🚨 Test instructions

✔️ PR Todo

  • Added/updated unit tests for this change
  • Filled out test instructions (In case there aren't any unit tests)
  • Included links to related issues/PRs

prints local environment information
@jamesgeorge007
Copy link
Contributor Author

@DeMoorJasper Thoughts 🤔

@jamesgeorge007 jamesgeorge007 changed the title Adds new info command Added new info command May 22, 2019
DeMoorJasper
DeMoorJasper previously approved these changes May 22, 2019
Copy link
Member

@DeMoorJasper DeMoorJasper left a comment

Choose a reason for hiding this comment

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

Awesome, this would simplify bug reporting a lot

@mischnic
Copy link
Member

One interesting info would be if that parcel instance is actually the globally installed one

@jamesgeorge007
Copy link
Contributor Author

One interesting info would be if that parcel instance is actually the globally installed one

npmGlobalPackages:
    parcel-bundler: 1.12.3

It returns the globally installed parcel-bundler version.

@DeMoorJasper
Copy link
Member

DeMoorJasper commented May 23, 2019

@jamesgeorge007 but it does not return whether parcel is being used globally or locally or does it?

Global is executed from terminal, local is executed from package.json

Sent with GitHawk

@jamesgeorge007
Copy link
Contributor Author

jamesgeorge007 commented May 23, 2019

@DeMoorJasper It does return the globally installed version as per now. Can you be more specific 🤔

@DeMoorJasper
Copy link
Member

@jamesgeorge007 parcel can also be ran locally. Sometimes running it globally causes issues, so it would be helpfull to know whether the parcel instance is the global or local one.

Local being in npm_modules and global being global...

You currently do not print information about the local Parcel version nor whether it's actually using the global one.

For example if you use the scripts section in pkg.json for running parcel it will use the local version regardless of whether there is a global version installed. (So your output would give a false image as the local one could be a different version)

@jamesgeorge007
Copy link
Contributor Author

@DeMoorJasper Made it such that both the local and global instances show up. Makes sense 🤔

@DeMoorJasper
Copy link
Member

@jamesgeorge007 CI is just unstable, sometimes it's Azure DevOps being unstable, but usually it's just some command failing. We're not sure why though

@DeMoorJasper DeMoorJasper merged commit 4c59571 into parcel-bundler:master May 23, 2019
@jamesgeorge007 jamesgeorge007 deleted the feat/info-cmd branch June 24, 2019 06:01
twome added a commit to twome/parcel that referenced this pull request Sep 10, 2019
…e/strip-type-module-attr

* 'master' of github.com:parcel-bundler/parcel:
  fix source maps on coffeescript assets (parcel-bundler#3423)
  Fixes parcel-bundler#3133 by upgrading serialize-to-js from 1.1.1 to 3.0.0  (parcel-bundler#3451)
  Fix up misleading usage information (parcel-bundler#3158)
  bump chokidar to get a reload fix for linux (parcel-bundler#2878)
  Use uppercase for the first letter of the issue template (parcel-bundler#3192)
  Update dotenv-expand to allow overriding of falsy values (parcel-bundler#2971)
  Fixes 3076: HMR update breaks in webworker due to window (and location.reload) not existing in web worker context. (parcel-bundler#3078)
  Scope hoisting destructuring (parcel-bundler#2742)
  Create FUNDING.yml (parcel-bundler#3074)
  Added new info command  (parcel-bundler#3068)
  Fix typo (parcel-bundler#3043)
  Update deps & gitattributes (parcel-bundler#3006)
  Fix assigning to exports from inside a function in scope hoisting (parcel-bundler#2994)
  Define __esModule interop flag when requiring ES module from CommonJS (parcel-bundler#2993)
  Replace module.require in scope hoisting (parcel-bundler#2875)
  Clear scope cache before crawling (parcel-bundler#2986)
  Fix CI (parcel-bundler#2990)
  Shake exports with pure property assignments (parcel-bundler#2979)
  Update postcss.js (parcel-bundler#2922)
  Fail immediately if yarn.lock updates are needed (parcel-bundler#2945)
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.

None yet

3 participants