innetjs 2.2.4 → 2.2.6

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.
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  (function() {
4
- const env = {"INNETJS_INNETJS_PACKAGE_VERSION":"2.2.3"};
4
+ const env = {"INNETJS_INNETJS_PACKAGE_VERSION":"2.2.6"};
5
5
  try {
6
6
  if (process) {
7
7
  process.env = Object.assign({}, process.env);
@@ -1,5 +1,5 @@
1
1
  (function() {
2
- const env = {"INNETJS_INNETJS_PACKAGE_VERSION":"2.2.3"};
2
+ const env = {"INNETJS_INNETJS_PACKAGE_VERSION":"2.2.6"};
3
3
  try {
4
4
  if (process) {
5
5
  process.env = Object.assign({}, process.env);
package/bin/innet CHANGED
@@ -68,7 +68,7 @@ var typescript__default = /*#__PURE__*/_interopDefaultLegacy(typescript);
68
68
  var tmp__default = /*#__PURE__*/_interopDefaultLegacy(tmp);
69
69
 
70
70
  (function() {
71
- const env = {"INNETJS_INNETJS_PACKAGE_VERSION":"2.2.3"};
71
+ const env = {"INNETJS_INNETJS_PACKAGE_VERSION":"2.2.6"};
72
72
  try {
73
73
  if (process) {
74
74
  process.env = Object.assign({}, process.env);
@@ -184,14 +184,22 @@ const reporter = (options, outputOptions, info) => {
184
184
  return '';
185
185
  };
186
186
 
187
+ function updateDotenv() {
188
+ const { INNETJS_INNETJS_PACKAGE_VERSION } = process.env;
189
+ delete process.env.INNETJS_INNETJS_PACKAGE_VERSION;
190
+ require('dotenv-expand').expand(require('dotenv').config());
191
+ if (!('INNETJS_INNETJS_PACKAGE_VERSION' in process.env)) {
192
+ process.env.INNETJS_INNETJS_PACKAGE_VERSION = INNETJS_INNETJS_PACKAGE_VERSION;
193
+ }
194
+ }
195
+
187
196
  const livereload = require('rollup-plugin-livereload');
188
197
  const { string } = require('rollup-plugin-string');
189
198
  const { exec, spawn } = require('child_process');
190
199
  const readline = require('readline');
191
200
  const execAsync = node_util.promisify(exec);
192
201
  const copyFiles = node_util.promisify(fs__default["default"].copy);
193
- const dotenvConfigOutput$1 = require('dotenv').config();
194
- require('dotenv-expand').expand(dotenvConfigOutput$1);
202
+ updateDotenv();
195
203
  const REG_CLEAR_TEXT = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
196
204
  function normalizeEnv(value) {
197
205
  if (value) {
@@ -758,8 +766,7 @@ class InnetJS {
758
766
  }
759
767
  }
760
768
 
761
- const dotenvConfigOutput = require('dotenv').config();
762
- require('dotenv-expand').expand(dotenvConfigOutput);
769
+ updateDotenv();
763
770
  const innetJS = new InnetJS();
764
771
  const errorOption = new commander.Option('-e, --error', 'Show error details');
765
772
  const releaseOption = new commander.Option('-r, --release <release>', 'Select release type')
package/index.js CHANGED
@@ -39,6 +39,7 @@ var node_util = require('node:util');
39
39
  var constants = require('./constants.js');
40
40
  var extract = require('./extract.js');
41
41
  var helpers = require('./helpers.js');
42
+ var updateDotenv = require('./updateDotenv.js');
42
43
 
43
44
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
44
45
 
@@ -76,8 +77,7 @@ const { exec, spawn } = require('child_process');
76
77
  const readline = require('readline');
77
78
  const execAsync = node_util.promisify(exec);
78
79
  const copyFiles = node_util.promisify(fs__default["default"].copy);
79
- const dotenvConfigOutput = require('dotenv').config();
80
- require('dotenv-expand').expand(dotenvConfigOutput);
80
+ updateDotenv.updateDotenv();
81
81
  const REG_CLEAR_TEXT = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
82
82
  function normalizeEnv(value) {
83
83
  if (value) {
package/index.mjs CHANGED
@@ -35,6 +35,7 @@ import { promisify } from 'node:util';
35
35
  import { lintInclude, stringExcludeNode, stringExcludeDom } from './constants.mjs';
36
36
  import { Extract } from './extract.mjs';
37
37
  import { reporter, convertIndexFile, getFile } from './helpers.mjs';
38
+ import { updateDotenv } from './updateDotenv.mjs';
38
39
 
39
40
  const livereload = require('rollup-plugin-livereload');
40
41
  const { string } = require('rollup-plugin-string');
@@ -42,8 +43,7 @@ const { exec, spawn } = require('child_process');
42
43
  const readline = require('readline');
43
44
  const execAsync = promisify(exec);
44
45
  const copyFiles = promisify(fs.copy);
45
- const dotenvConfigOutput = require('dotenv').config();
46
- require('dotenv-expand').expand(dotenvConfigOutput);
46
+ updateDotenv();
47
47
  const REG_CLEAR_TEXT = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
48
48
  function normalizeEnv(value) {
49
49
  if (value) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "innetjs",
3
- "version": "2.2.4",
3
+ "version": "2.2.6",
4
4
  "description": "CLI for innet boilerplate",
5
5
  "homepage": "https://github.com/d8corp/innetjs",
6
6
  "author": "Mikhail Lysikov <d8corp@mail.ru>",
@@ -21,9 +21,10 @@
21
21
  "start": "npm run build && cd release && npm link",
22
22
  "stop": "npm unlink innetjs -g",
23
23
  "restart": "npm run stop && npm start",
24
- "patch": "innetjs release -n -p -r patch",
25
- "minor": "innetjs release -n -p -r minor",
26
- "major": "innetjs release -n -p -r major"
24
+ "release": "innetjs release -n -p",
25
+ "patch": "innetjs patch",
26
+ "minor": "innetjs minor",
27
+ "major": "innetjs major"
27
28
  },
28
29
  "repository": {
29
30
  "type": "git",
@@ -0,0 +1 @@
1
+ export declare function updateDotenv(): void;
@@ -0,0 +1,16 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ require('./_virtual/_rollup-plugin-inject-process-env.js');
6
+
7
+ function updateDotenv() {
8
+ const { INNETJS_INNETJS_PACKAGE_VERSION } = process.env;
9
+ delete process.env.INNETJS_INNETJS_PACKAGE_VERSION;
10
+ require('dotenv-expand').expand(require('dotenv').config());
11
+ if (!('INNETJS_INNETJS_PACKAGE_VERSION' in process.env)) {
12
+ process.env.INNETJS_INNETJS_PACKAGE_VERSION = INNETJS_INNETJS_PACKAGE_VERSION;
13
+ }
14
+ }
15
+
16
+ exports.updateDotenv = updateDotenv;
@@ -0,0 +1,12 @@
1
+ import './_virtual/_rollup-plugin-inject-process-env.mjs';
2
+
3
+ function updateDotenv() {
4
+ const { INNETJS_INNETJS_PACKAGE_VERSION } = process.env;
5
+ delete process.env.INNETJS_INNETJS_PACKAGE_VERSION;
6
+ require('dotenv-expand').expand(require('dotenv').config());
7
+ if (!('INNETJS_INNETJS_PACKAGE_VERSION' in process.env)) {
8
+ process.env.INNETJS_INNETJS_PACKAGE_VERSION = INNETJS_INNETJS_PACKAGE_VERSION;
9
+ }
10
+ }
11
+
12
+ export { updateDotenv };