executable

WebJar for executable

License

License

MIT
GroupId

GroupId

org.webjars.npm
ArtifactId

ArtifactId

executable
Last Version

Last Version

1.1.0
Release Date

Release Date

Type

Type

jar
Description

Description

executable
WebJar for executable
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/kevva/executable

Download executable

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.npm/executable/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>executable</artifactId>
    <version>1.1.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/executable/
implementation 'org.webjars.npm:executable:1.1.0'
// https://jarcasting.com/artifacts/org.webjars.npm/executable/
implementation ("org.webjars.npm:executable:1.1.0")
'org.webjars.npm:executable:jar:1.1.0'
<dependency org="org.webjars.npm" name="executable" rev="1.1.0">
  <artifact name="executable" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='executable', version='1.1.0')
)
libraryDependencies += "org.webjars.npm" % "executable" % "1.1.0"
[org.webjars.npm/executable "1.1.0"]

Dependencies

compile (1)

Group / Artifact Type Version
org.webjars.npm : meow jar [3.1.0,4)

Project Modules

There are no modules declared in this project.

executable Build Status

Check if a file is executable

Install

$ npm install --save executable

Usage

const executable = require('executable');

executable('bash').then(exec => {
	console.log(exec);
	//=> true
});

API

executable(file)

Returns a Promise for a boolean.

executable.sync(file)

Returns a boolean of whether the file is executable.

file

Type: string

Path of the file.

executable.checkMode(mode, [gid], [uid])

Returns a boolean of whether the mode passed as first argument means that the file is executable.

mode

Type: number

Property mode of fs.Stats instance returned by fs.stat() (or fs.statSync()) function.

gid, uid

Type: number

Respectively the group identity and user identity of the file. If not set, permissions will be evaluated without considering owner or group of the file.

Related

License

MIT © Kevin Mårtensson

Versions

Version
1.1.0