mkdirp-promise

WebJar for mkdirp-promise

License

License

ISC
GroupId

GroupId

org.webjars.npm
ArtifactId

ArtifactId

mkdirp-promise
Last Version

Last Version

5.0.1
Release Date

Release Date

Type

Type

jar
Description

Description

mkdirp-promise
WebJar for mkdirp-promise
Project URL

Project URL

https://www.webjars.org
Source Code Management

Source Code Management

https://github.com/ahmadnassri/mkdirp-promise

Download mkdirp-promise

How to add to project

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

Dependencies

compile (1)

Group / Artifact Type Version
org.webjars.npm : mkdirp jar [0,)

Project Modules

There are no modules declared in this project.

mkdirp-promise version License

⚠️ This package is broken and no longer maintained

mkdirp (which this package was wrapping) itself supports promises now, please switch to that

Or, if you're using the latest Node.js version, fs.mkdir also supports recursive mode and returns promises

Promise version of mkdirp:

Like mkdir -p, but in node.js!

Install

npm install --only=production --save mkdirp-promise

API

const mkdirp = require('mkdirp-promise')

mkdirp(dir, [, options])

pattern: String options: Object or String Return: Object (Promise)

When it finishes, it will be fulfilled with the first directory made that had to be created, if any.

When it fails, it will be rejected with an error as its first argument.

mkdirp('/tmp/foo/bar/baz')
  .then(console.log) //=> '/tmp/foo'
  .catch(console.error)

options

The option object will be directly passed to mkdirp.


©️ ahmadnassri.com  ·  License: ISC  ·  Github: @ahmadnassri  ·  Twitter: @ahmadnassri

Versions

Version
5.0.1
1.1.0