Skip to content
Check if the process is running as Administrator on Windows
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.editorconfig
.gitattributes
.gitignore
.travis.yml
elevate.exe
fixture.js
index.js
license
package.json
readme.md
test.js

readme.md

is-admin

Check if the process is running as Administrator on Windows

Install

$ npm install --save is-admin

Usage

const isAdmin = require('is-admin');

isAdmin().then(admin => {
	console.log(admin);
	//=> false
});

API

isAdmin()

Returns a Promise<boolean> indicating whether the process is running as Administrator.

Related

  • is-elevated - Check if the process is running with elevated privileges (cross-platform)

License

MIT © Sindre Sorhus

You can’t perform that action at this time.