@powerlines/plugin-date 0.2.0 → 0.4.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.
- package/dist/components/date-fns.cjs +2 -2
- package/dist/components/date-fns.d.cts +2 -2
- package/dist/components/date-fns.d.ts +2 -2
- package/dist/components/date-fns.js +2 -2
- package/dist/components/dayjs.cjs +4 -4
- package/dist/components/dayjs.d.cts +2 -2
- package/dist/components/dayjs.d.ts +2 -2
- package/dist/components/dayjs.js +4 -4
- package/dist/components/index.d.cts +2 -2
- package/dist/components/index.d.ts +2 -2
- package/dist/components/luxon.cjs +4 -4
- package/dist/components/luxon.d.cts +2 -2
- package/dist/components/luxon.d.ts +2 -2
- package/dist/components/luxon.js +4 -4
- package/dist/components/moment.cjs +4 -4
- package/dist/components/moment.d.cts +2 -2
- package/dist/components/moment.d.ts +2 -2
- package/dist/components/moment.js +4 -4
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/types/plugin.d.cts +23 -34
- package/dist/types/plugin.d.ts +23 -34
- package/package.json +6 -7
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
|
|
7
7
|
function d(e){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
11
|
* @module ${e.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${fileHeader.getFileHeader()}
|
|
14
|
+
${fileHeader.getFileHeader(e)}
|
|
15
15
|
|
|
16
16
|
import { DateFormats, TimeUnit } from "@powerlines/plugin-date/types/runtime";
|
|
17
17
|
import { addDays as dateFnsAddDays } from "date-fns/addDays";
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -6,12 +6,12 @@ import {a}from'../chunk-UCUR73HG.js';import {getFileHeader}from'powerlines/lib/u
|
|
|
6
6
|
|
|
7
7
|
function u(e){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
11
|
* @module ${e.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${getFileHeader()}
|
|
14
|
+
${getFileHeader(e)}
|
|
15
15
|
|
|
16
16
|
import { DateFormats, TimeUnit } from "@powerlines/plugin-date/types/runtime";
|
|
17
17
|
import { addDays as dateFnsAddDays } from "date-fns/addDays";
|
|
@@ -4,14 +4,14 @@
|
|
|
4
4
|
*
|
|
5
5
|
*****************************************/
|
|
6
6
|
|
|
7
|
-
function u(
|
|
7
|
+
function u(t){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
|
-
* @module ${
|
|
11
|
+
* @module ${t.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${fileHeader.getFileHeader()}
|
|
14
|
+
${fileHeader.getFileHeader(t)}
|
|
15
15
|
|
|
16
16
|
import defaultDayjs, { QUnitType } from "dayjs";
|
|
17
17
|
import customParseFormatPlugin from "dayjs/plugin/customParseFormat";
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
package/dist/components/dayjs.js
CHANGED
|
@@ -4,14 +4,14 @@ import {a}from'../chunk-UCUR73HG.js';import {getFileHeader}from'powerlines/lib/u
|
|
|
4
4
|
*
|
|
5
5
|
*****************************************/
|
|
6
6
|
|
|
7
|
-
function d(
|
|
7
|
+
function d(t){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
|
-
* @module ${
|
|
11
|
+
* @module ${t.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${getFileHeader()}
|
|
14
|
+
${getFileHeader(t)}
|
|
15
15
|
|
|
16
16
|
import defaultDayjs, { QUnitType } from "dayjs";
|
|
17
17
|
import customParseFormatPlugin from "dayjs/plugin/customParseFormat";
|
|
@@ -16,14 +16,14 @@ import '@stryke/env/get-env-paths';
|
|
|
16
16
|
import '@stryke/types/package-json';
|
|
17
17
|
import 'jiti';
|
|
18
18
|
import '@deepkit/type';
|
|
19
|
+
import 'semver';
|
|
19
20
|
import 'unplugin';
|
|
20
21
|
import '@stryke/capnp';
|
|
21
22
|
import '@stryke/types/base';
|
|
22
23
|
import '@stryke/types/tsconfig';
|
|
23
24
|
import 'typescript';
|
|
24
|
-
import 'semver';
|
|
25
|
-
import '@stryke/types/array';
|
|
26
25
|
import 'memfs';
|
|
27
26
|
import 'node:fs';
|
|
28
27
|
import 'unionfs';
|
|
28
|
+
import '@stryke/types/array';
|
|
29
29
|
import '@stryke/env/types';
|
|
@@ -16,14 +16,14 @@ import '@stryke/env/get-env-paths';
|
|
|
16
16
|
import '@stryke/types/package-json';
|
|
17
17
|
import 'jiti';
|
|
18
18
|
import '@deepkit/type';
|
|
19
|
+
import 'semver';
|
|
19
20
|
import 'unplugin';
|
|
20
21
|
import '@stryke/capnp';
|
|
21
22
|
import '@stryke/types/base';
|
|
22
23
|
import '@stryke/types/tsconfig';
|
|
23
24
|
import 'typescript';
|
|
24
|
-
import 'semver';
|
|
25
|
-
import '@stryke/types/array';
|
|
26
25
|
import 'memfs';
|
|
27
26
|
import 'node:fs';
|
|
28
27
|
import 'unionfs';
|
|
28
|
+
import '@stryke/types/array';
|
|
29
29
|
import '@stryke/env/types';
|
|
@@ -4,14 +4,14 @@
|
|
|
4
4
|
*
|
|
5
5
|
*****************************************/
|
|
6
6
|
|
|
7
|
-
function i(
|
|
7
|
+
function i(e){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
|
-
* @module ${
|
|
11
|
+
* @module ${e.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${fileHeader.getFileHeader()}
|
|
14
|
+
${fileHeader.getFileHeader(e)}
|
|
15
15
|
|
|
16
16
|
import { DateTime, Settings, Info } from "luxon";
|
|
17
17
|
import {
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
package/dist/components/luxon.js
CHANGED
|
@@ -4,14 +4,14 @@ import {a}from'../chunk-UCUR73HG.js';import {getFileHeader}from'powerlines/lib/u
|
|
|
4
4
|
*
|
|
5
5
|
*****************************************/
|
|
6
6
|
|
|
7
|
-
function m(
|
|
7
|
+
function m(e){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
|
-
* @module ${
|
|
11
|
+
* @module ${e.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${getFileHeader()}
|
|
14
|
+
${getFileHeader(e)}
|
|
15
15
|
|
|
16
16
|
import { DateTime, Settings, Info } from "luxon";
|
|
17
17
|
import {
|
|
@@ -4,14 +4,14 @@
|
|
|
4
4
|
*
|
|
5
5
|
*****************************************/
|
|
6
6
|
|
|
7
|
-
function m(
|
|
7
|
+
function m(e){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
|
-
* @module ${
|
|
11
|
+
* @module ${e.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${fileHeader.getFileHeader()}
|
|
14
|
+
${fileHeader.getFileHeader(e)}
|
|
15
15
|
|
|
16
16
|
import defaultMoment, { LongDateFormatKey } from "moment";
|
|
17
17
|
import {
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -12,16 +12,16 @@ import '@stryke/env/get-env-paths';
|
|
|
12
12
|
import '@stryke/types/package-json';
|
|
13
13
|
import 'jiti';
|
|
14
14
|
import '@deepkit/type';
|
|
15
|
+
import 'semver';
|
|
15
16
|
import 'unplugin';
|
|
16
17
|
import '@stryke/capnp';
|
|
17
18
|
import '@stryke/types/base';
|
|
18
19
|
import '@stryke/types/tsconfig';
|
|
19
20
|
import 'typescript';
|
|
20
|
-
import 'semver';
|
|
21
|
-
import '@stryke/types/array';
|
|
22
21
|
import 'memfs';
|
|
23
22
|
import 'node:fs';
|
|
24
23
|
import 'unionfs';
|
|
24
|
+
import '@stryke/types/array';
|
|
25
25
|
import '@stryke/env/types';
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -4,14 +4,14 @@ import {a}from'../chunk-UCUR73HG.js';import {getFileHeader}from'powerlines/lib/u
|
|
|
4
4
|
*
|
|
5
5
|
*****************************************/
|
|
6
6
|
|
|
7
|
-
function d(
|
|
7
|
+
function d(e){return `
|
|
8
8
|
/**
|
|
9
|
-
* The
|
|
9
|
+
* The Date module provides utility functions for date manipulation and formatting
|
|
10
10
|
*
|
|
11
|
-
* @module ${
|
|
11
|
+
* @module ${e.config.output.builtinPrefix}:date
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
${getFileHeader()}
|
|
14
|
+
${getFileHeader(e)}
|
|
15
15
|
|
|
16
16
|
import defaultMoment, { LongDateFormatKey } from "moment";
|
|
17
17
|
import {
|
package/dist/types/index.d.cts
CHANGED
|
@@ -13,14 +13,14 @@ import '@stryke/env/get-env-paths';
|
|
|
13
13
|
import '@stryke/types/package-json';
|
|
14
14
|
import 'jiti';
|
|
15
15
|
import '@deepkit/type';
|
|
16
|
+
import 'semver';
|
|
16
17
|
import 'unplugin';
|
|
17
18
|
import '@stryke/capnp';
|
|
18
19
|
import '@stryke/types/base';
|
|
19
20
|
import '@stryke/types/tsconfig';
|
|
20
21
|
import 'typescript';
|
|
21
|
-
import 'semver';
|
|
22
|
-
import '@stryke/types/array';
|
|
23
22
|
import 'memfs';
|
|
24
23
|
import 'node:fs';
|
|
25
24
|
import 'unionfs';
|
|
25
|
+
import '@stryke/types/array';
|
|
26
26
|
import '@stryke/env/types';
|
package/dist/types/index.d.ts
CHANGED
|
@@ -13,14 +13,14 @@ import '@stryke/env/get-env-paths';
|
|
|
13
13
|
import '@stryke/types/package-json';
|
|
14
14
|
import 'jiti';
|
|
15
15
|
import '@deepkit/type';
|
|
16
|
+
import 'semver';
|
|
16
17
|
import 'unplugin';
|
|
17
18
|
import '@stryke/capnp';
|
|
18
19
|
import '@stryke/types/base';
|
|
19
20
|
import '@stryke/types/tsconfig';
|
|
20
21
|
import 'typescript';
|
|
21
|
-
import 'semver';
|
|
22
|
-
import '@stryke/types/array';
|
|
23
22
|
import 'memfs';
|
|
24
23
|
import 'node:fs';
|
|
25
24
|
import 'unionfs';
|
|
25
|
+
import '@stryke/types/array';
|
|
26
26
|
import '@stryke/env/types';
|
package/dist/types/plugin.d.cts
CHANGED
|
@@ -11,16 +11,16 @@ import { EnvPaths } from '@stryke/env/get-env-paths';
|
|
|
11
11
|
import { PackageJson } from '@stryke/types/package-json';
|
|
12
12
|
import { Jiti } from 'jiti';
|
|
13
13
|
import { ReflectionClass } from '@deepkit/type';
|
|
14
|
+
import { Range } from 'semver';
|
|
14
15
|
import { TransformResult, ExternalIdResult, HookFilter, UnpluginOptions, UnpluginContext, UnpluginBuildContext } from 'unplugin';
|
|
15
16
|
import * as $ from '@stryke/capnp';
|
|
16
17
|
import { NonUndefined, MaybePromise, FunctionLike } from '@stryke/types/base';
|
|
17
18
|
import { TsConfigJson, CompilerOptions } from '@stryke/types/tsconfig';
|
|
18
19
|
import ts from 'typescript';
|
|
19
|
-
import { Range } from 'semver';
|
|
20
|
-
import { ArrayValues } from '@stryke/types/array';
|
|
21
20
|
import { Volume } from 'memfs';
|
|
22
21
|
import { StatSyncOptions, Stats, PathLike, RmDirOptions, RmOptions, Mode, MakeDirectoryOptions as MakeDirectoryOptions$1, PathOrFileDescriptor, WriteFileOptions as WriteFileOptions$1 } from 'node:fs';
|
|
23
22
|
import { IUnionFs } from 'unionfs';
|
|
23
|
+
import { ArrayValues } from '@stryke/types/array';
|
|
24
24
|
import { DotenvParseOutput } from '@stryke/env/types';
|
|
25
25
|
|
|
26
26
|
declare const ReflectionKind: {
|
|
@@ -1657,7 +1657,7 @@ type OutputResolvedConfig = Required<Omit<OutputConfig, "assets"> & {
|
|
|
1657
1657
|
/**
|
|
1658
1658
|
* The resolved options for the Powerlines project configuration.
|
|
1659
1659
|
*/
|
|
1660
|
-
type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "build" | "transform" | "override" | "root" | "variant" | "type" | "output" | "logLevel"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "build" | "transform" | "override">> & {
|
|
1660
|
+
type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "build" | "transform" | "override" | "root" | "variant" | "type" | "output" | "logLevel" | "framework"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "build" | "transform" | "override" | "framework">> & {
|
|
1661
1661
|
/**
|
|
1662
1662
|
* The configuration options that were provided inline to the Powerlines CLI.
|
|
1663
1663
|
*/
|
|
@@ -1703,11 +1703,6 @@ type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserCon
|
|
|
1703
1703
|
declare const SUPPORTED_COMMANDS: readonly ["new", "clean", "prepare", "lint", "test", "build", "docs", "release", "finalize"];
|
|
1704
1704
|
type CommandType = ArrayValues<typeof SUPPORTED_COMMANDS>;
|
|
1705
1705
|
|
|
1706
|
-
type PackageDependencyMeta = "dependency" | "devDependency" | {
|
|
1707
|
-
version?: string | Range;
|
|
1708
|
-
type?: "dependency" | "devDependency";
|
|
1709
|
-
};
|
|
1710
|
-
type PackageDependencies = Record<string, PackageDependencyMeta>;
|
|
1711
1706
|
interface PluginHookObject<THookFunction extends FunctionLike, TFilter extends keyof HookFilter | undefined = undefined> {
|
|
1712
1707
|
/**
|
|
1713
1708
|
* The order in which the plugin should be applied.
|
|
@@ -2432,13 +2427,6 @@ interface Context<TResolvedConfig extends ResolvedConfig = ResolvedConfig> {
|
|
|
2432
2427
|
* The relative path to the Powerlines workspace root directory
|
|
2433
2428
|
*/
|
|
2434
2429
|
relativeToWorkspaceRoot: string;
|
|
2435
|
-
/**
|
|
2436
|
-
* The path to the \powerlines package
|
|
2437
|
-
*
|
|
2438
|
-
* @remarks
|
|
2439
|
-
* This is used to determine the path to the Powerlines core package, which contains the runtime files.
|
|
2440
|
-
*/
|
|
2441
|
-
corePackagePath: string;
|
|
2442
2430
|
/**
|
|
2443
2431
|
* The Powerlines artifacts directory
|
|
2444
2432
|
*/
|
|
@@ -2468,9 +2456,17 @@ interface Context<TResolvedConfig extends ResolvedConfig = ResolvedConfig> {
|
|
|
2468
2456
|
*/
|
|
2469
2457
|
envPaths: EnvPaths;
|
|
2470
2458
|
/**
|
|
2471
|
-
* The
|
|
2459
|
+
* The file system path to the Powerlines package installation
|
|
2460
|
+
*/
|
|
2461
|
+
powerlinesPath: string;
|
|
2462
|
+
/**
|
|
2463
|
+
* The dependency installations required by the project
|
|
2464
|
+
*/
|
|
2465
|
+
dependencies: Record<string, string | Range>;
|
|
2466
|
+
/**
|
|
2467
|
+
* The development dependency installations required by the project
|
|
2472
2468
|
*/
|
|
2473
|
-
|
|
2469
|
+
devDependencies: Record<string, string | Range>;
|
|
2474
2470
|
/**
|
|
2475
2471
|
* The project's `package.json` file content
|
|
2476
2472
|
*/
|
|
@@ -2626,14 +2622,14 @@ interface OutputConfig {
|
|
|
2626
2622
|
*/
|
|
2627
2623
|
builtinPrefix?: string;
|
|
2628
2624
|
/**
|
|
2629
|
-
* The folder where the generated runtime
|
|
2625
|
+
* The folder where the generated runtime artifacts will be located
|
|
2630
2626
|
*
|
|
2631
2627
|
* @remarks
|
|
2632
|
-
* This folder will contain all runtime
|
|
2628
|
+
* This folder will contain all runtime artifacts and builtins generated during the "prepare" phase.
|
|
2633
2629
|
*
|
|
2634
2630
|
* @defaultValue "\{projectRoot\}/.powerlines"
|
|
2635
2631
|
*/
|
|
2636
|
-
|
|
2632
|
+
artifactsFolder?: string;
|
|
2637
2633
|
/**
|
|
2638
2634
|
* The module format of the output files
|
|
2639
2635
|
*
|
|
@@ -2651,19 +2647,6 @@ interface OutputConfig {
|
|
|
2651
2647
|
*/
|
|
2652
2648
|
assets?: Array<string | AssetGlob>;
|
|
2653
2649
|
}
|
|
2654
|
-
interface TransformConfig {
|
|
2655
|
-
/**
|
|
2656
|
-
* The Babel configuration options to use for the build process
|
|
2657
|
-
*/
|
|
2658
|
-
babel?: BabelUserConfig;
|
|
2659
|
-
/**
|
|
2660
|
-
* Reflection configuration options for the Deepkit TSC custom transformers
|
|
2661
|
-
*
|
|
2662
|
-
* @remarks
|
|
2663
|
-
* These options will be merged with the `tsconfig.json` file and the `tsconfigRaw` options.
|
|
2664
|
-
*/
|
|
2665
|
-
deepkit?: DeepkitOptions;
|
|
2666
|
-
}
|
|
2667
2650
|
interface BaseConfig {
|
|
2668
2651
|
/**
|
|
2669
2652
|
* The name of the project
|
|
@@ -2714,7 +2697,7 @@ interface BaseConfig {
|
|
|
2714
2697
|
/**
|
|
2715
2698
|
* Configuration for the transformation of the source code
|
|
2716
2699
|
*/
|
|
2717
|
-
transform?:
|
|
2700
|
+
transform?: Record<string, any>;
|
|
2718
2701
|
/**
|
|
2719
2702
|
* Options to to provide to the build process
|
|
2720
2703
|
*/
|
|
@@ -2839,6 +2822,12 @@ interface CommonUserConfig extends BaseConfig {
|
|
|
2839
2822
|
* Environment-specific configurations
|
|
2840
2823
|
*/
|
|
2841
2824
|
environments?: Record<string, EnvironmentConfig>;
|
|
2825
|
+
/**
|
|
2826
|
+
* A string identifier that allows a child framework or tool to identify itself when using Powerlines.
|
|
2827
|
+
*
|
|
2828
|
+
* @defaultValue "powerlines"
|
|
2829
|
+
*/
|
|
2830
|
+
framework?: string;
|
|
2842
2831
|
}
|
|
2843
2832
|
type UserConfig<TBuildConfig extends BuildConfig = BuildConfig, TBuildResolvedConfig extends BuildResolvedConfig = BuildResolvedConfig, TBuildVariant extends string = any> = CommonUserConfig & {
|
|
2844
2833
|
build?: TBuildConfig & {
|
package/dist/types/plugin.d.ts
CHANGED
|
@@ -11,16 +11,16 @@ import { EnvPaths } from '@stryke/env/get-env-paths';
|
|
|
11
11
|
import { PackageJson } from '@stryke/types/package-json';
|
|
12
12
|
import { Jiti } from 'jiti';
|
|
13
13
|
import { ReflectionClass } from '@deepkit/type';
|
|
14
|
+
import { Range } from 'semver';
|
|
14
15
|
import { TransformResult, ExternalIdResult, HookFilter, UnpluginOptions, UnpluginContext, UnpluginBuildContext } from 'unplugin';
|
|
15
16
|
import * as $ from '@stryke/capnp';
|
|
16
17
|
import { NonUndefined, MaybePromise, FunctionLike } from '@stryke/types/base';
|
|
17
18
|
import { TsConfigJson, CompilerOptions } from '@stryke/types/tsconfig';
|
|
18
19
|
import ts from 'typescript';
|
|
19
|
-
import { Range } from 'semver';
|
|
20
|
-
import { ArrayValues } from '@stryke/types/array';
|
|
21
20
|
import { Volume } from 'memfs';
|
|
22
21
|
import { StatSyncOptions, Stats, PathLike, RmDirOptions, RmOptions, Mode, MakeDirectoryOptions as MakeDirectoryOptions$1, PathOrFileDescriptor, WriteFileOptions as WriteFileOptions$1 } from 'node:fs';
|
|
23
22
|
import { IUnionFs } from 'unionfs';
|
|
23
|
+
import { ArrayValues } from '@stryke/types/array';
|
|
24
24
|
import { DotenvParseOutput } from '@stryke/env/types';
|
|
25
25
|
|
|
26
26
|
declare const ReflectionKind: {
|
|
@@ -1657,7 +1657,7 @@ type OutputResolvedConfig = Required<Omit<OutputConfig, "assets"> & {
|
|
|
1657
1657
|
/**
|
|
1658
1658
|
* The resolved options for the Powerlines project configuration.
|
|
1659
1659
|
*/
|
|
1660
|
-
type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "build" | "transform" | "override" | "root" | "variant" | "type" | "output" | "logLevel"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "build" | "transform" | "override">> & {
|
|
1660
|
+
type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "build" | "transform" | "override" | "root" | "variant" | "type" | "output" | "logLevel" | "framework"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "build" | "transform" | "override" | "framework">> & {
|
|
1661
1661
|
/**
|
|
1662
1662
|
* The configuration options that were provided inline to the Powerlines CLI.
|
|
1663
1663
|
*/
|
|
@@ -1703,11 +1703,6 @@ type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserCon
|
|
|
1703
1703
|
declare const SUPPORTED_COMMANDS: readonly ["new", "clean", "prepare", "lint", "test", "build", "docs", "release", "finalize"];
|
|
1704
1704
|
type CommandType = ArrayValues<typeof SUPPORTED_COMMANDS>;
|
|
1705
1705
|
|
|
1706
|
-
type PackageDependencyMeta = "dependency" | "devDependency" | {
|
|
1707
|
-
version?: string | Range;
|
|
1708
|
-
type?: "dependency" | "devDependency";
|
|
1709
|
-
};
|
|
1710
|
-
type PackageDependencies = Record<string, PackageDependencyMeta>;
|
|
1711
1706
|
interface PluginHookObject<THookFunction extends FunctionLike, TFilter extends keyof HookFilter | undefined = undefined> {
|
|
1712
1707
|
/**
|
|
1713
1708
|
* The order in which the plugin should be applied.
|
|
@@ -2432,13 +2427,6 @@ interface Context<TResolvedConfig extends ResolvedConfig = ResolvedConfig> {
|
|
|
2432
2427
|
* The relative path to the Powerlines workspace root directory
|
|
2433
2428
|
*/
|
|
2434
2429
|
relativeToWorkspaceRoot: string;
|
|
2435
|
-
/**
|
|
2436
|
-
* The path to the \powerlines package
|
|
2437
|
-
*
|
|
2438
|
-
* @remarks
|
|
2439
|
-
* This is used to determine the path to the Powerlines core package, which contains the runtime files.
|
|
2440
|
-
*/
|
|
2441
|
-
corePackagePath: string;
|
|
2442
2430
|
/**
|
|
2443
2431
|
* The Powerlines artifacts directory
|
|
2444
2432
|
*/
|
|
@@ -2468,9 +2456,17 @@ interface Context<TResolvedConfig extends ResolvedConfig = ResolvedConfig> {
|
|
|
2468
2456
|
*/
|
|
2469
2457
|
envPaths: EnvPaths;
|
|
2470
2458
|
/**
|
|
2471
|
-
* The
|
|
2459
|
+
* The file system path to the Powerlines package installation
|
|
2460
|
+
*/
|
|
2461
|
+
powerlinesPath: string;
|
|
2462
|
+
/**
|
|
2463
|
+
* The dependency installations required by the project
|
|
2464
|
+
*/
|
|
2465
|
+
dependencies: Record<string, string | Range>;
|
|
2466
|
+
/**
|
|
2467
|
+
* The development dependency installations required by the project
|
|
2472
2468
|
*/
|
|
2473
|
-
|
|
2469
|
+
devDependencies: Record<string, string | Range>;
|
|
2474
2470
|
/**
|
|
2475
2471
|
* The project's `package.json` file content
|
|
2476
2472
|
*/
|
|
@@ -2626,14 +2622,14 @@ interface OutputConfig {
|
|
|
2626
2622
|
*/
|
|
2627
2623
|
builtinPrefix?: string;
|
|
2628
2624
|
/**
|
|
2629
|
-
* The folder where the generated runtime
|
|
2625
|
+
* The folder where the generated runtime artifacts will be located
|
|
2630
2626
|
*
|
|
2631
2627
|
* @remarks
|
|
2632
|
-
* This folder will contain all runtime
|
|
2628
|
+
* This folder will contain all runtime artifacts and builtins generated during the "prepare" phase.
|
|
2633
2629
|
*
|
|
2634
2630
|
* @defaultValue "\{projectRoot\}/.powerlines"
|
|
2635
2631
|
*/
|
|
2636
|
-
|
|
2632
|
+
artifactsFolder?: string;
|
|
2637
2633
|
/**
|
|
2638
2634
|
* The module format of the output files
|
|
2639
2635
|
*
|
|
@@ -2651,19 +2647,6 @@ interface OutputConfig {
|
|
|
2651
2647
|
*/
|
|
2652
2648
|
assets?: Array<string | AssetGlob>;
|
|
2653
2649
|
}
|
|
2654
|
-
interface TransformConfig {
|
|
2655
|
-
/**
|
|
2656
|
-
* The Babel configuration options to use for the build process
|
|
2657
|
-
*/
|
|
2658
|
-
babel?: BabelUserConfig;
|
|
2659
|
-
/**
|
|
2660
|
-
* Reflection configuration options for the Deepkit TSC custom transformers
|
|
2661
|
-
*
|
|
2662
|
-
* @remarks
|
|
2663
|
-
* These options will be merged with the `tsconfig.json` file and the `tsconfigRaw` options.
|
|
2664
|
-
*/
|
|
2665
|
-
deepkit?: DeepkitOptions;
|
|
2666
|
-
}
|
|
2667
2650
|
interface BaseConfig {
|
|
2668
2651
|
/**
|
|
2669
2652
|
* The name of the project
|
|
@@ -2714,7 +2697,7 @@ interface BaseConfig {
|
|
|
2714
2697
|
/**
|
|
2715
2698
|
* Configuration for the transformation of the source code
|
|
2716
2699
|
*/
|
|
2717
|
-
transform?:
|
|
2700
|
+
transform?: Record<string, any>;
|
|
2718
2701
|
/**
|
|
2719
2702
|
* Options to to provide to the build process
|
|
2720
2703
|
*/
|
|
@@ -2839,6 +2822,12 @@ interface CommonUserConfig extends BaseConfig {
|
|
|
2839
2822
|
* Environment-specific configurations
|
|
2840
2823
|
*/
|
|
2841
2824
|
environments?: Record<string, EnvironmentConfig>;
|
|
2825
|
+
/**
|
|
2826
|
+
* A string identifier that allows a child framework or tool to identify itself when using Powerlines.
|
|
2827
|
+
*
|
|
2828
|
+
* @defaultValue "powerlines"
|
|
2829
|
+
*/
|
|
2830
|
+
framework?: string;
|
|
2842
2831
|
}
|
|
2843
2832
|
type UserConfig<TBuildConfig extends BuildConfig = BuildConfig, TBuildResolvedConfig extends BuildResolvedConfig = BuildResolvedConfig, TBuildVariant extends string = any> = CommonUserConfig & {
|
|
2844
2833
|
build?: TBuildConfig & {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@powerlines/plugin-date",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A package containing a Powerlines plugin for injecting static .env configuration values to the code so that they're accessible at runtime.",
|
|
6
6
|
"repository": {
|
|
@@ -116,17 +116,16 @@
|
|
|
116
116
|
"files": ["dist/**/*"],
|
|
117
117
|
"keywords": ["powerlines", "storm-software", "powerlines-plugin"],
|
|
118
118
|
"dependencies": {
|
|
119
|
-
"@powerlines/plugin-env": "^0.
|
|
119
|
+
"@powerlines/plugin-env": "^0.3.0",
|
|
120
120
|
"@storm-software/config-tools": "^1.188.6",
|
|
121
121
|
"@stryke/path": "^0.15.5",
|
|
122
|
-
"powerlines": "^0.
|
|
122
|
+
"powerlines": "^0.4.0"
|
|
123
123
|
},
|
|
124
124
|
"devDependencies": {
|
|
125
|
-
"@powerlines/nx": "^0.
|
|
125
|
+
"@powerlines/nx": "^0.4.0",
|
|
126
126
|
"@storm-software/tsup": "^0.2.4",
|
|
127
|
-
"@types/node": "^22.18.11"
|
|
128
|
-
"tsup": "8.4.0"
|
|
127
|
+
"@types/node": "^22.18.11"
|
|
129
128
|
},
|
|
130
129
|
"publishConfig": { "access": "public" },
|
|
131
|
-
"gitHead": "
|
|
130
|
+
"gitHead": "f4d0c8a8f0036ac8de46ac96afd9336a390a7268"
|
|
132
131
|
}
|