JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 4941704
  • Score
    100M100P100Q195120F
  • License MIT

Check if the process is running as root user, for example, one started with `sudo`

Package Exports

  • is-root

Readme

is-root

Check if the process is running as root user, for example, one started with sudo

Install

$ npm install is-root

Usage

$ sudo node index.js
// index.js
import isRoot from 'is-root';

isRoot();
//=> true
  • is-elevated - Check if the process is running with elevated privileges (cross-platform)