1.1.1 • Published 5 years ago
mergeyaml v1.1.1
Recursively merge yaml documents in a new one
Node.js Usage
install
npm install mergeyaml --save
one.yml
1: hello
4:
4.1: jhon
4.2: doe
two.yml
2: world
4:
4.1: jhon
4.2: lenon
4.3: from two
three.yml
3: '!'
4:
4.1: jhon
4.2: lennon
4.3: from three
example.js
'use strict';
var fs = require('fs');
var mergeyaml = require('mergeyaml');
var one = fs.readFileSync(__dirname + '/one.yml', 'utf8');
var two = fs.readFileSync(__dirname + '/two.yml', 'utf8');
var three = fs.readFileSync(__dirname + '/three.yml', 'utf8');
console.log(mergeyaml(one, two, three));
// or
console.log(mergeyaml([one, two, three]));
// ->
/*
1: hello
2: world
3: '!'
4:
4.1: jhon
4.2: doe
4.3: from two
*/
Terminal Usage
npm install -g mergeyaml
mergeyaml $(cat one.yml) $(cat two.yml) $(cat three.yml)
# ->
#
# 1: hello
# 2: world
# 3: '!'
# 4:
# 4.1: jhon
# 4.2: doe
# 4.3: from two
1.1.1
5 years ago
1.1.0
7 years ago
1.0.33
7 years ago
1.0.32
7 years ago
1.0.31
7 years ago
1.0.30
8 years ago
1.0.29
8 years ago
1.0.28
8 years ago
1.0.27
8 years ago
1.0.25
8 years ago
1.0.26
9 years ago
1.0.24
9 years ago
1.0.23
9 years ago
1.0.22
9 years ago
1.0.21
9 years ago
1.0.20
9 years ago
1.0.19
9 years ago
1.0.18
9 years ago
1.0.17
9 years ago
1.0.16
9 years ago
1.0.14
9 years ago
1.0.13
9 years ago
1.0.12
9 years ago
1.0.11
9 years ago
1.0.10
9 years ago
1.0.9
9 years ago
1.0.8
9 years ago
1.0.7
9 years ago
1.0.5
9 years ago
1.0.4
9 years ago
1.0.3
9 years ago
1.0.2
9 years ago
1.0.1
9 years ago
1.0.0
9 years ago