keycloakify 11.6.0 → 11.6.2
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/bin/{805.index.js → 174.index.js} +111 -2
- package/bin/363.index.js +1528 -0
- package/bin/453.index.js +1 -1
- package/bin/{33.index.js → 568.index.js} +2 -113
- package/bin/735.index.js +53 -24
- package/bin/{653.index.js → 840.index.js} +387 -213
- package/bin/921.index.js +1 -1
- package/bin/930.index.js +165 -0
- package/bin/946.index.js +20 -0
- package/bin/initialize-admin-theme.d.ts +4 -0
- package/bin/main.js +72 -18
- package/bin/{eject-file.d.ts → own.d.ts} +2 -1
- package/bin/shared/addSyncExtensionsToPostinstallScript.d.ts +10 -0
- package/bin/shared/customHandler.d.ts +1 -1
- package/bin/shared/customHandler.js.map +1 -1
- package/bin/{postinstall/uiModuleMeta.d.ts → sync-extensions/extensionModuleMeta.d.ts} +5 -5
- package/bin/sync-extensions/getExtensionModuleFileSourceCodeReadyToBeCopied.d.ts +12 -0
- package/bin/sync-extensions/index.d.ts +1 -0
- package/bin/{postinstall/installUiModulesPeerDependencies.d.ts → sync-extensions/installExtensionModulesPeerDependencies.d.ts} +3 -3
- package/bin/{postinstall → sync-extensions}/managedGitignoreFile.d.ts +4 -4
- package/bin/tools/isKnownByGit.d.ts +3 -0
- package/bin/tools/npmInstall.d.ts +1 -1
- package/package.json +27 -22
- package/src/bin/eject-page.ts +1 -3
- package/src/bin/initialize-account-theme/initializeAccountTheme_singlePage.ts +3 -1
- package/src/bin/initialize-admin-theme.ts +146 -0
- package/src/bin/main.ts +76 -17
- package/src/bin/own.ts +209 -0
- package/src/bin/shared/addSyncExtensionsToPostinstallScript.ts +70 -0
- package/src/bin/shared/customHandler.ts +1 -0
- package/src/bin/{postinstall/uiModuleMeta.ts → sync-extensions/extensionModuleMeta.ts} +55 -43
- package/src/bin/{postinstall/getUiModuleFileSourceCodeReadyToBeCopied.ts → sync-extensions/getExtensionModuleFileSourceCodeReadyToBeCopied.ts} +32 -21
- package/src/bin/sync-extensions/index.ts +1 -0
- package/src/bin/{postinstall/installUiModulesPeerDependencies.ts → sync-extensions/installExtensionModulesPeerDependencies.ts} +16 -14
- package/src/bin/{postinstall → sync-extensions}/managedGitignoreFile.ts +18 -18
- package/src/bin/{postinstall/postinstall.ts → sync-extensions/sync-extension.ts} +14 -26
- package/src/bin/tools/isKnownByGit.ts +45 -0
- package/src/bin/tools/listInstalledModules.ts +2 -2
- package/src/bin/tools/npmInstall.ts +46 -9
- package/src/bin/tools/untrackFromGit.ts +19 -3
- package/bin/356.index.js +0 -755
- package/bin/854.index.js +0 -68
- package/bin/postinstall/getUiModuleFileSourceCodeReadyToBeCopied.d.ts +0 -12
- package/bin/postinstall/index.d.ts +0 -1
- package/bin/tools/isTrackedByGit.d.ts +0 -3
- package/src/bin/eject-file.ts +0 -68
- package/src/bin/postinstall/index.ts +0 -1
- package/src/bin/tools/isTrackedByGit.ts +0 -29
- /package/bin/{postinstall/postinstall.d.ts → sync-extensions/sync-extension.d.ts} +0 -0
@@ -9,8 +9,9 @@ import { objectKeys } from "tsafe/objectKeys";
|
|
9
9
|
import { getAbsoluteAndInOsFormatPath } from "./getAbsoluteAndInOsFormatPath";
|
10
10
|
import { exclude } from "tsafe/exclude";
|
11
11
|
import { rmSync } from "./fs.rmSync";
|
12
|
+
import { Deferred } from "evt/tools/Deferred";
|
12
13
|
|
13
|
-
export function npmInstall(params: { packageJsonDirPath: string }) {
|
14
|
+
export async function npmInstall(params: { packageJsonDirPath: string }) {
|
14
15
|
const { packageJsonDirPath } = params;
|
15
16
|
|
16
17
|
const packageManagerBinName = (() => {
|
@@ -68,7 +69,7 @@ export function npmInstall(params: { packageJsonDirPath: string }) {
|
|
68
69
|
|
69
70
|
console.log(chalk.green("Installing in a way that won't break the links..."));
|
70
71
|
|
71
|
-
installWithoutBreakingLinks({
|
72
|
+
await installWithoutBreakingLinks({
|
72
73
|
packageJsonDirPath,
|
73
74
|
garronejLinkInfos
|
74
75
|
});
|
@@ -77,9 +78,9 @@ export function npmInstall(params: { packageJsonDirPath: string }) {
|
|
77
78
|
}
|
78
79
|
|
79
80
|
try {
|
80
|
-
|
81
|
-
|
82
|
-
|
81
|
+
await runPackageManagerInstall({
|
82
|
+
packageManagerBinName,
|
83
|
+
cwd: packageJsonDirPath
|
83
84
|
});
|
84
85
|
} catch {
|
85
86
|
console.log(
|
@@ -90,6 +91,42 @@ export function npmInstall(params: { packageJsonDirPath: string }) {
|
|
90
91
|
}
|
91
92
|
}
|
92
93
|
|
94
|
+
async function runPackageManagerInstall(params: {
|
95
|
+
packageManagerBinName: string;
|
96
|
+
cwd: string;
|
97
|
+
}) {
|
98
|
+
const { packageManagerBinName, cwd } = params;
|
99
|
+
|
100
|
+
const dCompleted = new Deferred<void>();
|
101
|
+
|
102
|
+
const child = child_process.spawn(packageManagerBinName, ["install"], {
|
103
|
+
cwd,
|
104
|
+
env: process.env,
|
105
|
+
shell: true
|
106
|
+
});
|
107
|
+
|
108
|
+
child.stdout.on("data", data => process.stdout.write(data));
|
109
|
+
|
110
|
+
child.stderr.on("data", data => {
|
111
|
+
if (data.toString("utf8").includes("peer dependency")) {
|
112
|
+
return;
|
113
|
+
}
|
114
|
+
|
115
|
+
process.stderr.write(data);
|
116
|
+
});
|
117
|
+
|
118
|
+
child.on("exit", code => {
|
119
|
+
if (code !== 0) {
|
120
|
+
dCompleted.reject(new Error(`Failed with code ${code}`));
|
121
|
+
return;
|
122
|
+
}
|
123
|
+
|
124
|
+
dCompleted.resolve();
|
125
|
+
});
|
126
|
+
|
127
|
+
await dCompleted.pr;
|
128
|
+
}
|
129
|
+
|
93
130
|
function getGarronejLinkInfos(params: {
|
94
131
|
packageJsonDirPath: string;
|
95
132
|
}): { linkedModuleNames: string[]; yarnHomeDirPath: string } | undefined {
|
@@ -180,7 +217,7 @@ function getGarronejLinkInfos(params: {
|
|
180
217
|
return { linkedModuleNames, yarnHomeDirPath };
|
181
218
|
}
|
182
219
|
|
183
|
-
function installWithoutBreakingLinks(params: {
|
220
|
+
async function installWithoutBreakingLinks(params: {
|
184
221
|
packageJsonDirPath: string;
|
185
222
|
garronejLinkInfos: Exclude<ReturnType<typeof getGarronejLinkInfos>, undefined>;
|
186
223
|
}) {
|
@@ -261,9 +298,9 @@ function installWithoutBreakingLinks(params: {
|
|
261
298
|
pathJoin(tmpProjectDirPath, YARN_LOCK)
|
262
299
|
);
|
263
300
|
|
264
|
-
|
265
|
-
|
266
|
-
|
301
|
+
await runPackageManagerInstall({
|
302
|
+
packageManagerBinName: "yarn",
|
303
|
+
cwd: tmpProjectDirPath
|
267
304
|
});
|
268
305
|
|
269
306
|
// NOTE: Moving the modules from the tmp project to the actual project
|
@@ -1,15 +1,31 @@
|
|
1
1
|
import * as child_process from "child_process";
|
2
|
-
import {
|
2
|
+
import {
|
3
|
+
dirname as pathDirname,
|
4
|
+
basename as pathBasename,
|
5
|
+
join as pathJoin,
|
6
|
+
sep as pathSep
|
7
|
+
} from "path";
|
3
8
|
import { Deferred } from "evt/tools/Deferred";
|
9
|
+
import { existsAsync } from "./fs.existsAsync";
|
4
10
|
|
5
11
|
export async function untrackFromGit(params: { filePath: string }): Promise<void> {
|
6
12
|
const { filePath } = params;
|
7
13
|
|
8
14
|
const dDone = new Deferred<void>();
|
9
15
|
|
16
|
+
let relativePath = pathBasename(filePath);
|
17
|
+
|
18
|
+
let dirPath = pathDirname(filePath);
|
19
|
+
|
20
|
+
while (!(await existsAsync(dirPath))) {
|
21
|
+
relativePath = pathJoin(pathBasename(dirPath), relativePath);
|
22
|
+
|
23
|
+
dirPath = pathDirname(dirPath);
|
24
|
+
}
|
25
|
+
|
10
26
|
child_process.exec(
|
11
|
-
`git rm --cached ${
|
12
|
-
{ cwd:
|
27
|
+
`git rm --cached '${relativePath.split(pathSep).join("/")}'`,
|
28
|
+
{ cwd: dirPath },
|
13
29
|
error => {
|
14
30
|
if (error !== null) {
|
15
31
|
dDone.reject(error);
|