@esgettext/tools 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/LICENSE +19 -0
  2. package/README.md +126 -0
  3. package/bin/esgettext-install.js +5 -0
  4. package/bin/esgettext-mo2json.js +5 -0
  5. package/bin/esgettext-msgfmt-all.js +5 -0
  6. package/bin/esgettext-msgmerge-all.js +5 -0
  7. package/bin/esgettext-xgettext.js +5 -0
  8. package/dist/cli/getopt.d.ts +34 -0
  9. package/dist/cli/getopt.js +150 -0
  10. package/dist/cli/getopt.js.map +1 -0
  11. package/dist/cli/getopt.spec.d.ts +1 -0
  12. package/dist/cli/getopt.spec.js +164 -0
  13. package/dist/cli/getopt.spec.js.map +1 -0
  14. package/dist/cli/install.d.ts +1 -0
  15. package/dist/cli/install.js +91 -0
  16. package/dist/cli/install.js.map +1 -0
  17. package/dist/cli/mo2json-cli.d.ts +1 -0
  18. package/dist/cli/mo2json-cli.js +48 -0
  19. package/dist/cli/mo2json-cli.js.map +1 -0
  20. package/dist/cli/msgfmt-all.d.ts +1 -0
  21. package/dist/cli/msgfmt-all.js +99 -0
  22. package/dist/cli/msgfmt-all.js.map +1 -0
  23. package/dist/cli/msgmerge-all.d.ts +1 -0
  24. package/dist/cli/msgmerge-all.js +85 -0
  25. package/dist/cli/msgmerge-all.js.map +1 -0
  26. package/dist/cli/xgettext-cli.d.ts +1 -0
  27. package/dist/cli/xgettext-cli.js +303 -0
  28. package/dist/cli/xgettext-cli.js.map +1 -0
  29. package/dist/install/install.d.ts +10 -0
  30. package/dist/install/install.js +157 -0
  31. package/dist/install/install.js.map +1 -0
  32. package/dist/msgfmt-all/msgfmt-all.d.ts +8 -0
  33. package/dist/msgfmt-all/msgfmt-all.js +142 -0
  34. package/dist/msgfmt-all/msgfmt-all.js.map +1 -0
  35. package/dist/msgmerge-all/msgmerge-all.d.ts +9 -0
  36. package/dist/msgmerge-all/msgmerge-all.js +157 -0
  37. package/dist/msgmerge-all/msgmerge-all.js.map +1 -0
  38. package/dist/package.d.ts +4 -0
  39. package/dist/package.js +17 -0
  40. package/dist/package.js.map +1 -0
  41. package/dist/parser/__snapshots__/javascript.spec.js.snap +56 -0
  42. package/dist/parser/__snapshots__/po.spec.js.snap +176 -0
  43. package/dist/parser/javascript.d.ts +4 -0
  44. package/dist/parser/javascript.js +47 -0
  45. package/dist/parser/javascript.js.map +1 -0
  46. package/dist/parser/javascript.spec.d.ts +1 -0
  47. package/dist/parser/javascript.spec.js +436 -0
  48. package/dist/parser/javascript.spec.js.map +1 -0
  49. package/dist/parser/parser.d.ts +45 -0
  50. package/dist/parser/parser.js +582 -0
  51. package/dist/parser/parser.js.map +1 -0
  52. package/dist/parser/po.d.ts +22 -0
  53. package/dist/parser/po.js +394 -0
  54. package/dist/parser/po.js.map +1 -0
  55. package/dist/parser/po.spec.d.ts +1 -0
  56. package/dist/parser/po.spec.js +296 -0
  57. package/dist/parser/po.spec.js.map +1 -0
  58. package/dist/parser/typescript.d.ts +4 -0
  59. package/dist/parser/typescript.js +47 -0
  60. package/dist/parser/typescript.js.map +1 -0
  61. package/dist/parser/typescript.spec.d.ts +1 -0
  62. package/dist/parser/typescript.spec.js +106 -0
  63. package/dist/parser/typescript.spec.js.map +1 -0
  64. package/dist/pot/__snapshots__/catalog.spec.js.snap +591 -0
  65. package/dist/pot/catalog.d.ts +26 -0
  66. package/dist/pot/catalog.js +210 -0
  67. package/dist/pot/catalog.js.map +1 -0
  68. package/dist/pot/catalog.spec.d.ts +1 -0
  69. package/dist/pot/catalog.spec.js +240 -0
  70. package/dist/pot/catalog.spec.js.map +1 -0
  71. package/dist/pot/entry.d.ts +35 -0
  72. package/dist/pot/entry.js +322 -0
  73. package/dist/pot/entry.js.map +1 -0
  74. package/dist/pot/entry.spec.d.ts +1 -0
  75. package/dist/pot/entry.spec.js +317 -0
  76. package/dist/pot/entry.spec.js.map +1 -0
  77. package/dist/pot/keyword.d.ts +17 -0
  78. package/dist/pot/keyword.js +181 -0
  79. package/dist/pot/keyword.js.map +1 -0
  80. package/dist/pot/keyword.spec.d.ts +1 -0
  81. package/dist/pot/keyword.spec.js +54 -0
  82. package/dist/pot/keyword.spec.js.map +1 -0
  83. package/dist/xgettext/__snapshots__/xgettext.spec.js.snap +462 -0
  84. package/dist/xgettext/file-resolver.d.ts +5 -0
  85. package/dist/xgettext/file-resolver.js +23 -0
  86. package/dist/xgettext/file-resolver.js.map +1 -0
  87. package/dist/xgettext/file-resolver.spec.d.ts +1 -0
  88. package/dist/xgettext/file-resolver.spec.js +22 -0
  89. package/dist/xgettext/file-resolver.spec.js.map +1 -0
  90. package/dist/xgettext/files-collector.d.ts +5 -0
  91. package/dist/xgettext/files-collector.js +41 -0
  92. package/dist/xgettext/files-collector.js.map +1 -0
  93. package/dist/xgettext/files-collector.spec.d.ts +1 -0
  94. package/dist/xgettext/files-collector.spec.js +78 -0
  95. package/dist/xgettext/files-collector.spec.js.map +1 -0
  96. package/dist/xgettext/xgettext.d.ts +16 -0
  97. package/dist/xgettext/xgettext.js +335 -0
  98. package/dist/xgettext/xgettext.js.map +1 -0
  99. package/dist/xgettext/xgettext.spec.d.ts +1 -0
  100. package/dist/xgettext/xgettext.spec.js +743 -0
  101. package/dist/xgettext/xgettext.spec.js.map +1 -0
  102. package/package.json +88 -0
@@ -0,0 +1,48 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var fs_1 = require("fs");
4
+ var runtime_1 = require("@esgettext/runtime");
5
+ var getopt_1 = require("./getopt");
6
+ var gtx = runtime_1.Textdomain.getInstance('tools');
7
+ gtx.resolve().then(function () {
8
+ var optionGroups = [
9
+ {
10
+ description: gtx._('File locations:'),
11
+ options: [
12
+ {
13
+ name: 'input',
14
+ yargsOptions: {
15
+ alias: 'i',
16
+ type: 'string',
17
+ describe: gtx._('location of the input MO file'),
18
+ demandOption: gtx._("Error: the option '--input' is required."),
19
+ },
20
+ },
21
+ {
22
+ name: 'output',
23
+ yargsOptions: {
24
+ alias: 'o',
25
+ type: 'string',
26
+ describe: gtx._('location of the output JSON file'),
27
+ },
28
+ },
29
+ ],
30
+ },
31
+ ];
32
+ var usage = gtx._('[OPTIONS]');
33
+ var description = gtx._('Convert .mo files into catalog json.');
34
+ var getopt = new getopt_1.Getopt(usage, description, optionGroups);
35
+ var options = getopt.argv();
36
+ var inputFilename = options['input'];
37
+ var input = (0, fs_1.readFileSync)(inputFilename);
38
+ var catalog = (0, runtime_1.parseMoCatalog)(input);
39
+ var json = JSON.stringify(catalog);
40
+ var outputFilename = options['output'];
41
+ if (typeof outputFilename === 'undefined') {
42
+ process.stdout.write(json);
43
+ }
44
+ else {
45
+ (0, fs_1.writeFileSync)(outputFilename, json);
46
+ }
47
+ });
48
+ //# sourceMappingURL=mo2json-cli.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mo2json-cli.js","sourceRoot":"","sources":["../../src/cli/mo2json-cli.ts"],"names":[],"mappings":";;AAAA,yBAAiD;AACjD,8CAAgE;AAChE,mCAA+C;AAE/C,IAAM,GAAG,GAAG,oBAAU,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;AAC5C,GAAG,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC;IAClB,IAAM,YAAY,GAAuB;QACxC;YACC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC,iBAAiB,CAAC;YACrC,OAAO,EAAE;gBACR;oBACC,IAAI,EAAE,OAAO;oBACb,YAAY,EAAE;wBACb,KAAK,EAAE,GAAG;wBACV,IAAI,EAAE,QAAQ;wBACd,QAAQ,EAAE,GAAG,CAAC,CAAC,CAAC,+BAA+B,CAAC;wBAChD,YAAY,EAAE,GAAG,CAAC,CAAC,CAAC,0CAA0C,CAAC;qBAC/D;iBACD;gBACD;oBACC,IAAI,EAAE,QAAQ;oBACd,YAAY,EAAE;wBACb,KAAK,EAAE,GAAG;wBACV,IAAI,EAAE,QAAQ;wBACd,QAAQ,EAAE,GAAG,CAAC,CAAC,CAAC,kCAAkC,CAAC;qBACnD;iBACD;aACD;SACD;KACD,CAAC;IAEF,IAAM,KAAK,GAAG,GAAG,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC;IACjC,IAAM,WAAW,GAAG,GAAG,CAAC,CAAC,CAAC,sCAAsC,CAAC,CAAC;IAClE,IAAM,MAAM,GAAG,IAAI,eAAM,CAAC,KAAK,EAAE,WAAW,EAAE,YAAY,CAAC,CAAC;IAC5D,IAAM,OAAO,GAAG,MAAM,CAAC,IAAI,EAAE,CAAC;IAE9B,IAAM,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IACvC,IAAM,KAAK,GAAG,IAAA,iBAAY,EAAC,aAAa,CAAC,CAAC;IAC1C,IAAM,OAAO,GAAG,IAAA,wBAAc,EAAC,KAAK,CAAC,CAAC;IACtC,IAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;IAErC,IAAM,cAAc,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IACzC,IAAI,OAAO,cAAc,KAAK,WAAW,EAAE,CAAC;QAC3C,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAC5B,CAAC;SAAM,CAAC;QACP,IAAA,kBAAa,EAAC,cAAc,EAAE,IAAI,CAAC,CAAC;IACrC,CAAC;AACF,CAAC,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,99 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var runtime_1 = require("@esgettext/runtime");
4
+ var msgfmt_all_1 = require("../msgfmt-all/msgfmt-all");
5
+ var getopt_1 = require("./getopt");
6
+ var gtx = runtime_1.Textdomain.getInstance('tools');
7
+ gtx.resolve().then(function () {
8
+ var optionGroups = [
9
+ {
10
+ description: gtx._('Input file options:'),
11
+ options: [
12
+ {
13
+ name: 'package-json',
14
+ yargsOptions: {
15
+ type: 'string',
16
+ describe: gtx._("read package information from PACKAGE_JSON (or 'package.json' without an argument)"),
17
+ }
18
+ },
19
+ {
20
+ name: 'locale',
21
+ flags: {
22
+ multiple: true,
23
+ },
24
+ yargsOptions: {
25
+ alias: 'l',
26
+ type: 'array',
27
+ describe: gtx._("list of locales"),
28
+ },
29
+ },
30
+ {
31
+ name: 'directory',
32
+ yargsOptions: {
33
+ alias: 'D',
34
+ type: 'string',
35
+ describe: gtx._("search '.po' files in DIRECTORY"),
36
+ },
37
+ },
38
+ ],
39
+ },
40
+ {
41
+ description: gtx._('Output file options:'),
42
+ options: [
43
+ {
44
+ name: 'format',
45
+ yargsOptions: {
46
+ type: 'string',
47
+ default: 'gmo',
48
+ describe: gtx._("output file type format"),
49
+ },
50
+ },
51
+ ],
52
+ },
53
+ {
54
+ description: gtx._('Mode of operation:'),
55
+ options: [
56
+ {
57
+ name: 'msgfmt',
58
+ yargsOptions: {
59
+ type: 'string',
60
+ default: 'msgfmt',
61
+ describe: gtx._("msgfmt program if not in PATH"),
62
+ },
63
+ },
64
+ {
65
+ name: 'options',
66
+ flags: {
67
+ multiple: true,
68
+ },
69
+ yargsOptions: {
70
+ type: 'string',
71
+ default: ['--check', '--statistics', '--verbose'],
72
+ describe: gtx._("options to pass to msgfmt"),
73
+ },
74
+ },
75
+ ],
76
+ },
77
+ ];
78
+ var usage = gtx._('[OPTIONS] ref.pot');
79
+ var description = gtx._("Invoke 'msgmerge' for multiple files.");
80
+ var getopt = new getopt_1.Getopt(usage, description, optionGroups, {
81
+ hasVerboseOption: true,
82
+ });
83
+ var msgfmtAll;
84
+ try {
85
+ msgfmtAll = new msgfmt_all_1.MsgfmtAll(getopt.argv());
86
+ }
87
+ catch (error) {
88
+ console.warn(gtx._x('{programName}: {error}', {
89
+ error: error,
90
+ programName: getopt.programName,
91
+ }));
92
+ console.error(gtx._x('Try "{programName} --help" for more information!', {
93
+ programName: getopt.programName,
94
+ }));
95
+ process.exit(2);
96
+ }
97
+ msgfmtAll.run().then(function (exitCode) { return process.exit(exitCode); });
98
+ });
99
+ //# sourceMappingURL=msgfmt-all.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"msgfmt-all.js","sourceRoot":"","sources":["../../src/cli/msgfmt-all.ts"],"names":[],"mappings":";;AAAA,8CAAgD;AAChD,uDAAqD;AACrD,mCAA+C;AAI/C,IAAM,GAAG,GAAG,oBAAU,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;AAC5C,GAAG,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC;IAClB,IAAM,YAAY,GAAuB;QACxC;YACC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC,qBAAqB,CAAC;YACzC,OAAO,EAAE;gBACR;oBACC,IAAI,EAAE,cAAc;oBACpB,YAAY,EAAE;wBACb,IAAI,EAAE,QAAQ;wBACd,QAAQ,EAAE,GAAG,CAAC,CAAC,CAAC,oFAAoF,CAAC;qBACrG;iBACD;gBACD;oBACC,IAAI,EAAE,QAAQ;oBACd,KAAK,EAAE;wBACN,QAAQ,EAAE,IAAI;qBACd;oBACD,YAAY,EAAE;wBACb,KAAK,EAAE,GAAG;wBACV,IAAI,EAAE,OAAO;wBACb,QAAQ,EAAE,GAAG,CAAC,CAAC,CACd,iBAAiB,CACjB;qBACD;iBACD;gBACD;oBACC,IAAI,EAAE,WAAW;oBACjB,YAAY,EAAE;wBACb,KAAK,EAAE,GAAG;wBACV,IAAI,EAAE,QAAQ;wBACd,QAAQ,EAAE,GAAG,CAAC,CAAC,CACd,iCAAiC,CACjC;qBACD;iBACD;aACD;SACD;QACD;YACC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC,sBAAsB,CAAC;YAC1C,OAAO,EAAE;gBACR;oBACC,IAAI,EAAE,QAAQ;oBACd,YAAY,EAAE;wBACb,IAAI,EAAE,QAAQ;wBACd,OAAO,EAAE,KAAK;wBACd,QAAQ,EAAE,GAAG,CAAC,CAAC,CACd,yBAAyB,CACzB;qBACD;iBACD;aACD;SACD;QACD;YACC,WAAW,E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C,CAAC,CAAC;IACjB,CAAC;IAED,SAAS,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,UAAA,QAAQ,IAAI,OAAA,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAtB,CAAsB,CAAC,CAAC;AAC1D,CAAC,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,85 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var runtime_1 = require("@esgettext/runtime");
4
+ var msgmerge_all_1 = require("../msgmerge-all/msgmerge-all");
5
+ var getopt_1 = require("./getopt");
6
+ var gtx = runtime_1.Textdomain.getInstance('tools');
7
+ gtx.resolve().then(function () {
8
+ var optionGroups = [
9
+ {
10
+ description: gtx._('Input file options:'),
11
+ options: [
12
+ {
13
+ name: 'package-json',
14
+ yargsOptions: {
15
+ type: 'string',
16
+ describe: gtx._("read package information from PACKAGE_JSON (or 'package.json' without an argument)"),
17
+ }
18
+ },
19
+ {
20
+ name: 'locale',
21
+ flags: {
22
+ multiple: true,
23
+ },
24
+ yargsOptions: {
25
+ alias: 'l',
26
+ type: 'array',
27
+ describe: gtx._("list of locales"),
28
+ },
29
+ },
30
+ {
31
+ name: 'directory',
32
+ yargsOptions: {
33
+ alias: 'D',
34
+ type: 'string',
35
+ describe: gtx._("search '.po' files in DIRECTORY"),
36
+ },
37
+ },
38
+ ],
39
+ },
40
+ {
41
+ description: gtx._('Mode of operation:'),
42
+ options: [
43
+ {
44
+ name: 'msgmerge',
45
+ yargsOptions: {
46
+ type: 'string',
47
+ default: 'msgmerge',
48
+ describe: gtx._("msgmerge program if not in PATH"),
49
+ },
50
+ },
51
+ {
52
+ name: 'options',
53
+ flags: {
54
+ multiple: true,
55
+ },
56
+ yargsOptions: {
57
+ type: 'string',
58
+ describe: gtx._("options to pass to msgmerge"),
59
+ },
60
+ },
61
+ ],
62
+ },
63
+ ];
64
+ var usage = gtx._('[OPTIONS] ref.pot');
65
+ var description = gtx._("Invoke 'msgmerge' for multiple files.");
66
+ var getopt = new getopt_1.Getopt(usage, description, optionGroups, {
67
+ hasVerboseOption: true,
68
+ });
69
+ var msgmergeAll;
70
+ try {
71
+ msgmergeAll = new msgmerge_all_1.MsgmergeAll(getopt.argv());
72
+ }
73
+ catch (error) {
74
+ console.warn(gtx._x('{programName}: {error}', {
75
+ error: error,
76
+ programName: getopt.programName,
77
+ }));
78
+ console.error(gtx._x('Try "{programName} --help" for more information!', {
79
+ programName: getopt.programName,
80
+ }));
81
+ process.exit(2);
82
+ }
83
+ msgmergeAll.run().then(function (exitCode) { return process.exit(exitCode); });
84
+ });
85
+ //# sourceMappingURL=msgmerge-all.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"msgmerge-all.js","sourceRoot":"","sources":["../../src/cli/msgmerge-all.ts"],"names":[],"mappings":";;AAAA,8CAAgD;AAChD,6DAA2D;AAC3D,mCAA+C;AAI/C,IAAM,GAAG,GAAG,oBAAU,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;AAC5C,GAAG,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC;IAClB,IAAM,YAAY,GAAuB;QACxC;YACC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC,qBAAqB,CAAC;YACzC,OAAO,EAAE;gBACR;oBACC,IAAI,EAAE,cAAc;oBACpB,YAAY,EAAE;wBACb,IAAI,EAAE,QAAQ;wBACd,QAAQ,EAAE,GAAG,CAAC,CAAC,CAAC,oFAAoF,CAAC;qBACrG;iBACD;gBACD;oBACC,IAAI,EAAE,QAAQ;oBACd,KAAK,EAAE;wBACN,QAAQ,EAAE,IAAI;qBACd;oBACD,YAAY,EAAE;wBACb,KAAK,EAAE,GAAG;wBACV,IAAI,EAAE,OAAO;wBACb,QAAQ,EAAE,GAAG,CAAC,CAAC,CACd,iBAAiB,CACjB;qBACD;iBACD;gBACD;oBACC,IAAI,EAAE,WAAW;oBACjB,YAAY,EAAE;wBACb,KAAK,EAAE,GAAG;wBACV,IAA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AAC,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACjB,CAAC;IAED,WAAW,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,UAAA,QAAQ,IAAI,OAAA,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAtB,CAAsB,CAAC,CAAC;AAC5D,CAAC,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,303 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var runtime_1 = require("@esgettext/runtime");
4
+ var xgettext_1 = require("../xgettext/xgettext");
5
+ var getopt_1 = require("./getopt");
6
+ var gtx = runtime_1.Textdomain.getInstance('tools');
7
+ gtx
8
+ .resolve()
9
+ .then(function () {
10
+ var optionGroups = [
11
+ {
12
+ description: gtx._('Input file location:'),
13
+ options: [
14
+ {
15
+ name: 'files-from',
16
+ flags: { multiple: true },
17
+ yargsOptions: {
18
+ type: 'string',
19
+ describe: gtx._('get list of input files from FILE'),
20
+ },
21
+ },
22
+ {
23
+ name: 'directory',
24
+ flags: { multiple: true },
25
+ yargsOptions: {
26
+ alias: 'D',
27
+ type: 'string',
28
+ describe: gtx._('add DIRECTORY to list for input files search\nIf input file is -, standard input is read.'),
29
+ },
30
+ },
31
+ ],
32
+ },
33
+ {
34
+ description: gtx._('Output file location:'),
35
+ options: [
36
+ {
37
+ name: 'default-domain',
38
+ yargsOptions: {
39
+ alias: 'd',
40
+ type: 'string',
41
+ describe: gtx._('use NAME.po for output (instead of messages.po)'),
42
+ },
43
+ },
44
+ {
45
+ name: 'output',
46
+ yargsOptions: {
47
+ alias: 'o',
48
+ type: 'string',
49
+ describe: gtx._('write output to specified file'),
50
+ },
51
+ },
52
+ {
53
+ name: 'output-dir',
54
+ yargsOptions: {
55
+ alias: 'p',
56
+ type: 'string',
57
+ describe: gtx._('output files will be placed in directory DIR\nIf output file is -, output is written to standard output.'),
58
+ },
59
+ },
60
+ ],
61
+ },
62
+ {
63
+ description: gtx._('Choice of input file language:'),
64
+ options: [
65
+ {
66
+ name: 'language',
67
+ yargsOptions: {
68
+ alias: 'L',
69
+ type: 'string',
70
+ describe: gtx._('recognise the specified language (JavaScript, TypeScript, HTML)\nDefault is to auto-detect language based on filename extension.'),
71
+ },
72
+ },
73
+ ],
74
+ },
75
+ {
76
+ description: gtx._('Interpretation of input files:'),
77
+ options: [
78
+ {
79
+ name: 'from-code',
80
+ yargsOptions: {
81
+ type: 'string',
82
+ describe: gtx._('encoding of input files'),
83
+ default: 'ASCII',
84
+ },
85
+ },
86
+ ],
87
+ },
88
+ {
89
+ description: gtx._('Operation mode:'),
90
+ options: [
91
+ {
92
+ name: 'join-existing',
93
+ yargsOptions: {
94
+ alias: 'j',
95
+ type: 'boolean',
96
+ describe: gtx._('join messages with existing file'),
97
+ },
98
+ },
99
+ {
100
+ name: 'exclude-file',
101
+ flags: { multiple: true },
102
+ yargsOptions: {
103
+ alias: 'x',
104
+ type: 'string',
105
+ describe: gtx._('entries from FILE.po are not extracted'),
106
+ },
107
+ },
108
+ {
109
+ name: 'add-comments',
110
+ flags: { multiple: true },
111
+ yargsOptions: {
112
+ alias: 'c',
113
+ type: 'string',
114
+ describe: gtx._('place comment blocks starting with TAG and preceding keyword lines in output file'),
115
+ },
116
+ },
117
+ {
118
+ name: 'add-all-comments',
119
+ yargsOptions: {
120
+ describe: gtx._('place all comment blocks preceding keyword lines in output file'),
121
+ type: 'boolean',
122
+ },
123
+ },
124
+ ],
125
+ },
126
+ {
127
+ description: gtx._('Language specific options:'),
128
+ options: [
129
+ {
130
+ name: 'extract-all',
131
+ yargsOptions: {
132
+ alias: 'a',
133
+ type: 'boolean',
134
+ describe: gtx._('extract all strings'),
135
+ },
136
+ },
137
+ {
138
+ name: 'keyword',
139
+ flags: { multiple: true },
140
+ yargsOptions: {
141
+ alias: 'k',
142
+ type: 'string',
143
+ describe: gtx._('look for WORD as an additional keyword'),
144
+ },
145
+ },
146
+ {
147
+ name: 'flag',
148
+ flags: { multiple: true },
149
+ yargsOptions: {
150
+ type: 'string',
151
+ describe: gtx._('argument: WORD:ARG:FLAG, additional flag for strings inside the argument number ARG of keyword WORD'),
152
+ },
153
+ },
154
+ {
155
+ name: 'instance',
156
+ flags: { multiple: true },
157
+ yargsOptions: {
158
+ type: 'string',
159
+ describe: gtx._('only accept method calls of specified instance names'),
160
+ },
161
+ },
162
+ ],
163
+ },
164
+ {
165
+ description: gtx._('Output details'),
166
+ options: [
167
+ {
168
+ name: 'force-po',
169
+ yargsOptions: {
170
+ type: 'boolean',
171
+ describe: gtx._('write PO file even if empty'),
172
+ },
173
+ },
174
+ {
175
+ name: 'width',
176
+ yargsOptions: {
177
+ alias: 'w',
178
+ type: 'number',
179
+ describe: gtx._('set output page width'),
180
+ },
181
+ },
182
+ {
183
+ name: 'no-wrap',
184
+ yargsOptions: {
185
+ type: 'boolean',
186
+ describe: gtx._('do not break long message lines,' +
187
+ ' longer than' +
188
+ ' the output page width, into' +
189
+ ' several lines'),
190
+ },
191
+ },
192
+ {
193
+ name: 'sort-output',
194
+ yargsOptions: {
195
+ alias: 's',
196
+ type: 'boolean',
197
+ describe: gtx._('generate sorted output'),
198
+ },
199
+ },
200
+ {
201
+ name: 'sort-by-file',
202
+ yargsOptions: {
203
+ alias: 'F',
204
+ type: 'boolean',
205
+ describe: gtx._('sort output by file location'),
206
+ },
207
+ },
208
+ {
209
+ name: 'omit-header',
210
+ yargsOptions: {
211
+ type: 'boolean',
212
+ describe: gtx._("don't write header with msgid '\"\"' entry"),
213
+ },
214
+ },
215
+ {
216
+ name: 'package-json',
217
+ yargsOptions: {
218
+ type: 'string',
219
+ describe: gtx._("read package information from PACKAGE_JSON (or 'package.json' without an argument)"),
220
+ }
221
+ },
222
+ {
223
+ name: 'copyright-holder',
224
+ yargsOptions: {
225
+ type: 'string',
226
+ describe: gtx._('set copyright holder in output'),
227
+ },
228
+ },
229
+ {
230
+ name: 'foreign-user',
231
+ yargsOptions: {
232
+ type: 'string',
233
+ describe: gtx._('omit FSF copyright in output for foreign user'),
234
+ },
235
+ },
236
+ {
237
+ name: 'package-name',
238
+ yargsOptions: {
239
+ type: 'string',
240
+ describe: gtx._('set package name in output'),
241
+ },
242
+ },
243
+ {
244
+ name: 'package-version',
245
+ yargsOptions: {
246
+ type: 'string',
247
+ describe: gtx._('set package name in output'),
248
+ },
249
+ },
250
+ {
251
+ name: 'msgid-bugs-address',
252
+ yargsOptions: {
253
+ type: 'string',
254
+ describe: gtx._('set report address for msgid bugs'),
255
+ },
256
+ },
257
+ {
258
+ name: 'msgstr-prefix',
259
+ yargsOptions: {
260
+ alias: 'm',
261
+ type: 'string',
262
+ describe: gtx._('use STRING or "" as prefix for msgstr values'),
263
+ },
264
+ },
265
+ {
266
+ name: 'msgstr-suffix',
267
+ yargsOptions: {
268
+ alias: 'M',
269
+ type: 'string',
270
+ describe: gtx._('use STRING or "" as suffix for msgstr values'),
271
+ },
272
+ },
273
+ ],
274
+ },
275
+ ];
276
+ var usage = gtx._x('[OPTIONS] [INPUTFILE]...');
277
+ var description = gtx._('Extract translatable strings from given input files');
278
+ var getopt = new getopt_1.Getopt(usage, description, optionGroups, {
279
+ hasVerboseOption: true,
280
+ });
281
+ var xgettext;
282
+ try {
283
+ xgettext = new xgettext_1.XGettext(getopt.argv());
284
+ }
285
+ catch (error) {
286
+ console.warn(gtx._x('{programName}: {error}', {
287
+ error: error,
288
+ programName: getopt.programName,
289
+ }));
290
+ console.error(gtx._x('Try "{programName} --help" for more information!', {
291
+ programName: getopt.programName,
292
+ }));
293
+ process.exit(2);
294
+ }
295
+ process.exit(xgettext.run());
296
+ })
297
+ .catch(function (exception) {
298
+ console.error(gtx._x('{programName}: unhandled exception: {exception}', {
299
+ programName: 'esgettext-xgettext',
300
+ exception: exception,
301
+ }));
302
+ });
303
+ //# sourceMappingURL=xgettext-cli.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"xgettext-cli.js","sourceRoot":"","sources":["../../src/cli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G,IAAI,mBAAQ,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC;IACxC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QAChB,OAAO,CAAC,IAAI,CACX,GAAG,CAAC,EAAE,CAAC,wBAAwB,EAAE;YAChC,KAAK,OAAA;YACL,WAAW,EAAE,MAAM,CAAC,WAAW;SAC/B,CAAC,CACF,CAAC;QACF,OAAO,CAAC,KAAK,CACZ,GAAG,CAAC,EAAE,CAAC,kDAAkD,EAAE;YAC1D,WAAW,EAAE,MAAM,CAAC,WAAW;SAC/B,CAAC,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACjB,CAAC;IAED,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,EAAE,CAAC,CAAC;AAC9B,CAAC,CAAC;KACD,KAAK,CAAC,UAAA,SAAS;IACf,OAAO,CAAC,KAAK,CACZ,GAAG,CAAC,EAAE,CAAC,iDAAiD,EAAE;QACzD,WAAW,EAAE,oBAAoB;QACjC,SAAS,WAAA;KACT,CAAC,CACF,CAAC;AACH,CAAC,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ import { Options } from '../cli/getopt';
2
+ export declare class Install {
3
+ private readonly options;
4
+ private readonly locales;
5
+ constructor(options: Options);
6
+ private installMoLocale;
7
+ private installJsonLocale;
8
+ private installLocale;
9
+ run(): Promise<number>;
10
+ }