Skip to content

Add the mkdtemp and mkstemp methods to fs #5332

Description

@ralt

I would like to propose the addition of mkdtemp and mkstemp to the fs module, to create a temporary directory and file, respectively.

Some manual pages to start with:

So, this utility is fairly often needed for various reasons. Not providing it in nodejs itself means that people try to rewrite it, badly. (Or may I say, inefficiently.) (I'm obviously not trying to put the blame on someone there, except on node.js for not providing the functions ;-).)

This is part of the standard library in most other languages. Whether it's C, python, java, and surely others. I believe node.js would benefit its addition as well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature requestIssues requesting new Node.js features.fsIssues and PRs related to file-system APIs and the fs module.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions