penguins-eggs 9.0.2 → 9.0.9

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.
Files changed (125) hide show
  1. package/README.md +22 -21
  2. package/addons/blissos/theme/livecd/README.md +2 -2
  3. package/addons/blissos/theme/livecd/grub.theme.cfg +9 -13
  4. package/addons/blissos/theme/livecd/isolinux.theme.cfg +1 -1
  5. package/addons/eggs/theme/livecd/grub.theme.cfg +12 -15
  6. package/addons/neon/theme/livecd/grub.theme.cfg +12 -15
  7. package/addons/templates/grub.template +28 -0
  8. package/addons/{neon/theme/livecd/isolinux.template.cfg → templates/isolinux.template} +7 -7
  9. package/conf/distros/buster/calamares/calamares-modules/sources-yolk/sources-yolk.sh +1 -1
  10. package/conf/distros/buster/calamares/calamares-modules/sources-yolk/sources-yolk.working.sh +1 -1
  11. package/conf/distros/jessie/krill/krill-modules/sources-yolk/sources-yolk.sh +1 -1
  12. package/conf/eggs.yaml +2 -2
  13. package/conf/exclude.list +10 -3
  14. package/lib/classes/daddy.js +6 -0
  15. package/lib/classes/distro.js +26 -1
  16. package/lib/classes/family/archlinux.js +2 -1
  17. package/lib/classes/krill_install.js +20 -6
  18. package/lib/classes/krill_prepare.d.ts +6 -2
  19. package/lib/classes/krill_prepare.js +21 -9
  20. package/lib/classes/ovary.js +49 -16
  21. package/lib/classes/pacman.js +10 -4
  22. package/lib/classes/settings.js +1 -1
  23. package/lib/classes/utils.d.ts +1 -1
  24. package/lib/classes/utils.js +1 -1
  25. package/lib/classes/xdg.js +21 -4
  26. package/lib/classes/yolk.js +2 -2
  27. package/lib/commands/install.d.ts +1 -0
  28. package/lib/commands/install.js +6 -1
  29. package/lib/commands/produce.js +6 -1
  30. package/lib/commands/tools/yolk.js +1 -1
  31. package/lib/components/partitions.d.ts +2 -1
  32. package/lib/components/partitions.js +4 -2
  33. package/lib/interfaces/i-krill.d.ts +1 -0
  34. package/lib/lib/get_password.js +1 -0
  35. package/manpages/doc/man/eggs.html +508 -0
  36. package/manpages/doc/man/eggs.roll.gz +0 -0
  37. package/oclif.manifest.json +1 -1
  38. package/package.json +12 -12
  39. package/scripts/_eggs +246 -0
  40. package/scripts/eggs.bash +1 -1
  41. package/scripts/mom-cli.sh +6 -5
  42. package/addons/blissos/theme/livecd/grub.template.cfg +0 -34
  43. package/addons/blissos/theme/livecd/isolinux.template.cfg +0 -29
  44. package/addons/debian/theme/README.md +0 -23
  45. package/addons/debian/theme/applications/install-debian.desktop +0 -13
  46. package/addons/debian/theme/artwork/install-debian.png +0 -0
  47. package/addons/debian/theme/calamares/branding/branding.desc +0 -27
  48. package/addons/debian/theme/calamares/branding/debian-logo.png +0 -0
  49. package/addons/debian/theme/calamares/branding/show.qml +0 -51
  50. package/addons/debian/theme/calamares/branding/slide1.png +0 -0
  51. package/addons/debian/theme/calamares/branding/welcome.png +0 -0
  52. package/addons/debian/theme/calamares/modules/partition.yml +0 -233
  53. package/addons/debian/theme/livecd/README.md +0 -23
  54. package/addons/debian/theme/livecd/grub.template.cfg +0 -34
  55. package/addons/debian/theme/livecd/grub.theme.cfg +0 -46
  56. package/addons/debian/theme/livecd/isolinux.template.cfg +0 -30
  57. package/addons/debian/theme/livecd/isolinux.theme.cfg +0 -45
  58. package/addons/debian/theme/livecd/splash.png +0 -0
  59. package/addons/deblinux/theme/README.md +0 -23
  60. package/addons/deblinux/theme/applications/install-debian.desktop +0 -13
  61. package/addons/deblinux/theme/artwork/install-debian.png +0 -0
  62. package/addons/deblinux/theme/calamares/branding/branding.desc +0 -23
  63. package/addons/deblinux/theme/calamares/branding/deblinux-logo.png +0 -0
  64. package/addons/deblinux/theme/calamares/branding/show.qml +0 -46
  65. package/addons/deblinux/theme/calamares/branding/slide1.png +0 -0
  66. package/addons/deblinux/theme/calamares/branding/welcome.png +0 -0
  67. package/addons/deblinux/theme/calamares/modules/partition.yml +0 -233
  68. package/addons/eggs/theme/livecd/grub.template.cfg +0 -34
  69. package/addons/eggs/theme/livecd/isolinux.template.cfg +0 -29
  70. package/addons/guadalinex/theme/README.md +0 -9
  71. package/addons/guadalinex/theme/applications/install-debian.desktop +0 -28
  72. package/addons/guadalinex/theme/artwork/install-debian.png +0 -0
  73. package/addons/guadalinex/theme/calamares/branding/branding.desc +0 -1
  74. package/addons/guadalinex/theme/calamares/branding/guadalinex-logo.png +0 -0
  75. package/addons/guadalinex/theme/calamares/branding/show.qml +0 -85
  76. package/addons/guadalinex/theme/calamares/branding/slide1.png +0 -0
  77. package/addons/guadalinex/theme/calamares/branding/slide2.png +0 -0
  78. package/addons/guadalinex/theme/calamares/branding/slide3.png +0 -0
  79. package/addons/guadalinex/theme/calamares/branding/slide4.png +0 -0
  80. package/addons/guadalinex/theme/calamares/branding/slide5.png +0 -0
  81. package/addons/guadalinex/theme/calamares/branding/slide6.png +0 -0
  82. package/addons/guadalinex/theme/calamares/branding/slide7.png +0 -0
  83. package/addons/guadalinex/theme/calamares/branding/welcome.png +0 -0
  84. package/addons/guadalinex/theme/calamares/modules/partition.yml +0 -233
  85. package/addons/guadalinex/theme/livecd/README.md +0 -23
  86. package/addons/guadalinex/theme/livecd/isolinux.template.cfg +0 -63
  87. package/addons/guadalinex/theme/livecd/isolinux.theme.cfg +0 -42
  88. package/addons/guadalinex/theme/livecd/splash.png +0 -0
  89. package/addons/neon/theme/livecd/grub.template.cfg +0 -34
  90. package/addons/openos/theme/applications/Install-OpenOS-Neon_RLTS-Desktop.png +0 -0
  91. package/addons/openos/theme/applications/install-debian.desktop +0 -24
  92. package/addons/openos/theme/artwork/install-debian.png +0 -0
  93. package/addons/openos/theme/calamares/branding/branding.desc +0 -28
  94. package/addons/openos/theme/calamares/branding/openos-logo.png +0 -0
  95. package/addons/openos/theme/calamares/branding/show.qml +0 -203
  96. package/addons/openos/theme/calamares/branding/slide1.png +0 -0
  97. package/addons/openos/theme/calamares/branding/slide10.png +0 -0
  98. package/addons/openos/theme/calamares/branding/slide11.png +0 -0
  99. package/addons/openos/theme/calamares/branding/slide12.png +0 -0
  100. package/addons/openos/theme/calamares/branding/slide13.png +0 -0
  101. package/addons/openos/theme/calamares/branding/slide14.png +0 -0
  102. package/addons/openos/theme/calamares/branding/slide15.png +0 -0
  103. package/addons/openos/theme/calamares/branding/slide16.png +0 -0
  104. package/addons/openos/theme/calamares/branding/slide2.png +0 -0
  105. package/addons/openos/theme/calamares/branding/slide3.png +0 -0
  106. package/addons/openos/theme/calamares/branding/slide4.png +0 -0
  107. package/addons/openos/theme/calamares/branding/slide5.png +0 -0
  108. package/addons/openos/theme/calamares/branding/slide6.png +0 -0
  109. package/addons/openos/theme/calamares/branding/slide7.png +0 -0
  110. package/addons/openos/theme/calamares/branding/slide8.png +0 -0
  111. package/addons/openos/theme/calamares/branding/slide9.png +0 -0
  112. package/addons/openos/theme/calamares/branding/welcome.png +0 -0
  113. package/addons/openos/theme/calamares/branding.desc +0 -24
  114. package/addons/openos/theme/calamares/lang/calamares-default_ar.qm +0 -0
  115. package/addons/openos/theme/calamares/lang/calamares-default_en.qm +0 -0
  116. package/addons/openos/theme/calamares/lang/calamares-default_eo.qm +0 -0
  117. package/addons/openos/theme/calamares/lang/calamares-default_fr.qm +0 -0
  118. package/addons/openos/theme/calamares/lang/calamares-default_nl.qm +0 -0
  119. package/addons/openos/theme/calamares/modules/partition.yml +0 -233
  120. package/addons/openos/theme/livecd/README.md +0 -23
  121. package/addons/openos/theme/livecd/grub.template.cfg +0 -60
  122. package/addons/openos/theme/livecd/grub.theme.cfg +0 -42
  123. package/addons/openos/theme/livecd/isolinux.template.cfg +0 -62
  124. package/addons/openos/theme/livecd/isolinux.theme.cfg +0 -45
  125. package/addons/openos/theme/livecd/splash.png +0 -0
@@ -36,11 +36,15 @@ const get_domain_1 = (0, tslib_1.__importDefault)(require("../lib/get_domain"));
36
36
  const get_dns_1 = (0, tslib_1.__importDefault)(require("../lib/get_dns"));
37
37
  const krill_install_1 = (0, tslib_1.__importDefault)(require("./krill_install"));
38
38
  class Krill {
39
- async prepare() {
39
+ /**
40
+ *
41
+ * @param cryped
42
+ */
43
+ async prepare(cryped = false) {
40
44
  const oWelcome = await this.welcome();
41
45
  const oLocation = await this.location(oWelcome.language);
42
46
  const oKeyboard = await this.keyboard();
43
- const oPartitions = await this.partitions();
47
+ const oPartitions = await this.partitions(cryped);
44
48
  const oUsers = await this.users();
45
49
  const oNetwork = await this.network();
46
50
  await this.summary(oLocation, oKeyboard, oPartitions);
@@ -128,39 +132,47 @@ class Krill {
128
132
  /**
129
133
  * PARTITIONS
130
134
  */
131
- async partitions() {
135
+ async partitions(crypted = false) {
132
136
  let installationDevice = '/dev/sda';
133
137
  let installationMode = 'standard';
138
+ let luksPassphrase = 'evolution';
134
139
  let filesystemType = 'ext4';
135
140
  let userSwapChoice = 'small';
141
+ if (crypted = true) {
142
+ installationMode = 'full-encrypted';
143
+ }
136
144
  let partitionsElem;
137
145
  while (true) {
138
- partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
146
+ partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, luksPassphrase: luksPassphrase, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
139
147
  if (await confirm(partitionsElem, "Confirm Partitions datas?")) {
140
148
  break;
141
149
  }
142
150
  else {
143
151
  installationDevice = '';
144
- installationMode = '';
152
+ if (crypted = true) {
153
+ installationMode = 'full-encrypted';
154
+ }
155
+ luksPassphrase = 'evolution';
145
156
  filesystemType = '';
146
157
  userSwapChoice = '';
147
158
  }
148
- partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
159
+ partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, luksPassphrase: luksPassphrase, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
149
160
  redraw(partitionsElem);
150
161
  installationDevice = await (0, select_installation_device_1.default)();
151
- partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
162
+ partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, luksPassphrase: luksPassphrase, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
152
163
  redraw(partitionsElem);
153
164
  installationMode = await (0, select_installation_mode_1.default)();
154
- partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
165
+ partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, luksPassphrase: luksPassphrase, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
155
166
  redraw(partitionsElem);
156
167
  filesystemType = await (0, select_filesystem_type_1.default)();
157
- partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
168
+ partitionsElem = react_1.default.createElement(partitions_1.default, { installationDevice: installationDevice, installationMode: installationMode, luksPassphrase: luksPassphrase, filesystemType: filesystemType, userSwapChoice: userSwapChoice });
158
169
  redraw(partitionsElem);
159
170
  userSwapChoice = await (0, select_user_swap_choice_1.default)();
160
171
  }
161
172
  return {
162
173
  installationDevice: installationDevice,
163
174
  installationMode: installationMode,
175
+ luksPassphrase: luksPassphrase,
164
176
  filesystemType: filesystemType,
165
177
  userSwapChoice: userSwapChoice
166
178
  };
@@ -547,7 +547,7 @@ class Ovary {
547
547
  * isolinux.cfg from isolinux.template.cfg
548
548
  */
549
549
  const isolinuxDest = this.settings.work_dir.pathIso + 'isolinux/isolinux.cfg';
550
- let isolinuxTemplate = node_path_1.default.resolve(__dirname, `../../addons/${theme}/theme/livecd/isolinux.template.cfg`);
550
+ let isolinuxTemplate = node_path_1.default.resolve(__dirname, `../../addons/templates/isolinux.template`);
551
551
  if (!fs.existsSync(isolinuxTemplate)) {
552
552
  utils_2.default.warning('Cannot find: ' + isolinuxTemplate);
553
553
  process.exit();
@@ -560,7 +560,7 @@ class Ovary {
560
560
  const template = fs.readFileSync(isolinuxTemplate, 'utf8');
561
561
  const view = {
562
562
  fullname: this.settings.remix.fullname.toUpperCase(),
563
- kernel: utils_2.default.kernerlVersion(),
563
+ kernel: utils_2.default.kernelVersion(),
564
564
  vmlinuz: `/live${this.settings.vmlinuz}`,
565
565
  initrdImg: `/live${this.settings.initrdImg}`,
566
566
  kernel_parameters: kernel_parameters,
@@ -1008,6 +1008,16 @@ class Ovary {
1008
1008
  if (this.familyId === 'debian') {
1009
1009
  // add user live to sudo
1010
1010
  cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG sudo ${this.settings.config.user_opt}`, verbose));
1011
+ // educaandos
1012
+ if (this.theme === 'educaandos') {
1013
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG adm ${this.settings.config.user_opt}`, verbose));
1014
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG cdrom ${this.settings.config.user_opt}`, verbose));
1015
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG dip ${this.settings.config.user_opt}`, verbose));
1016
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG plugdev ${this.settings.config.user_opt}`, verbose));
1017
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG lpadmin ${this.settings.config.user_opt}`, verbose));
1018
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG sambashare ${this.settings.config.user_opt}`, verbose));
1019
+ cmds.push(await rexec(`chroot ${this.settings.work_dir.merged} usermod -aG admin ${this.settings.config.user_opt}`, verbose));
1020
+ }
1011
1021
  }
1012
1022
  else if (this.familyId === 'archlinux') {
1013
1023
  // adduser live to wheel and autologin
@@ -1034,7 +1044,6 @@ class Ovary {
1034
1044
  shelljs_1.default.cp(node_path_1.default.resolve(__dirname, '../../assets/krill.svg'), '/usr/share/icons/');
1035
1045
  /**
1036
1046
  * creazione dei link in /usr/share/applications
1037
- *
1038
1047
  */
1039
1048
  shelljs_1.default.cp(node_path_1.default.resolve(__dirname, '../../assets/penguins-eggs.desktop'), '/usr/share/applications/');
1040
1049
  let installerUrl = 'install-debian.desktop';
@@ -1047,14 +1056,18 @@ class Ovary {
1047
1056
  installerIcon = 'utilities-terminal';
1048
1057
  shelljs_1.default.cp(node_path_1.default.resolve(__dirname, '../../assets/penguins-krill.desktop'), `${this.settings.work_dir.merged}/usr/share/applications/`);
1049
1058
  }
1050
- // flags
1059
+ /**
1060
+ * flags
1061
+ */
1062
+ // adapt
1051
1063
  if (myAddons.adapt) {
1052
1064
  // if (Pacman.packageIsInstalled('lxde-core') || Pacman.packageIsInstalled('deepin-desktop-base') || Pacman.packageIsInstalled('mate-desktop') || Pacman.packageIsInstalled('ubuntu-mate-core') || Pacman.packageIsInstalled('xfce4')) {
1053
1065
  const dirAddon = node_path_1.default.resolve(__dirname, `../../addons/eggs/adapt/`);
1054
1066
  shelljs_1.default.cp(`${dirAddon}/applications/eggs-adapt.desktop`, `${this.settings.work_dir.merged}/usr/share/applications/`);
1055
- shelljs_1.default.cp(`${dirAddon}/bin/eggs-adapt.sh`, `${this.settings.work_dir.merged}/usr/local/bin/`);
1067
+ // shx.cp(`${dirAddon}/bin/eggs-adapt.sh`, `${this.settings.work_dir.merged}/usr/local/bin/`)
1056
1068
  // }
1057
1069
  }
1070
+ // ichoice
1058
1071
  if (myAddons.ichoice) {
1059
1072
  installerUrl = 'eggs-ichoice.desktop';
1060
1073
  installerIcon = 'system-software-install';
@@ -1062,6 +1075,7 @@ class Ovary {
1062
1075
  shelljs_1.default.cp(`${dirAddon}/applications/eggs-ichoice.desktop`, `${this.settings.work_dir.merged}/usr/share/applications/`);
1063
1076
  shelljs_1.default.cp(`${dirAddon}/bin/eggs-ichoice.sh`, `${this.settings.work_dir.merged}/usr/local/bin/`);
1064
1077
  }
1078
+ // pve
1065
1079
  if (myAddons.pve) {
1066
1080
  // Imposto service pve-lite
1067
1081
  const pve = new pve_live_1.default();
@@ -1070,6 +1084,7 @@ class Ovary {
1070
1084
  shelljs_1.default.cp(`${dirAddon}/artwork/eggs-pve.png`, `${this.settings.work_dir.merged}/usr/share/icons/`);
1071
1085
  shelljs_1.default.cp(`${dirAddon}/applications/eggs-pve.desktop`, `${this.settings.work_dir.merged}/usr/share/applications/`);
1072
1086
  }
1087
+ // rsupport
1073
1088
  if (myAddons.rsupport) {
1074
1089
  const dirAddon = node_path_1.default.resolve(__dirname, '../../addons/eggs/rsupport');
1075
1090
  shelljs_1.default.cp(`${dirAddon}/applications/eggs-rsupport.desktop`, `${this.settings.work_dir.merged}/usr/share/applications/`);
@@ -1111,6 +1126,23 @@ class Ovary {
1111
1126
  if (myAddons.rsupport)
1112
1127
  text += 'cp /usr/share/applications/eggs-rsupport.desktop $DESKTOP\n';
1113
1128
  }
1129
+ // enable desktop links in gnome
1130
+ /**
1131
+ * test -f /usr/share/applications/penguins-eggs.desktop && cp /usr/share/applications/penguins-eggs.desktop $DESKTOP
1132
+ * test -f "$DESKTOP/penguins-eggs.desktop" && chmod a+x "$DESKTOP/penguins-eggs.desktop"
1133
+ * test -f "$DESKTOP/penguins-eggs.desktop" && gio set "$DESKTOP/penguins-eggs.desktop" metadata::trusted true
1134
+ * test -f /usr/share/applications/install-debian.desktop && cp /usr/share/applications/install-debian.desktop $DESKTOP
1135
+ * test -f "$DESKTOP/install-debian.desktop" && chmod a+x $DESKTOP/install-debian.desktop
1136
+ * test -f "$DESKTOP/install-debian.desktop" && gio set "$DESKTOP/install-debian.desktop" metadata::trusted true
1137
+ */
1138
+ if (pacman_1.default.packageIsInstalled('gdm3') || pacman_1.default.packageIsInstalled('gdm')) {
1139
+ text += `test -f /usr/share/applications/penguins-eggs.desktop && cp /usr/share/applications/penguins-eggs.desktop $DESKTOP\n`;
1140
+ text += `test -f "$DESKTOP/penguins-eggs.desktop" && chmod a+x "$DESKTOP/penguins-eggs.desktop"\n`;
1141
+ text += `test -f "$DESKTOP/penguins-eggs.desktop" && gio set "$DESKTOP/penguins-eggs.desktop" metadata::trusted true\n`;
1142
+ text += `test -f /usr/share/applications/install-debian.desktop && cp /usr/share/applications/install-debian.desktop $DESKTOP\n`;
1143
+ text += `test -f "$DESKTOP/install-debian.desktop" && chmod a+x $DESKTOP/install-debian.desktop\n`;
1144
+ text += `test -f "$DESKTOP/install-debian.desktop" && gio set "$DESKTOP/install-debian.desktop" metadata::trusted true\n`;
1145
+ }
1114
1146
  fs.writeFileSync(script, text, 'utf8');
1115
1147
  await (0, utils_1.exec)(`chmod a+x ${script}`, echo);
1116
1148
  }
@@ -1189,7 +1221,7 @@ class Ovary {
1189
1221
  let text = '';
1190
1222
  text += 'search --file --set=root /.disk/info\n';
1191
1223
  text += 'set prefix=($root)/boot/grub\n';
1192
- text += `source $prefix/x86_64-efi/grub.cfg\n`;
1224
+ text += `source $prefix/${utils_2.default.machineUEFI()}/grub.cfg\n`;
1193
1225
  utils_2.default.write(grubCfg, text);
1194
1226
  // #################################
1195
1227
  /**
@@ -1219,7 +1251,7 @@ class Ovary {
1219
1251
  * copy theme
1220
1252
  */
1221
1253
  const themeDest = `${efiWorkDir}/boot/grub/theme.cfg`;
1222
- const themeSrc = node_path_1.default.resolve(__dirname, `../../addons/${theme}/theme/livecd/isolinux.theme.cfg`);
1254
+ const themeSrc = node_path_1.default.resolve(__dirname, `../../addons/${theme}/theme/livecd/grub.theme.cfg`);
1223
1255
  if (!fs.existsSync(themeSrc)) {
1224
1256
  utils_2.default.warning('Cannot find: ' + themeSrc);
1225
1257
  process.exit();
@@ -1285,7 +1317,7 @@ class Ovary {
1285
1317
  // Do the main grub.cfg (which gets loaded last):
1286
1318
  // grub.theme.cfg
1287
1319
  const grubThemeSrc = node_path_1.default.resolve(__dirname, `../../addons/${theme}/theme/livecd/grub.theme.cfg`);
1288
- const grubThemeDest = `${isoDir}/boot/grub/grub.theme.cfg`;
1320
+ const grubThemeDest = `${isoDir}/boot/grub/theme.cfg`;
1289
1321
  if (!fs.existsSync(grubThemeSrc)) {
1290
1322
  utils_2.default.warning('Cannot find: ' + grubThemeSrc);
1291
1323
  process.exit();
@@ -1294,23 +1326,24 @@ class Ovary {
1294
1326
  /**
1295
1327
  * prepare grub.cfg from grub.template.cfg
1296
1328
  */
1297
- const grubTemplate = node_path_1.default.resolve(__dirname, `../../addons/${theme}/theme/livecd/grub.template.cfg`);
1329
+ const grubTemplate = node_path_1.default.resolve(__dirname, `../../addons/templates/grub.template`);
1298
1330
  if (!fs.existsSync(grubTemplate)) {
1299
1331
  utils_2.default.warning('Cannot find: ' + grubTemplate);
1300
1332
  process.exit();
1301
1333
  }
1334
+ let kernel_parameters = `boot=live locales=${process.env.LANG}`;
1335
+ let volid = utils_2.default.getVolid(this.settings.remix.name);
1336
+ if (this.familyId === "archlinux") {
1337
+ kernel_parameters = `misobasedir=live misolabel=${volid} boot=live locales=${process.env.LANG}`;
1338
+ }
1302
1339
  const grubDest = `${isoDir}/boot/grub/grub.cfg`;
1303
1340
  const template = fs.readFileSync(grubTemplate, 'utf8');
1304
1341
  const view = {
1305
1342
  fullname: this.settings.remix.fullname.toUpperCase(),
1306
- kernel: utils_2.default.kernerlVersion(),
1343
+ kernel: utils_2.default.kernelVersion(),
1307
1344
  vmlinuz: `/live${this.settings.vmlinuz}`,
1308
1345
  initrdImg: `/live${this.settings.initrdImg}`,
1309
- usernameOpt: this.settings.config.user_opt,
1310
- netconfigOpt: this.settings.config.netconfig_opt,
1311
- timezoneOpt: this.settings.config.timezone,
1312
- lang: process.env.LANG,
1313
- locales: process.env.LANG
1346
+ kernel_parameters: kernel_parameters,
1314
1347
  };
1315
1348
  fs.writeFileSync(grubDest, mustache_1.default.render(template, view));
1316
1349
  /**
@@ -1332,7 +1365,7 @@ class Ovary {
1332
1365
  shelljs_1.default.mkdir('-p', dotDisk);
1333
1366
  // .disk/info
1334
1367
  let file = dotDisk + '/info';
1335
- let content = utils_2.default.getVolid(this.settings.remix.name); //this.settings.config.snapshot_prefix + this.settings.config.snapshot_basename
1368
+ let content = utils_2.default.getVolid(this.settings.remix.name);
1336
1369
  fs.writeFileSync(file, content, 'utf-8');
1337
1370
  // .disk/mksquashfs
1338
1371
  const scripts = this.settings.work_dir.path;
@@ -409,7 +409,12 @@ class Pacman {
409
409
  static async autocompleteInstall(verbose = false) {
410
410
  if (this.distro().familyId === 'debian') {
411
411
  if (Pacman.packageIsInstalled('bash-completion')) {
412
- await (0, utils_2.exec)(`cp ${__dirname}/../../scripts/eggs.bash /etc/bash_completion.d/`);
412
+ if (node_fs_1.default.existsSync('/usr/share/bash-completion/completions/')) {
413
+ await (0, utils_2.exec)(`cp ${__dirname}/../../scripts/eggs.bash /usr/share/bash-completion/completions/`);
414
+ }
415
+ else if (node_fs_1.default.existsSync('/etc/bash_completion.d/')) {
416
+ await (0, utils_2.exec)(`cp ${__dirname}/../../scripts/eggs.bash /etc/bash_completion.d/`);
417
+ }
413
418
  }
414
419
  }
415
420
  else if (this.distro().familyId === 'archlinux') {
@@ -422,13 +427,14 @@ class Pacman {
422
427
  * Installa manPage
423
428
  */
424
429
  static async manPageInstall(verbose = false) {
425
- const manPage = node_path_1.default.resolve(__dirname, '../../manpages/doc/man/eggs.1.gz');
426
- if (node_fs_1.default.existsSync(manPage)) {
430
+ const manPageSrc = node_path_1.default.resolve(__dirname, '../../manpages/doc/man/eggs.roll.gz');
431
+ if (node_fs_1.default.existsSync(manPageSrc)) {
427
432
  const man1Dir = '/usr/share/man/man1/';
428
433
  if (!node_fs_1.default.existsSync(man1Dir)) {
429
434
  (0, utils_2.exec)(`mkdir ${man1Dir} -p`);
430
435
  }
431
- (0, utils_2.exec)(`cp ${manPage} ${man1Dir}`);
436
+ const manPageDest = man1Dir + 'eggs.1.gz';
437
+ (0, utils_2.exec)(`cp ${manPageSrc} ${manPageDest}`);
432
438
  if (shelljs_1.default.exec('which mandb', { silent: true }).stdout.trim() !== '') {
433
439
  await (0, utils_2.exec)('mandb > /dev/null');
434
440
  if (verbose) {
@@ -212,7 +212,7 @@ class Settings {
212
212
  */
213
213
  async loadRemix(basename = '', theme = '') {
214
214
  this.remix.versionNumber = utils_1.default.getPackageVersion();
215
- this.remix.kernel = utils_1.default.kernerlVersion();
215
+ this.remix.kernel = utils_1.default.kernelVersion();
216
216
  this.remix.branding = theme === '' ? 'eggs' : theme;
217
217
  this.remix.name = this.config.snapshot_basename;
218
218
  let name = this.config.snapshot_prefix + this.config.snapshot_basename;
@@ -178,7 +178,7 @@ export default class Utils {
178
178
  /**
179
179
  * get the kernel version
180
180
  */
181
- static kernerlVersion(): string;
181
+ static kernelVersion(): string;
182
182
  /**
183
183
  * return the name of network device
184
184
  */
@@ -481,7 +481,7 @@ class Utils {
481
481
  /**
482
482
  * get the kernel version
483
483
  */
484
- static kernerlVersion() {
484
+ static kernelVersion() {
485
485
  return os_1.default.release();
486
486
  }
487
487
  /**
@@ -84,7 +84,14 @@ class Xdg {
84
84
  }
85
85
  // lightdm
86
86
  if (pacman_1.default.packageIsInstalled('lightdm')) {
87
- shelljs_1.default.sed('-i', `autologin-user=${olduser}`, `autologin-user=${newuser}`, `${chroot}/etc/lightdm/lightdm.conf`);
87
+ if (node_fs_1.default.existsSync(`${chroot}/etc/lightdm/lightdm.conf`)) {
88
+ shelljs_1.default.sed('-i', `autologin-user=${olduser}`, `autologin-user=${newuser}`, `${chroot}/etc/lightdm/lightdm.conf`);
89
+ }
90
+ else {
91
+ const autologin = `${chroot}/etc/lightdm/lightdm.conf`;
92
+ const content = `[Seat:*]\nautologin-user=${newuser}`;
93
+ node_fs_1.default.writeFileSync(autologin, content, 'utf-8');
94
+ }
88
95
  }
89
96
  // sddm
90
97
  if (pacman_1.default.packageIsInstalled('sddm')) {
@@ -111,10 +118,20 @@ class Xdg {
111
118
  }
112
119
  }
113
120
  }
114
- // gdm3
121
+ // gdm3 in ubuntu, gdm in manjaro
115
122
  if (pacman_1.default.packageIsInstalled('gdm3')) {
116
- shelljs_1.default.sed('-i', 'AutomaticLoginEnable=False', 'AutomaticLoginEnable=True', `${chroot}/etc/gdm3/custom.conf`);
117
- shelljs_1.default.sed('-i', `AutomaticLogin=${olduser}`, `AutomaticLogin=${newuser}`, `${chroot}/etc/gdm3/custom.conf`);
123
+ const gdm3Custom = `${chroot}/etc/gdm3/custom.conf`;
124
+ if (node_fs_1.default.existsSync(gdm3Custom)) {
125
+ shelljs_1.default.sed('-i', 'AutomaticLoginEnable=False', 'AutomaticLoginEnable=True', gdm3Custom);
126
+ shelljs_1.default.sed('-i', `AutomaticLogin=${olduser}`, `AutomaticLogin=${newuser}`, gdm3Custom);
127
+ }
128
+ }
129
+ else if (pacman_1.default.packageIsInstalled('gdm')) {
130
+ const gdmCustom = `${chroot}/etc/gdm/custom.conf`;
131
+ if (node_fs_1.default.existsSync(gdmCustom)) {
132
+ shelljs_1.default.sed('-i', 'AutomaticLoginEnable=False', 'AutomaticLoginEnable=True', gdmCustom);
133
+ shelljs_1.default.sed('-i', `AutomaticLogin=${olduser}`, `AutomaticLogin=${newuser}`, gdmCustom);
134
+ }
118
135
  }
119
136
  }
120
137
  }
@@ -28,7 +28,7 @@ class Yolk {
28
28
  /**
29
29
  * riga apt
30
30
  *
31
- * deb [trusted=yes] file:/usr/local/yolk ./
31
+ * deb [trusted=yes] file:/var/local/yolk ./
32
32
  *
33
33
  */
34
34
  utils_1.default.warning('updating system...');
@@ -114,7 +114,7 @@ class Yolk {
114
114
  }
115
115
  }
116
116
  }
117
- // e li vado a scaricare in /usr/local/yolk
117
+ // e li vado a scaricare in /var/local/yolk
118
118
  for (const toDownload of toDownloads) {
119
119
  process.chdir(this.dir);
120
120
  const cmd = `apt-get download ${toDownload}`;
@@ -11,6 +11,7 @@ import { Command } from '@oclif/core';
11
11
  export default class Install extends Command {
12
12
  static flags: {
13
13
  cli: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
14
+ crypted: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
14
15
  help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
15
16
  verbose: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
16
17
  };
@@ -23,6 +23,10 @@ class Install extends core_1.Command {
23
23
  async run() {
24
24
  utils_1.default.titles(this.id + ' ' + this.argv);
25
25
  const { flags } = await this.parse(Install);
26
+ let crypted = false;
27
+ if (flags.crypted) {
28
+ crypted = true;
29
+ }
26
30
  let verbose = false;
27
31
  if (flags.verbose) {
28
32
  verbose = true;
@@ -38,7 +42,7 @@ class Install extends core_1.Command {
38
42
  }
39
43
  else {
40
44
  const krill = new krill_prepare_1.default();
41
- await krill.prepare();
45
+ await krill.prepare(crypted);
42
46
  }
43
47
  }
44
48
  }
@@ -50,6 +54,7 @@ class Install extends core_1.Command {
50
54
  exports.default = Install;
51
55
  Install.flags = {
52
56
  cli: core_1.Flags.boolean({ char: 'c', description: 'force use CLI installer' }),
57
+ crypted: core_1.Flags.boolean({ char: 'k', description: 'crypted CLI installation' }),
53
58
  help: core_1.Flags.help({ char: 'h' }),
54
59
  verbose: core_1.Flags.boolean({ char: 'v', description: 'verbose' })
55
60
  };
@@ -73,7 +73,9 @@ class Produce extends core_1.Command {
73
73
  else if (compressors.isEnabled.lz4) {
74
74
  fastest = 'lz4';
75
75
  }
76
- // jessie e stretch usano solo normal
76
+ /**
77
+ * jessie e stretch will use gzip for fastest
78
+ */
77
79
  const settings = new settings_1.default();
78
80
  if (settings.distro.versionLike === 'jessie' || settings.distro.versionLike === 'stretch') {
79
81
  fastest = 'gzip';
@@ -96,6 +98,9 @@ class Produce extends core_1.Command {
96
98
  if (release) {
97
99
  compression = 'xz -Xbcj x86';
98
100
  }
101
+ /**
102
+ * theme: if not defined will use eggs
103
+ */
99
104
  let theme = 'eggs';
100
105
  if (flags.theme !== undefined) {
101
106
  theme = flags.theme;
@@ -42,4 +42,4 @@ DevYolk.flags = {
42
42
  help: core_1.Flags.help({ char: 'h' }),
43
43
  verbose: core_1.Flags.boolean({ char: 'v' })
44
44
  };
45
- DevYolk.dir = '/usr/local/yolk';
45
+ DevYolk.dir = '/var/local/yolk';
@@ -2,8 +2,9 @@
2
2
  declare type partitionsProps = {
3
3
  installationDevice?: string;
4
4
  installationMode?: string;
5
+ luksPassphrase: string;
5
6
  filesystemType?: string;
6
7
  userSwapChoice?: string;
7
8
  };
8
- export default function Partitions({ installationDevice, installationMode, filesystemType, userSwapChoice }: partitionsProps): JSX.Element;
9
+ export default function Partitions({ installationDevice, installationMode, luksPassphrase, filesystemType, userSwapChoice }: partitionsProps): JSX.Element;
9
10
  export {};
@@ -10,7 +10,7 @@ const title_1 = (0, tslib_1.__importDefault)(require("./elements/title"));
10
10
  const steps_1 = (0, tslib_1.__importDefault)(require("./elements/steps"));
11
11
  const js_yaml_1 = (0, tslib_1.__importDefault)(require("js-yaml"));
12
12
  const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
13
- function Partitions({ installationDevice, installationMode, filesystemType, userSwapChoice }) {
13
+ function Partitions({ installationDevice, installationMode, luksPassphrase, filesystemType, userSwapChoice }) {
14
14
  let installer = 'krill';
15
15
  let productName = 'unknown';
16
16
  let version = 'x.x.x';
@@ -57,13 +57,15 @@ function Partitions({ installationDevice, installationMode, filesystemType, user
57
57
  react_1.default.createElement(ink_1.Box, null,
58
58
  react_1.default.createElement(ink_1.Text, null, "BIOS: "),
59
59
  react_1.default.createElement(ink_1.Text, { color: "cyan" }, bios)),
60
- react_1.default.createElement(ink_1.Newline, null),
61
60
  react_1.default.createElement(ink_1.Box, null,
62
61
  react_1.default.createElement(ink_1.Text, null, "Installation device: "),
63
62
  react_1.default.createElement(ink_1.Text, { color: "cyan" }, installationDevice)),
64
63
  react_1.default.createElement(ink_1.Box, null,
65
64
  react_1.default.createElement(ink_1.Text, null, "Installation mode: "),
66
65
  react_1.default.createElement(ink_1.Text, { color: "cyan" }, installationMode)),
66
+ react_1.default.createElement(ink_1.Box, null,
67
+ react_1.default.createElement(ink_1.Text, null, "LUKS passphrase: "),
68
+ react_1.default.createElement(ink_1.Text, { color: "cyan" }, luksPassphrase)),
67
69
  react_1.default.createElement(ink_1.Box, null,
68
70
  react_1.default.createElement(ink_1.Text, null, "Filesystem: "),
69
71
  react_1.default.createElement(ink_1.Text, { color: "cyan" }, filesystemType)),
@@ -14,6 +14,7 @@ export interface IKeyboard {
14
14
  export interface IPartitions {
15
15
  installationDevice: string;
16
16
  installationMode: string;
17
+ luksPassphrase: string;
17
18
  filesystemType: string;
18
19
  userSwapChoice: string;
19
20
  }
@@ -1,5 +1,6 @@
1
1
  'use strict';
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ //import { option } from '@oclif/command/lib/flags'
3
4
  const inquirer = require("inquirer");
4
5
  async function getPassword(initial) {
5
6
  const requireLetterAndNumber = (value) => {