1.1.1 • Published 4 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
4 years ago
1.1.0
6 years ago
1.0.33
6 years ago
1.0.32
6 years ago
1.0.31
6 years ago
1.0.30
7 years ago
1.0.29
7 years ago
1.0.28
7 years ago
1.0.27
7 years ago
1.0.25
7 years ago
1.0.26
8 years ago
1.0.24
8 years ago
1.0.23
8 years ago
1.0.22
8 years ago
1.0.21
8 years ago
1.0.20
8 years ago
1.0.19
8 years ago
1.0.18
8 years ago
1.0.17
8 years ago
1.0.16
8 years ago
1.0.14
8 years ago
1.0.13
8 years ago
1.0.12
8 years ago
1.0.11
8 years ago
1.0.10
8 years ago
1.0.9
8 years ago
1.0.8
8 years ago
1.0.7
8 years ago
1.0.5
8 years ago
1.0.4
8 years ago
1.0.3
8 years ago
1.0.2
8 years ago
1.0.1
8 years ago
1.0.0
8 years ago