Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on Apr 25, 2024 via pnpm

chownr 1.0.1

like `chown -R`
Package summary
Share
2
issues
2
low severity
vulnerability
2
1
license
1
ISC
Package created
4 Jun 2012
Version published
9 Aug 2015
Maintainers
1
Total deps
1
Direct deps
0
License
ISC

Issues

2

2 low severity issues

low
Recommendation: Upgrade to version 1.1.0 or later
via: chownr@1.0.1
Recommendation: Upgrade to version 1.1.0 or later
via: chownr@1.0.1
Collapse
Expand

Licenses

ISC License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
chownr@1.0.1
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

0
All Dependencies CSV
β“˜ This is a list of chownr 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does chownr do?

Chownr is a helpful npm package designed to change the ownership of a file system hierarchy in Node.js. It's similar to how you would use the chown -R command in a Linux or Unix-based system. The primary function of Chownr is to recursively traverse directories, allowing you to alter the user ID and group ID of each file and directory it encounters. Chownr thus offers developers an efficient solution when they need to modify an entire file hierarchy's ownership, matching the functionality you'd expect from the fs.chown() function.

How do you use chownr?

Chownr package can be utilized within your JavaScript code in Node.js environment by first installing it via npm, and then it can be required in your script. Here's an example showing how to install and use Chownr:

  1. Install the package using npm:
npm install chownr
  1. Require and use Chownr in your script:
const chownr = require('chownr')

// supply the path to dir, uid and gid
chownr('/path/to/dir', uid, gid, (err) => {
  if (err) console.error('Failed to change ownership:', err)
})

In this example, you simply replace /path/to/dir with the desired directory's path, and uid & gid with the desired user ID and group ID respectively. If the function executes successfully, it changes the ownership of all directories and files recursively. If an error occurs, it will be logged to the console.

Where are the chownr docs?

The best place to find exhaustive details and examples for using Chownr is the package's official GitHub page: chownr - GitHub. This page acts as the documentation source, providing the package's complete function list, parameter explanations, and examples for using it effectively in your script. For more complex scenarios or troubleshooting, exploring the repository's issues or pull requests sections could provide additional community-driven insights and solutions.