1.0.11 • Published 5 years ago

the-tmp v1.0.11

Weekly downloads
3
License
MIT
Repository
github
Last release
5 years ago

the-tmp

Build Status npm Version JS Standard

Tmp file creator

Installation

$ npm install the-tmp --save

Usage

'use strict'

const theTmp = require('the-tmp')

async function tryExample () {
  // Create tmp file and clean up automatically
  await theTmp.while(async (filename) => {
    console.log('Generated file', filename)
  })

  // Manually cleanup
  {
    const { cleanup, filename } = await theTmp.generate()
    console.log('Generated file', filename)
    cleanup() // Cleanup the file
  }
}

tryExample().catch((err) => console.error(err))

API Guide

License

This software is released under the MIT License.

Links

1.0.11

5 years ago

1.0.10

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago