Commit fcf90807 authored by Ludan Stoecklé's avatar Ludan Stoecklé

1.3.1 fat jar now works properly

parent 188103db
{
"name": "english-determiners",
"version": "2.3.0",
"version": "2.3.1",
"description": "English determiners",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "french-adjectives",
"version": "2.3.0",
"version": "2.3.1",
"description": "Agreement of adjectives in French",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......@@ -45,7 +45,7 @@
},
"dependencies": {
"debug": "^4.1.1",
"french-h-muet-aspire": "2.3.0"
"french-h-muet-aspire": "2.3.1"
},
"keywords": [
"french",
......
{
"name": "french-determiners",
"version": "2.3.0",
"version": "2.3.1",
"description": "French determiners",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "french-h-muet-aspire",
"version": "2.3.0",
"version": "2.3.1",
"description": "List of French words that are \"aspiré\" (vs. \"muet\")\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[D\u001b[Dstarting with a h that is \"aspiré\" vs \"muet\"",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "french-ordinals",
"version": "2.3.0",
"version": "2.3.1",
"description": "Ordinal numbers in French: 12 => douzième",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "french-verbs",
"version": "2.3.0",
"version": "2.3.1",
"description": "French verbs: conjugation, based on the Lefff contents, and list of transitive and intransitive verbs",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......@@ -50,7 +50,7 @@
},
"dependencies": {
"debug": "^4.1.1",
"french-h-muet-aspire": "2.3.0"
"french-h-muet-aspire": "2.3.1"
},
"devDependencies": {
"copyfiles": "^2.1.0",
......
{
"name": "french-words-gender",
"version": "2.3.0",
"version": "2.3.1",
"description": "Gender of French words, based on the Lefff",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "german-adjectives",
"version": "2.3.0",
"version": "2.3.1",
"description": "German adjectives, based on german-pos-dict",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "german-determiners",
"version": "2.3.0",
"version": "2.3.1",
"description": "German determiners",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "german-dict-helper",
"version": "2.3.0",
"version": "2.3.1",
"description": "Helper functions on an included database derived from german-pos-dict",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "german-ordinals",
"version": "2.3.0",
"version": "2.3.1",
"description": "Ordinal numbers in German: 12 => zwölfte",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "german-verbs",
"version": "2.3.0",
"version": "2.3.1",
"description": "German verbs, based on german-pos-dict",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "german-words",
"version": "2.3.0",
"version": "2.3.1",
"description": "Gender and case of German words, based on german-pos-dict",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "gulp-rosaenlg",
"version": "2.3.0",
"version": "2.3.1",
"description": "RosaeNLG client side packaging helper",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......@@ -60,6 +60,6 @@
"browserify": "^16.2.3",
"debug": "^4.1.1",
"minify-stream": "^1.2.0",
"rosaenlg": "1.3.0"
"rosaenlg": "1.3.1"
}
}
{
"name": "italian-adjectives",
"version": "2.3.0",
"version": "2.3.1",
"description": "Italian adjectives, based on morph-it",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......@@ -58,6 +58,6 @@
"license": "MIT",
"dependencies": {
"debug": "^4.1.1",
"rosaenlg-filter": "2.3.0"
"rosaenlg-filter": "2.3.1"
}
}
{
"name": "italian-determiners",
"version": "2.3.0",
"version": "2.3.1",
"description": "Italian determiners",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "italian-ordinals-cardinals",
"version": "2.3.0",
"version": "2.3.1",
"description": "Ordinal and cardinal numbers in Italian",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "italian-verbs",
"version": "2.3.0",
"version": "2.3.1",
"description": "Italian verbs, based on morph-it",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "italian-words",
"version": "2.3.0",
"version": "2.3.1",
"description": "Gender and plural of Italian words, based on morph-it",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "lefff-helper",
"version": "2.3.0",
"version": "2.3.1",
"description": "Helper functions on an included database derived from Lefff",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "morph-it-helper",
"version": "2.3.0",
"version": "2.3.1",
"description": "Helper functions on an included database derived from morph-it (Free Morphological Lexicon for the Italian Language)",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......
{
"name": "rosaenlg-filter",
"version": "2.3.0",
"version": "2.3.1",
"description": "Filtering feature of RosaeNLG",
"main": "dist/index.js",
"types": "dist/index.d.ts",
......@@ -43,7 +43,7 @@
"better-title-case": "^1.0.1",
"compromise": "^11.14.3",
"debug": "^4.1.1",
"french-h-muet-aspire": "2.3.0",
"french-h-muet-aspire": "2.3.1",
"titlecase-french": "^1.0.1"
},
"keywords": [
......
{
"name": "rosaenlg-pug-code-gen",
"version": "3.3.0",
"version": "3.3.1",
"description": "Default code-generator for pug. It generates HTML via a JavaScript template function. - RosaeNLG fork",
"scripts": {
"build": "tsc && cp lib/index.js dist/",
......@@ -53,13 +53,13 @@
"constantinople": "^3.1.2",
"debug": "^4.1.1",
"doctypes": "^1.1.0",
"french-verbs": "2.3.0",
"german-adjectives": "2.3.0",
"german-verbs": "2.3.0",
"german-words": "2.3.0",
"italian-adjectives": "2.3.0",
"italian-verbs": "2.3.0",
"italian-words": "2.3.0",
"french-verbs": "2.3.1",
"german-adjectives": "2.3.1",
"german-verbs": "2.3.1",
"german-words": "2.3.1",
"italian-adjectives": "2.3.1",
"italian-verbs": "2.3.1",
"italian-words": "2.3.1",
"js-stringify": "^1.0.1",
"pug-attrs": "^2.0.3",
"pug-error": "^1.3.2",
......
{
"name": "rosaenlg-pug-filters",
"version": "4.3.0",
"version": "4.3.1",
"description": "Code for processing filters in pug templates - RosaeNLG fork",
"scripts": {},
"keywords": [
......@@ -12,7 +12,7 @@
"jstransformer": "1.0.0",
"pug-error": "^1.3.2",
"resolve": "^1.1.6",
"rosaenlg-pug-walk": "2.2.0",
"rosaenlg-pug-walk": "2.2.1",
"snyk": "^1.232.0"
},
"devDependencies": {
......@@ -21,9 +21,9 @@
"jstransformer-less": "^2.3.0",
"jstransformer-markdown-it": "^2.1.0",
"jstransformer-stylus": "^1.0.0",
"rosaenlg-pug-lexer": "5.2.0",
"rosaenlg-pug-load": "3.2.0",
"rosaenlg-pug-parser": "6.2.0"
"rosaenlg-pug-lexer": "5.2.1",
"rosaenlg-pug-load": "3.2.1",
"rosaenlg-pug-parser": "6.2.1"
},
"repository": {
"type": "git",
......
{
"name": "rosaenlg-pug-lexer",
"version": "5.2.0",
"version": "5.2.1",
"description": "The pug lexer (takes a string and converts it to an array of tokens) - RosaeNLG fork",
"keywords": [
"pug"
......
{
"name": "rosaenlg-pug-linker",
"version": "4.2.0",
"version": "4.2.1",
"description": "Link multiple pug ASTs together using include/extends - RosaeNLG fork",
"keywords": [
"pug"
......@@ -8,12 +8,12 @@
"scripts": {},
"dependencies": {
"pug-error": "^1.3.2",
"rosaenlg-pug-walk": "2.2.0"
"rosaenlg-pug-walk": "2.2.1"
},
"devDependencies": {
"rosaenlg-pug-lexer": "5.2.0",
"rosaenlg-pug-load": "3.2.0",
"rosaenlg-pug-parser": "6.2.0"
"rosaenlg-pug-lexer": "5.2.1",
"rosaenlg-pug-load": "3.2.1",
"rosaenlg-pug-parser": "6.2.1"
},
"repository": {
"type": "git",
......
'use strict';
var fs = require('fs');
var path = require('path');
var walk = require('rosaenlg-pug-walk');
var assign = require('object-assign');
const fs = require('fs');
const path = require('path');
const walk = require('rosaenlg-pug-walk');
const assign = require('object-assign');
module.exports = load;
function load(ast, options) {
......@@ -13,11 +13,11 @@ function load(ast, options) {
return walk(ast, function(node) {
if (node.str === undefined) {
if (node.type === 'Include' || node.type === 'RawInclude' || node.type === 'Extends') {
var file = node.file;
const file = node.file;
if (file.type !== 'FileReference') {
throw new Error('Expected file.type to be "FileReference"');
}
var path, str;
let path, str;
try {
path = options.resolve(file.path, file.filename, options);
file.fullPath = path;
......@@ -44,15 +44,15 @@ load.string = function loadString(src, options) {
options = assign(getOptions(options), {
src: src,
});
var tokens = options.lex(src, options);
var ast = options.parse(tokens, options);
const tokens = options.lex(src, options);
const ast = options.parse(tokens, options);
return load(ast, options);
};
load.file = function loadFile(filename, options) {
options = assign(getOptions(options), {
filename: filename,
});
var str = options.read(filename);
const str = options.read(filename);
return load.string(str, options);
};
......@@ -69,7 +69,19 @@ load.resolve = function resolve(filename, source, options) {
return filename;
};
load.read = function read(filename, options) {
return fs.readFileSync(filename, 'utf8');
if (options.staticFs) {
// we are running in an env without fs: client or Graal thus we try to read from "includes" option
const str = options.staticFs[filename];
if (!str) {
const err = new Error();
err.name = 'InvalidArgumentError';
err.message = `using file content from staticFs opt but cannot be found for ${options.filename}`;
throw err;
}
return str;
} else {
return fs.readFileSync(filename, 'utf8');
}
};
load.validateOptions = function validateOptions(options) {
......
{
"name": "rosaenlg-pug-load",
"version": "3.2.0",
"version": "3.2.1",
"description": "The Pug loader is responsible for loading the depenendencies of a given Pug file. - RosaeNLG fork",
"keywords": [
"pug"
......@@ -8,11 +8,11 @@
"scripts": {},
"dependencies": {
"object-assign": "^4.1.0",
"rosaenlg-pug-walk": "2.2.0"
"rosaenlg-pug-walk": "2.2.1"
},
"devDependencies": {
"rosaenlg-pug-lexer": "5.2.0",
"rosaenlg-pug-parser": "6.2.0"
"rosaenlg-pug-lexer": "5.2.1",
"rosaenlg-pug-parser": "6.2.1"
},
"repository": {
"type": "git",
......
{
"name": "rosaenlg-pug-parser",
"version": "6.2.0",
"version": "6.2.1",
"description": "The pug parser (takes an array of tokens and converts it to an abstract syntax tree) - RosaeNLG fork",
"keywords": [
"pug"
......
{
"name": "rosaenlg-pug-walk",
"version": "2.2.0",
"version": "2.2.1",
"description": "Walk and transform a pug AST - RosaeNLG fork",
"keywords": [
"pug"
],
"scripts": {},
"devDependencies": {
"rosaenlg-pug-lexer": "5.2.0",
"rosaenlg-pug-parser": "6.2.0"
"rosaenlg-pug-lexer": "5.2.1",
"rosaenlg-pug-parser": "6.2.1"
},
"dependencies": {
"debug": "^4.1.1"
......
{
"name": "rosaenlg-yseop",
"version": "2.3.0",
"version": "2.3.1",
"description": "Yseop code generator for RosaeNLG. It generates Yseop Text compatible templates. Derived from rosaenlg-pug-code-gen.",
"scripts": {},
"keywords": [
......
name: rosaenlg
version: '1.3.0'
version: '1.3.1'
title: RosaeNLG
nav:
- modules/ROOT/nav.adoc
......
......@@ -8,6 +8,13 @@ https://keepachangelog.com/en/0.3.0/
=== Changed
////
== [1.3.1] - 2019-10-18
=== Fixed
* _fat js_ is still as fat but at least works now.
== [1.3.0] - 2019-10-13
=== Added
......
......@@ -19,24 +19,21 @@ const phoneString = `-
colors: ['Black', 'Red', 'White'],
displaySize: 6,
screenRatio: 80.43,
battery: 3300,
bluetooh: 5
battery: 3300
},
{
name: 'OnePlus 5',
colors: ['Gold', 'Gray'],
displaySize: 5.5,
screenRatio: 72.93,
battery: 3300,
bluetooh: 5
battery: 3300
},
{
name: 'OnePlus 3T',
colors: ['Black', 'Gold', 'Gray'],
displaySize: 5.5,
screenRatio: 73.15,
battery: 3400,
bluetooh: 4.2
battery: 3400
}
];
`
......
......@@ -19,24 +19,21 @@ const phoneString = `-
colors: ['Black', 'Red', 'White'],
displaySize: 6,
screenRatio: 80.43,
battery: 3300,
bluetooh: 5
battery: 3300
},
{
name: 'OnePlus 5',
colors: ['Gold', 'Gray'],
displaySize: 5.5,
screenRatio: 72.93,
battery: 3300,
bluetooh: 5
battery: 3300
},
{
name: 'OnePlus 3T',
colors: ['Black', 'Gold', 'Gray'],
displaySize: 5.5,
screenRatio: 73.15,
battery: 3400,
bluetooh: 4.2
battery: 3400
}
];
`
......
......@@ -48,24 +48,21 @@ const phoneString = `-
colors: ['Black', 'Red', 'White'],
displaySize: 6,
screenRatio: 80.43,
battery: 3300,
bluetooh: 5
battery: 3300
},
{
name: 'OnePlus 5',
colors: ['Gold', 'Gray'],
displaySize: 5.5,
screenRatio: 72.93,
battery: 3300,
bluetooh: 5
battery: 3300
},
{
name: 'OnePlus 3T',
colors: ['Black', 'Gold', 'Gray'],
displaySize: 5.5,
screenRatio: 73.15,
battery: 3400,
bluetooh: 4.2
battery: 3400
}
];
`
......
......@@ -3,14 +3,13 @@ const rosaenlgPug = require('rosaenlg');
// end::require[]
// tag::data[]
var phones = [
let phones = [
{
name: 'OnePlus 5T',
colors: ['Black', 'Red', 'White'],
displaySize: 6,
screenRatio: 80.43,
battery: 3300,
bluetooh: 5,
},
{
name: 'OnePlus 5',
......@@ -18,7 +17,6 @@ var phones = [
displaySize: 5.5,
screenRatio: 72.93,
battery: 3300,
bluetooh: 5,
},
{