penguins-eggs 9.1.34 → 9.2.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/README.md +41 -78
- package/addons/eggs/theme/applications/install-debian.desktop +2 -2
- package/conf/distros/bionic/calamares/settings.yml +2 -2
- package/conf/distros/buster/calamares/settings.yml +2 -2
- package/conf/distros/focal/calamares/settings.yml +2 -2
- package/conf/distros/rolling/calamares/modules/machineid.yml +4 -0
- package/conf/distros/rolling/calamares/modules/packages.yml +1 -1
- package/conf/distros/rolling/calamares/modules/shellprocess_removelink.yml +6 -0
- package/conf/distros/rolling/calamares/settings.yml +4 -11
- package/conf/exclude.list +81 -96
- package/conf/tools.yaml +1 -1
- package/lib/classes/bleach.js +6 -4
- package/lib/classes/daddy.js +2 -1
- package/lib/classes/distro.js +23 -14
- package/lib/classes/family/archlinux.js +8 -4
- package/lib/classes/incubation/distros/bionic.d.ts +1 -1
- package/lib/classes/incubation/distros/bionic.js +1 -1
- package/lib/classes/incubation/distros/buster.d.ts +1 -1
- package/lib/classes/incubation/distros/buster.js +1 -1
- package/lib/classes/incubation/distros/focal.d.ts +1 -1
- package/lib/classes/incubation/distros/focal.js +1 -1
- package/lib/classes/incubation/distros/jessie.d.ts +1 -1
- package/lib/classes/incubation/distros/jessie.js +1 -1
- package/lib/classes/incubation/distros/rolling.d.ts +3 -3
- package/lib/classes/incubation/distros/rolling.js +4 -5
- package/lib/classes/incubation/fisherman-helper/packages.d.ts +4 -0
- package/lib/classes/incubation/fisherman-helper/packages.js +9 -16
- package/lib/classes/incubation/fisherman.d.ts +1 -1
- package/lib/classes/incubation/fisherman.js +24 -10
- package/lib/classes/incubation/incubator.js +26 -22
- package/lib/classes/ovary.d.ts +2 -1
- package/lib/classes/ovary.js +91 -30
- package/lib/classes/pacman.js +5 -5
- package/lib/classes/utils.d.ts +1 -1
- package/lib/classes/utils.js +5 -4
- package/lib/commands/calamares.js +1 -0
- package/lib/commands/{krill.d.ts → install.d.ts} +0 -1
- package/lib/commands/{krill.js → install.js} +6 -24
- package/lib/commands/produce.d.ts +1 -0
- package/lib/commands/produce.js +5 -7
- package/lib/commands/syncfrom.js +1 -1
- package/lib/commands/syncto.js +1 -1
- package/lib/components/elements/information.js +0 -2
- package/lib/krill/krill-prepare.d.ts +3 -1
- package/lib/krill/krill-prepare.js +8 -2
- package/lib/krill/krill-sequence.d.ts +2 -1
- package/lib/krill/krill-sequence.js +36 -33
- package/lib/krill/modules/bootloader.js +28 -2
- package/lib/krill/modules/initramfs.js +14 -2
- package/lib/krill/modules/{l/303/262cale-cfg.d.ts → locale-cfg.d.ts} +0 -0
- package/lib/krill/modules/{l/303/262cale-cfg.js → locale-cfg.js} +0 -0
- package/lib/krill/modules/set-keyboard.js +3 -3
- package/lib/lib/utils.d.ts +27 -0
- package/lib/lib/utils.js +54 -19
- package/mkinitcpio/archlinux/README.md +116 -0
- package/mkinitcpio/manjaro/README.md +4 -0
- package/package.json +11 -10
- package/scripts/_eggs +21 -20
- package/scripts/eggs.bash +4 -4
- package/scripts/mom-cli.sh +23 -79
- package/conf/distros/rolling/calamares/calamares-modules/remove-link/module.yml +0 -9
- package/conf/distros/rolling/calamares/calamares-modules/remove-link/remove-link.sh +0 -3
- package/lib/commands/remove.d.ts +0 -21
- package/lib/commands/remove.js +0 -84
package/lib/classes/bleach.js
CHANGED
|
@@ -22,12 +22,15 @@ class Bleach {
|
|
|
22
22
|
* @param verbose
|
|
23
23
|
*/
|
|
24
24
|
async clean(verbose = false) {
|
|
25
|
+
if (verbose) {
|
|
26
|
+
utils_1.default.warning('cleaning the system');
|
|
27
|
+
}
|
|
25
28
|
const distro = new distro_1.default();
|
|
26
|
-
if (distro.
|
|
29
|
+
if (distro.familyId === 'debian') {
|
|
27
30
|
await this.cleanApt(verbose);
|
|
28
31
|
}
|
|
29
|
-
else if (distro.
|
|
30
|
-
await (0, utils_2.exec)('
|
|
32
|
+
else if (distro.familyId === 'archlinux') {
|
|
33
|
+
await (0, utils_2.exec)('pacman -Scc', utils_1.default.setEcho(true));
|
|
31
34
|
}
|
|
32
35
|
await this.cleanHistory(verbose);
|
|
33
36
|
await this.cleanJournal(verbose);
|
|
@@ -41,7 +44,6 @@ class Bleach {
|
|
|
41
44
|
let echo = { echo: false, ignore: true, capture: false };
|
|
42
45
|
if (verbose) {
|
|
43
46
|
echo = { echo: true, ignore: true, capture: false };
|
|
44
|
-
utils_1.default.warning('cleaning apt');
|
|
45
47
|
}
|
|
46
48
|
await (0, utils_2.exec)('apt-get clean', echo);
|
|
47
49
|
await (0, utils_2.exec)('apt-get autoclean', echo);
|
package/lib/classes/daddy.js
CHANGED
|
@@ -102,13 +102,14 @@ class Daddy {
|
|
|
102
102
|
const myAddons = {};
|
|
103
103
|
myAddons.adapt = true;
|
|
104
104
|
const backup = false;
|
|
105
|
+
const personal = false;
|
|
105
106
|
const scriptOnly = false;
|
|
106
107
|
const yolkRenew = false;
|
|
107
108
|
const final = false;
|
|
108
109
|
const ovary = new ovary_1.default();
|
|
109
110
|
utils_1.default.warning('Produce an egg...');
|
|
110
111
|
if (await ovary.fertilization(config.snapshot_prefix, config.snapshot_basename, config.theme, config.compression)) {
|
|
111
|
-
await ovary.produce(backup, scriptOnly, yolkRenew, final, myAddons, verbose);
|
|
112
|
+
await ovary.produce(backup, personal, scriptOnly, yolkRenew, final, myAddons, verbose);
|
|
112
113
|
ovary.finished(scriptOnly);
|
|
113
114
|
}
|
|
114
115
|
}
|
package/lib/classes/distro.js
CHANGED
|
@@ -27,6 +27,10 @@
|
|
|
27
27
|
* Ubuntu 21.10 (impish) active
|
|
28
28
|
* Ubuntu 22.04 (jammy) LTS
|
|
29
29
|
*
|
|
30
|
+
* Arch
|
|
31
|
+
* Manjaro Qonos
|
|
32
|
+
* Manjaro Ruah
|
|
33
|
+
*
|
|
30
34
|
*/
|
|
31
35
|
'use strict';
|
|
32
36
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -203,6 +207,12 @@ class Distro {
|
|
|
203
207
|
this.codenameLikeId = 'bookworm';
|
|
204
208
|
break;
|
|
205
209
|
}
|
|
210
|
+
case `hera`: {
|
|
211
|
+
// Elementary
|
|
212
|
+
this.distroLike = 'Ubuntu';
|
|
213
|
+
this.codenameLikeId = 'bionic';
|
|
214
|
+
break;
|
|
215
|
+
}
|
|
206
216
|
case `jolnir`: {
|
|
207
217
|
// Elementary
|
|
208
218
|
this.distroLike = 'Ubuntu';
|
|
@@ -301,18 +311,24 @@ class Distro {
|
|
|
301
311
|
case 'n/a': {
|
|
302
312
|
this.familyId = 'archlinux';
|
|
303
313
|
this.distroLike = 'Arch';
|
|
314
|
+
this.codenameId = 'rolling';
|
|
304
315
|
this.codenameLikeId = 'rolling';
|
|
305
316
|
break;
|
|
306
317
|
}
|
|
307
318
|
/**
|
|
308
|
-
*
|
|
319
|
+
* Manjaro
|
|
309
320
|
*/
|
|
310
|
-
case '
|
|
321
|
+
case 'Qonos':
|
|
322
|
+
case 'Ruah': {
|
|
311
323
|
this.familyId = 'archlinux';
|
|
312
324
|
this.distroLike = 'Arch';
|
|
313
325
|
this.codenameLikeId = 'rolling';
|
|
314
326
|
break;
|
|
315
327
|
}
|
|
328
|
+
/**
|
|
329
|
+
* GARUDA
|
|
330
|
+
*/
|
|
331
|
+
case 'Harpy-Eagle':
|
|
316
332
|
case 'White-tailed-eagle': {
|
|
317
333
|
this.familyId = 'archlinux';
|
|
318
334
|
this.distroLike = 'Arch';
|
|
@@ -320,18 +336,8 @@ class Distro {
|
|
|
320
336
|
break;
|
|
321
337
|
}
|
|
322
338
|
/**
|
|
323
|
-
*
|
|
339
|
+
* FEDORA
|
|
324
340
|
*/
|
|
325
|
-
case 'Qonos':
|
|
326
|
-
case 'Ruah': {
|
|
327
|
-
this.familyId = 'archlinux';
|
|
328
|
-
this.distroLike = 'Arch';
|
|
329
|
-
this.codenameLikeId = 'rolling';
|
|
330
|
-
break;
|
|
331
|
-
/**
|
|
332
|
-
* Fedora
|
|
333
|
-
*/
|
|
334
|
-
}
|
|
335
341
|
case 'ThirtyFive': {
|
|
336
342
|
this.familyId = 'fedora';
|
|
337
343
|
this.distroLike = 'Fedora';
|
|
@@ -366,9 +372,12 @@ class Distro {
|
|
|
366
372
|
else {
|
|
367
373
|
this.mountpointSquashFs = '/run/live/medium/live/filesystem.squashfs';
|
|
368
374
|
}
|
|
369
|
-
if (this.
|
|
375
|
+
if (this.distroId === "ManjaroLinux") {
|
|
370
376
|
this.mountpointSquashFs = "/run/miso/bootmnt/live/filesystem.squashfs";
|
|
371
377
|
}
|
|
378
|
+
else if (this.distroId === "Arch") {
|
|
379
|
+
this.mountpointSquashFs = "/run/archiso/bootmnt/live/filesystem.squashfs";
|
|
380
|
+
}
|
|
372
381
|
/**
|
|
373
382
|
* setting paths: syslinux, isolinux, usrLib
|
|
374
383
|
*/
|
|
@@ -36,8 +36,12 @@ class Archlinux {
|
|
|
36
36
|
* Crea array pacchetti da installare/rimuovere
|
|
37
37
|
*/
|
|
38
38
|
static packages(remove = false, verbose = false) {
|
|
39
|
+
/**
|
|
40
|
+
* praticamente non serve, perche prende dal pacchetto o da pkgbuild
|
|
41
|
+
*/
|
|
39
42
|
// non può essere pacman è universalmente presente
|
|
40
|
-
|
|
43
|
+
// 'pacman', 'awk', 'dosfstools'
|
|
44
|
+
const packages = ['']; // 'arch-install-scripts', 'e2fsprogs', 'erofs-utils', 'findutils', 'gzip', 'libarchive', 'libisoburn', 'mtools', 'openssl', 'rsync', 'sed', 'syslinux', 'squashfs-tools']
|
|
41
45
|
const toInstall = [];
|
|
42
46
|
const toRemove = [];
|
|
43
47
|
for (const elem of packages) {
|
|
@@ -97,12 +101,12 @@ class Archlinux {
|
|
|
97
101
|
static async calamaresInstall(verbose = false) {
|
|
98
102
|
verbose = true; // serve per pacman
|
|
99
103
|
const echo = utils_1.default.setEcho(verbose);
|
|
104
|
+
let cmd = `pacman -Sy --noconfirm ${(0, dependencies_1.array2spaced)(this.packs4calamares)}`;
|
|
100
105
|
try {
|
|
101
|
-
|
|
102
|
-
await (0, utils_2.exec)(`pacman -Sy --noconfirm ${(0, dependencies_1.array2spaced)(this.packs4calamares)}`, echo);
|
|
106
|
+
await (0, utils_2.exec)(cmd, echo);
|
|
103
107
|
}
|
|
104
108
|
catch {
|
|
105
|
-
utils_1.default.error(`Archlinux.calamaresInstall()
|
|
109
|
+
utils_1.default.error(`Archlinux.calamaresInstall(): ${cmd}`); // + e.error)
|
|
106
110
|
}
|
|
107
111
|
}
|
|
108
112
|
/**
|
|
@@ -21,7 +21,7 @@ export declare class Bionic {
|
|
|
21
21
|
* @param release
|
|
22
22
|
* @param verbose
|
|
23
23
|
*/
|
|
24
|
-
constructor(installer: IInstaller, remix: IRemix, distro: IDistro,
|
|
24
|
+
constructor(installer: IInstaller, remix: IRemix, distro: IDistro, user_opt: string, release?: boolean, verbose?: boolean);
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
@@ -19,7 +19,7 @@ class Bionic {
|
|
|
19
19
|
* @param release
|
|
20
20
|
* @param verbose
|
|
21
21
|
*/
|
|
22
|
-
constructor(installer, remix, distro,
|
|
22
|
+
constructor(installer, remix, distro, user_opt, release = false, verbose = false) {
|
|
23
23
|
this.verbose = false;
|
|
24
24
|
this.installer = {};
|
|
25
25
|
this.release = false;
|
|
@@ -23,7 +23,7 @@ export declare class Buster {
|
|
|
23
23
|
* @param displaymanager
|
|
24
24
|
* @param verbose
|
|
25
25
|
*/
|
|
26
|
-
constructor(installer: IInstaller, remix: IRemix, distro: IDistro,
|
|
26
|
+
constructor(installer: IInstaller, remix: IRemix, distro: IDistro, user_opt: string, release?: boolean, verbose?: boolean);
|
|
27
27
|
/**
|
|
28
28
|
*
|
|
29
29
|
*/
|
|
@@ -21,7 +21,7 @@ class Buster {
|
|
|
21
21
|
* @param displaymanager
|
|
22
22
|
* @param verbose
|
|
23
23
|
*/
|
|
24
|
-
constructor(installer, remix, distro,
|
|
24
|
+
constructor(installer, remix, distro, user_opt, release = false, verbose = false) {
|
|
25
25
|
this.verbose = false;
|
|
26
26
|
this.installer = {};
|
|
27
27
|
this.release = false;
|
|
@@ -21,7 +21,7 @@ export declare class Focal {
|
|
|
21
21
|
* @param displaymanager
|
|
22
22
|
* @param verbose
|
|
23
23
|
*/
|
|
24
|
-
constructor(installer: IInstaller, remix: IRemix, distro: IDistro,
|
|
24
|
+
constructor(installer: IInstaller, remix: IRemix, distro: IDistro, user_opt: string, release?: boolean, verbose?: boolean);
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
@@ -19,7 +19,7 @@ class Focal {
|
|
|
19
19
|
* @param displaymanager
|
|
20
20
|
* @param verbose
|
|
21
21
|
*/
|
|
22
|
-
constructor(installer, remix, distro,
|
|
22
|
+
constructor(installer, remix, distro, user_opt, release = false, verbose = false) {
|
|
23
23
|
this.verbose = false;
|
|
24
24
|
this.installer = {};
|
|
25
25
|
this.release = false;
|
|
@@ -24,7 +24,7 @@ export declare class Jessie {
|
|
|
24
24
|
* @param displaymanager
|
|
25
25
|
* @param verbose
|
|
26
26
|
*/
|
|
27
|
-
constructor(installer: IInstaller, remix: IRemix, distro: IDistro,
|
|
27
|
+
constructor(installer: IInstaller, remix: IRemix, distro: IDistro, user_opt: string, release?: boolean, verbose?: boolean);
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
*/
|
|
@@ -21,7 +21,7 @@ class Jessie {
|
|
|
21
21
|
* @param displaymanager
|
|
22
22
|
* @param verbose
|
|
23
23
|
*/
|
|
24
|
-
constructor(installer, remix, distro,
|
|
24
|
+
constructor(installer, remix, distro, user_opt, release = false, verbose = false) {
|
|
25
25
|
this.verbose = false;
|
|
26
26
|
this.installer = {};
|
|
27
27
|
this.release = false;
|
|
@@ -11,19 +11,19 @@ import { IInstaller, IRemix, IDistro } from '../../../interfaces';
|
|
|
11
11
|
*
|
|
12
12
|
*/
|
|
13
13
|
export declare class Rolling {
|
|
14
|
-
verbose: boolean;
|
|
15
14
|
installer: IInstaller;
|
|
16
15
|
remix: IRemix;
|
|
17
16
|
distro: IDistro;
|
|
18
|
-
release: boolean;
|
|
19
17
|
user_opt: string;
|
|
18
|
+
release: boolean;
|
|
19
|
+
verbose: boolean;
|
|
20
20
|
/**
|
|
21
21
|
* @param remix
|
|
22
22
|
* @param distro
|
|
23
23
|
* @param displaymanager
|
|
24
24
|
* @param verbose
|
|
25
25
|
*/
|
|
26
|
-
constructor(installer: IInstaller, remix: IRemix, distro: IDistro,
|
|
26
|
+
constructor(installer: IInstaller, remix: IRemix, distro: IDistro, user_opt: string, release?: boolean, verbose?: boolean);
|
|
27
27
|
/**
|
|
28
28
|
*
|
|
29
29
|
*/
|
|
@@ -21,10 +21,10 @@ class Rolling {
|
|
|
21
21
|
* @param displaymanager
|
|
22
22
|
* @param verbose
|
|
23
23
|
*/
|
|
24
|
-
constructor(installer, remix, distro,
|
|
25
|
-
this.verbose = false;
|
|
24
|
+
constructor(installer, remix, distro, user_opt, release = false, verbose = false) {
|
|
26
25
|
this.installer = {};
|
|
27
26
|
this.release = false;
|
|
27
|
+
this.verbose = false;
|
|
28
28
|
this.installer = installer;
|
|
29
29
|
this.remix = remix;
|
|
30
30
|
this.distro = distro;
|
|
@@ -55,14 +55,13 @@ class Rolling {
|
|
|
55
55
|
// await fisherman.buildCalamaresModule('bootloader-config', true)
|
|
56
56
|
await fisherman.buildModule('grubcf');
|
|
57
57
|
await fisherman.buildModule('bootloader');
|
|
58
|
-
await fisherman.modulePackages(this.distro, this.release);
|
|
58
|
+
await fisherman.modulePackages(this.distro, this.release);
|
|
59
59
|
await fisherman.buildModule('luksbootkeyfile');
|
|
60
60
|
await fisherman.buildModule('plymouthcfg');
|
|
61
61
|
// await fisherman.buildModule('initramfscfg')
|
|
62
62
|
// await fisherman.buildModule('initramfs')
|
|
63
63
|
await fisherman.moduleRemoveuser(this.user_opt);
|
|
64
|
-
|
|
65
|
-
// await fisherman.buildCalamaresModule('remove-link')
|
|
64
|
+
await fisherman.shellprocess('removelink');
|
|
66
65
|
await fisherman.buildModule('umount');
|
|
67
66
|
await fisherman.moduleFinished();
|
|
68
67
|
}
|
|
@@ -7,29 +7,22 @@ const tslib_1 = require("tslib");
|
|
|
7
7
|
*/
|
|
8
8
|
const pacman_1 = tslib_1.__importDefault(require("../../pacman"));
|
|
9
9
|
/**
|
|
10
|
+
* Work only with:
|
|
11
|
+
* - calamares
|
|
12
|
+
* - penguins-eggs
|
|
10
13
|
*
|
|
14
|
+
* dependencies actually are removed by package managers
|
|
11
15
|
*/
|
|
12
16
|
function remove(distro) {
|
|
13
|
-
let
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
removePackages = ["calamares"];
|
|
17
|
-
removePackages = ["penguins-eggs"];
|
|
17
|
+
let removePackages = ["calamares"];
|
|
18
|
+
if (distro.familyId === 'archlinux') {
|
|
19
|
+
removePackages.push("penguins-eggs");
|
|
18
20
|
}
|
|
19
|
-
|
|
20
|
-
removePackages.push("calamares");
|
|
21
|
+
if (distro.familyId === 'debian') {
|
|
21
22
|
removePackages.push("eggs");
|
|
22
23
|
}
|
|
23
|
-
const mustRemain = ["coreutils", "cryptsetup", "curl", "dosfstools", "git", "parted", "rsync", "lvm2"];
|
|
24
|
-
let sorted = [];
|
|
25
|
-
for (const elem of removePackages) {
|
|
26
|
-
if (!mustRemain.includes(elem)) {
|
|
27
|
-
sorted.push(elem);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
sorted = sorted.sort();
|
|
31
24
|
let text = ' - remove:\n';
|
|
32
|
-
for (const elem of
|
|
25
|
+
for (const elem of removePackages) {
|
|
33
26
|
text += ` - ${elem.trim()}\n`;
|
|
34
27
|
}
|
|
35
28
|
return text;
|
|
@@ -69,7 +69,7 @@ export default class Fisherman {
|
|
|
69
69
|
/**
|
|
70
70
|
* usa i moduli-ts
|
|
71
71
|
*/
|
|
72
|
-
modulePackages(distro: IDistro,
|
|
72
|
+
modulePackages(distro: IDistro, release?: boolean): Promise<void>;
|
|
73
73
|
/**
|
|
74
74
|
* Al momento rimane con la vecchia configurazione
|
|
75
75
|
*/
|
|
@@ -32,13 +32,25 @@ class Fisherman {
|
|
|
32
32
|
if (utils_1.default.isSystemd()) {
|
|
33
33
|
hasSystemd = '- ';
|
|
34
34
|
}
|
|
35
|
+
/**
|
|
36
|
+
* Controllo se è un clone
|
|
37
|
+
*/
|
|
38
|
+
let filePersonal = `/home/eggs/ovarium/iso/live/is-clone.md`;
|
|
39
|
+
if (utils_1.default.isLive()) {
|
|
40
|
+
filePersonal = node_path_1.default.dirname(this.distro.mountpointSquashFs) + `/is-clone.md`;
|
|
41
|
+
}
|
|
35
42
|
let hasDisplaymanager = '# ';
|
|
36
|
-
|
|
37
|
-
|
|
43
|
+
let createUsers = '# ';
|
|
44
|
+
if (!node_fs_1.default.existsSync(filePersonal)) {
|
|
45
|
+
createUsers = '- ';
|
|
46
|
+
if ((0, displaymanager_1.displaymanager)() !== '') {
|
|
47
|
+
hasDisplaymanager = '- ';
|
|
48
|
+
}
|
|
38
49
|
}
|
|
39
50
|
shelljs_1.default.sed('-i', '{{hasSystemd}}', hasSystemd, settings);
|
|
40
51
|
shelljs_1.default.sed('-i', '{{hasDisplaymanager}}', hasDisplaymanager, settings);
|
|
41
52
|
shelljs_1.default.sed('-i', '{{branding}}', branding, settings);
|
|
53
|
+
shelljs_1.default.sed('-i', '{{createUsers}}', createUsers, settings);
|
|
42
54
|
}
|
|
43
55
|
/**
|
|
44
56
|
*
|
|
@@ -78,6 +90,7 @@ class Fisherman {
|
|
|
78
90
|
* @param replaces [['search','replace']]
|
|
79
91
|
*/
|
|
80
92
|
async buildModule(name, vendor = '') {
|
|
93
|
+
console.log('creating... ' + name);
|
|
81
94
|
let moduleSource = node_path_1.default.resolve(__dirname, this.installer.templateModules + name + '.yml');
|
|
82
95
|
/**
|
|
83
96
|
* We need vendor here to have possibility to load custom modules for calamares
|
|
@@ -103,8 +116,9 @@ class Fisherman {
|
|
|
103
116
|
}
|
|
104
117
|
const moduleDest = this.installer.modules + name + '.conf';
|
|
105
118
|
if (node_fs_1.default.existsSync(moduleSource)) {
|
|
106
|
-
if (this.verbose)
|
|
119
|
+
if (this.verbose) {
|
|
107
120
|
this.show(name, 'module', moduleDest);
|
|
121
|
+
}
|
|
108
122
|
shelljs_1.default.cp(moduleSource, moduleDest);
|
|
109
123
|
}
|
|
110
124
|
else if (this.verbose) {
|
|
@@ -213,18 +227,18 @@ class Fisherman {
|
|
|
213
227
|
/**
|
|
214
228
|
* usa i moduli-ts
|
|
215
229
|
*/
|
|
216
|
-
async modulePackages(distro,
|
|
230
|
+
async modulePackages(distro, release = false) {
|
|
217
231
|
const name = 'packages';
|
|
218
232
|
const removePackages = require('./fisherman-helper/packages').remove;
|
|
219
233
|
const tryInstall = require('./fisherman-helper/packages').tryInstall;
|
|
220
234
|
this.buildModule(name);
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
else {
|
|
225
|
-
shelljs_1.default.sed('-i', '{{remove}}', '', this.installer.modules + name + '.conf');
|
|
235
|
+
let toRemove = '';
|
|
236
|
+
if (release) {
|
|
237
|
+
toRemove = removePackages(distro);
|
|
226
238
|
}
|
|
227
|
-
|
|
239
|
+
let toInstall = tryInstall(distro);
|
|
240
|
+
shelljs_1.default.sed('-i', '{{remove}}', toRemove, this.installer.modules + name + '.conf');
|
|
241
|
+
shelljs_1.default.sed('-i', '{{try_install}}', toInstall, this.installer.modules + name + '.conf');
|
|
228
242
|
}
|
|
229
243
|
/**
|
|
230
244
|
* Al momento rimane con la vecchia configurazione
|
|
@@ -50,86 +50,90 @@ class Incubator {
|
|
|
50
50
|
// DEBIAN
|
|
51
51
|
switch (this.distro.codenameLikeId) {
|
|
52
52
|
case 'jessie': {
|
|
53
|
-
const jessie = new jessie_1.Jessie(this.installer, this.remix, this.distro,
|
|
53
|
+
const jessie = new jessie_1.Jessie(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
54
54
|
await jessie.create();
|
|
55
55
|
break;
|
|
56
56
|
}
|
|
57
57
|
case 'stretch': {
|
|
58
|
-
const stretch = new jessie_1.Jessie(this.installer, this.remix, this.distro,
|
|
58
|
+
const stretch = new jessie_1.Jessie(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
59
59
|
await stretch.create();
|
|
60
60
|
break;
|
|
61
61
|
}
|
|
62
62
|
case 'buster': {
|
|
63
|
-
const buster = new buster_1.Buster(this.installer, this.remix, this.distro,
|
|
63
|
+
const buster = new buster_1.Buster(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
64
64
|
await buster.create();
|
|
65
65
|
break;
|
|
66
66
|
}
|
|
67
67
|
case 'bullseye': {
|
|
68
|
-
const bullseye = new buster_1.Buster(this.installer, this.remix, this.distro,
|
|
68
|
+
const bullseye = new buster_1.Buster(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
69
69
|
await bullseye.create();
|
|
70
70
|
break;
|
|
71
71
|
}
|
|
72
72
|
case 'bookworm': {
|
|
73
|
-
const bookworm = new buster_1.Buster(this.installer, this.remix, this.distro,
|
|
73
|
+
const bookworm = new buster_1.Buster(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
74
74
|
await bookworm.create();
|
|
75
75
|
// DEVUAN
|
|
76
76
|
break;
|
|
77
77
|
}
|
|
78
|
+
/**
|
|
79
|
+
* DEVUAL
|
|
80
|
+
*/
|
|
78
81
|
case 'beowulf': {
|
|
79
|
-
const beowulf = new buster_1.Buster(this.installer, this.remix, this.distro,
|
|
82
|
+
const beowulf = new buster_1.Buster(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
80
83
|
await beowulf.create();
|
|
81
84
|
break;
|
|
82
85
|
}
|
|
83
86
|
case 'chimaera': {
|
|
84
|
-
const chimaera = new buster_1.Buster(this.installer, this.remix, this.distro,
|
|
87
|
+
const chimaera = new buster_1.Buster(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
85
88
|
await chimaera.create();
|
|
86
89
|
break;
|
|
87
90
|
}
|
|
88
91
|
case 'daedalus': {
|
|
89
|
-
const daedalus = new buster_1.Buster(this.installer, this.remix, this.distro,
|
|
92
|
+
const daedalus = new buster_1.Buster(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
90
93
|
await daedalus.create();
|
|
91
|
-
// UBUNTU
|
|
92
94
|
break;
|
|
93
95
|
}
|
|
94
96
|
/**
|
|
95
|
-
*
|
|
97
|
+
* UBUNTU
|
|
96
98
|
*/
|
|
97
|
-
case 'rolling': {
|
|
98
|
-
release = true;
|
|
99
|
-
const rolling = new rolling_1.Rolling(this.installer, this.remix, this.distro, release, this.user_opt, this.verbose);
|
|
100
|
-
await rolling.create();
|
|
101
|
-
break;
|
|
102
|
-
}
|
|
103
99
|
case 'focal': {
|
|
104
|
-
const focal = new focal_1.Focal(this.installer, this.remix, this.distro,
|
|
100
|
+
const focal = new focal_1.Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
105
101
|
await focal.create();
|
|
106
102
|
break;
|
|
107
103
|
}
|
|
108
104
|
case 'groovy': {
|
|
109
|
-
const groovy = new focal_1.Focal(this.installer, this.remix, this.distro,
|
|
105
|
+
const groovy = new focal_1.Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
110
106
|
await groovy.create();
|
|
111
107
|
break;
|
|
112
108
|
}
|
|
113
109
|
case 'hirsute': {
|
|
114
|
-
const hirsute = new focal_1.Focal(this.installer, this.remix, this.distro,
|
|
110
|
+
const hirsute = new focal_1.Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
115
111
|
await hirsute.create();
|
|
116
112
|
break;
|
|
117
113
|
}
|
|
118
114
|
case 'impish': {
|
|
119
|
-
const impish = new focal_1.Focal(this.installer, this.remix, this.distro,
|
|
115
|
+
const impish = new focal_1.Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
120
116
|
await impish.create();
|
|
121
117
|
break;
|
|
122
118
|
}
|
|
123
119
|
case 'jammy': {
|
|
124
|
-
const jammy = new focal_1.Focal(this.installer, this.remix, this.distro,
|
|
120
|
+
const jammy = new focal_1.Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
125
121
|
await jammy.create();
|
|
126
122
|
break;
|
|
127
123
|
}
|
|
128
124
|
case 'bionic': {
|
|
129
|
-
const bionic = new bionic_1.Bionic(this.installer, this.remix, this.distro,
|
|
125
|
+
const bionic = new bionic_1.Bionic(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
130
126
|
await bionic.create();
|
|
131
127
|
break;
|
|
132
128
|
}
|
|
129
|
+
/**
|
|
130
|
+
* Arch
|
|
131
|
+
*/
|
|
132
|
+
case 'rolling': {
|
|
133
|
+
const rolling = new rolling_1.Rolling(this.installer, this.remix, this.distro, this.user_opt, release, this.verbose);
|
|
134
|
+
await rolling.create();
|
|
135
|
+
break;
|
|
136
|
+
}
|
|
133
137
|
// No default
|
|
134
138
|
}
|
|
135
139
|
this.createBranding();
|
package/lib/classes/ovary.d.ts
CHANGED
|
@@ -21,6 +21,7 @@ export default class Ovary {
|
|
|
21
21
|
snapshot_prefix: string;
|
|
22
22
|
snapshot_basename: string;
|
|
23
23
|
compression: string;
|
|
24
|
+
clone: boolean;
|
|
24
25
|
/**
|
|
25
26
|
* @returns {boolean} success
|
|
26
27
|
*/
|
|
@@ -29,7 +30,7 @@ export default class Ovary {
|
|
|
29
30
|
*
|
|
30
31
|
* @param basename
|
|
31
32
|
*/
|
|
32
|
-
produce(backup: boolean | undefined, scriptOnly: boolean | undefined, yolkRenew: boolean | undefined, release: boolean | undefined, myAddons: IMyAddons, verbose?: boolean): Promise<void>;
|
|
33
|
+
produce(backup: boolean | undefined, clone: boolean | undefined, scriptOnly: boolean | undefined, yolkRenew: boolean | undefined, release: boolean | undefined, myAddons: IMyAddons, verbose?: boolean): Promise<void>;
|
|
33
34
|
/**
|
|
34
35
|
* Crea la struttura della workdir
|
|
35
36
|
*/
|