@naturalcycles/dev-lib 12.16.6 → 12.17.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.
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.generateBuildInfo = void 0;
|
|
4
|
-
const
|
|
4
|
+
const js_lib_1 = require("@naturalcycles/js-lib");
|
|
5
5
|
const git_util_1 = require("./git.util");
|
|
6
6
|
async function generateBuildInfo(dev = false) {
|
|
7
|
-
const now = (0,
|
|
7
|
+
const now = (0, js_lib_1.localTime)();
|
|
8
8
|
const [rev, branchName, repoName, tsCommit] = dev
|
|
9
9
|
? ['devRev', 'devBranch', 'devRepo', now.unix()]
|
|
10
10
|
: await Promise.all([
|
|
@@ -15,7 +15,7 @@ async function generateBuildInfo(dev = false) {
|
|
|
15
15
|
]);
|
|
16
16
|
const ts = now.unix();
|
|
17
17
|
const tsStr = now.toPretty();
|
|
18
|
-
const ver = [now.
|
|
18
|
+
const ver = [now.toStringCompact(), repoName, branchName, rev].join('_');
|
|
19
19
|
return {
|
|
20
20
|
ts,
|
|
21
21
|
tsCommit,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@naturalcycles/dev-lib",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.17.0",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"prepare": "husky install",
|
|
6
6
|
"tsn-debug": "tsn testScript.ts",
|
|
@@ -35,7 +35,6 @@
|
|
|
35
35
|
"@naturalcycles/cli": "^1.0.0",
|
|
36
36
|
"@naturalcycles/js-lib": "^14.0.0",
|
|
37
37
|
"@naturalcycles/nodejs-lib": "^12.0.0",
|
|
38
|
-
"@naturalcycles/time-lib": "^3.0.1",
|
|
39
38
|
"@types/fs-extra": "^9.0.0",
|
|
40
39
|
"@types/jest": "^27.0.0",
|
|
41
40
|
"@types/node": "^17.0.0",
|