0.0.2 • Published 5 years ago

header-insertor v0.0.2

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

header-insertor

A simple tool to insert some text before file's content.

Install

npm install header-insertor -g

Usage

Usage: header-insertor [options] <file ...>

Options:
  -V, --version                  output the version number
  -p, --position <n>             string, a dictionary or file
  -t, --text <n>                 string, the text which will be inserted
  -e, --encoding <n>             string, character encoding type, one of
            'ascii','utf8','utf16le','ucs2','base64','latin1','binary','hex',default 'utf8'
  -f, --file-extensions <items>  list, A list of extensions which will be inserted, default null
  -h, --help                     output usage information

example

header-insertor -p ./test.js
Please specify the <text to insert>:

Then,the program will ask you to input the text which you want to insert;Please input:/* eslint-disable */ \n;

input:

const a = 1;

output

/* eslint-disable */
const a = 1;