Skip to content

Instantly share code, notes, and snippets.

@BetterProgramming
Created January 19, 2020 22:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BetterProgramming/d45a01e29d0cfb43df998e9e3fbf7168 to your computer and use it in GitHub Desktop.
Save BetterProgramming/d45a01e29d0cfb43df998e9e3fbf7168 to your computer and use it in GitHub Desktop.
const fs = require("fs");
const file = "./files/file.txt";
fs.chown(file, 1000, 1000, err => {
if (err) throw err;
console.log("File ownership changed");
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment