chmodr
DefinitelyTyped icon, indicating that this package has TypeScript declarations provided by the separate @types/chmodr package

1.2.0 • Public • Published

Description

Has the same effect as the command line command: chmod -R.

Install

npm i --save chmodr

Usage

Takes the same arguments as fs.chmod()

chmodr(path, mode, callback)

  • path <string> | <Buffer> | <URL>
  • mode <integer>
  • callback <Function>
    • err <Error>

Example

var chmodr = require('chmodr');
 
chmodr('/var/www/my/test/folder', 0o777, (err) => {
  if (err) {
    console.log('Failed to execute chmod', err);
  } else {
    console.log('Success');
  }
});

Readme

Keywords

none

Package Sidebar

Install

npm i chmodr

Weekly Downloads

39,717

Version

1.2.0

License

ISC

Unpacked Size

4.64 kB

Total Files

4

Last publish

Collaborators

  • isaacs