JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 87
  • Score
    100M100P100Q74374F
  • License MIT

rename group of files from a directory

Package Exports

  • renamify
  • renamify/lib/renamify.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (renamify) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Renamify License NPM version Build Status Coverage Status

Rename group of files from a directory.

Install

npm i renamify --save

API

import renamify from 'renamify';

const dir = '/';
const from = ['bin'];

const to = ['super-bin'];

await renamify(dir, from, to);

Full:

import renamify from 'renamify';

const dir = '/';
const from = ['/bin/hello'];

const to = ['/super-bin'];

await renamify(dir, from, to

Or with ``try-to-catch`:

import renamify from 'renamify';
import tryToCatch from 'try-to-catch';

const dir = '/';
const from = ['bin'];

const to = ['super-bin'];

const [error] = await tryToCatch(renamify, dir, from, to);

console.log(error || 'done');
  • renamify-cli - CLI rename group of files from a directory.

License

MIT