Skip to content
This repository has been archived by the owner on Feb 16, 2022. It is now read-only.

fabiospampinato/autogit-plugin-replace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Autogit Plugin - Replace

A plugin for performing string replacements.

Install

npm install --save autogit-plugin-replace

Usage

Options

This plugin uses the following options object:

{
  paths: [], // Array of relative paths to the files that will be replaced
  replacements: [] // Array or arguments to pass to `String.prototype.replace`
}

Configuration

Add this plugin to a command:

const replace = require ( 'autogit-plugin-replace' );

module.exports = {
  commands: {
    'my-command': [
      replace ({
        paths: ['readme.md'],
        replacements: [
          [/pulgin/g, 'plugin'],
          [/foo/g, 'bar']
        ]
      })
    ]
  }
}

License

MIT © Fabio Spampinato

About

A plugin for performing string replacements.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published