0.0.38 • Published 6 years ago

util.filelist v0.0.38

Weekly downloads
8
License
MIT
Repository
github
Last release
6 years ago

util.filelist

Reads a file list and returns it as an array of values.

build analysis code style: prettier testing NPM

Reads a given file list, stores each line in an array, and returns the array. It ignore blank lines and comments (# character). Each line is delimited by the newline characters.

Installation

This module uses yarn to manage dependencies and run scripts for development.

To install as a development dependency with cli:

$ yarn add --dev util.filelist

To build the app and run all tests:

$ yarn run all

Example Usage

const getFileList = require('util.filelist');
lines = getFileList("file.list");

lines.forEach(function(line) {
    console.log(line);
});

An example of the file.list above would be:

# This is a comment

    line 1

 line 2

This would result in an Array with only two lines (line 1 & line 2). The comment line and the blank line are removed and are not placed in the list. It also trims leading and trailing spaces.

0.0.38

6 years ago

0.0.37

6 years ago

0.0.36

6 years ago

0.0.35

6 years ago

0.0.34

6 years ago

0.0.33

6 years ago

0.0.32

6 years ago

0.0.31

6 years ago

0.0.30

6 years ago

0.0.29

7 years ago

0.0.28

7 years ago

0.0.27

8 years ago

0.0.26

8 years ago

0.0.25

8 years ago

0.0.24

8 years ago

0.0.23

8 years ago

0.0.22

8 years ago

0.0.21

8 years ago

0.0.20

8 years ago

0.0.19

8 years ago

0.0.18

8 years ago

0.0.17

8 years ago

0.0.16

8 years ago

0.0.15

8 years ago

0.0.14

8 years ago

0.0.13

8 years ago

0.0.12

8 years ago

0.0.11

8 years ago

0.0.10

8 years ago

0.0.9

8 years ago

0.0.8

8 years ago

0.0.7

8 years ago

0.0.6

8 years ago

0.0.4

8 years ago

0.0.3

8 years ago

0.0.2

8 years ago

0.0.1

8 years ago