https://github.com/moox/metalsmith-rename
metalsmith plugin to rename entries
https://github.com/moox/metalsmith-rename
Last synced: about 1 year ago
JSON representation
metalsmith plugin to rename entries
- Host: GitHub
- URL: https://github.com/moox/metalsmith-rename
- Owner: MoOx
- License: mit
- Created: 2015-05-01T06:21:19.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2017-11-21T07:01:17.000Z (over 8 years ago)
- Last Synced: 2025-03-27T04:12:31.748Z (about 1 year ago)
- Language: JavaScript
- Size: 3.91 KB
- Stars: 6
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# metalsmith-rename [](https://travis-ci.org/MoOx/metalsmith-rename)
> Metalsmith plugin to rename entries
## Installation
```console
$ npm install metalsmith-rename
```
## Usage
```js
import Metalsmith from "metalsmith"
import rename from "metalsmith-rename"
new Metalsmith("./")
.use(
rename([
[/\.md$/, ".html"]
])
)
.build(err => {if (err) {throw err}})
```
### Options
This plugin takes an array.
Each item must be an array of [pattern, replacement]
## [Changelog](CHANGELOG.md)
## [License](LICENSE)