penguins-eggs 25.10.30 → 25.11.8

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 (123) hide show
  1. package/.oclif.manifest.json +4 -4
  2. package/README.md +770 -3
  3. package/addons/eggs/adapt/applications/eggs-adapt.desktop +0 -0
  4. package/addons/eggs/pve/applications/eggs-pve.desktop +0 -0
  5. package/addons/eggs/rsupport/applications/eggs-rsupport.desktop +0 -0
  6. package/addons/eggs/theme/applications/install-system.desktop +0 -0
  7. package/assets/calamares/install-system.sh +0 -0
  8. package/assets/penguins-eggs.desktop +0 -0
  9. package/assets/penguins-krill.desktop +0 -0
  10. package/assets/penguins-links-add.desktop +0 -0
  11. package/assets/penguins-live-installer.desktop +0 -0
  12. package/bin/dev.js +0 -0
  13. package/conf/distros/alpine/calamares/calamares-modules/machineid-openrc/machineid-openrc.sh +0 -0
  14. package/conf/distros/alpine/calamares/modules/packages.mustache +1 -0
  15. package/conf/distros/alpine/calamares/modules/removeuser.mustache +2 -14
  16. package/conf/distros/alpine/calamares/modules/unpackfs.mustache +2 -2
  17. package/conf/distros/buster/calamares/calamares-modules/cleanup/cleanup.sh +0 -0
  18. package/conf/distros/buster/calamares/calamares-modules/dpkg-unsafe-io/dpkg-unsafe-io.sh +0 -0
  19. package/conf/distros/buster/calamares/calamares-modules/sources-yolk/sources-yolk.sh +0 -0
  20. package/conf/distros/buster/calamares/modules/shellprocess@boot_deploy.yml +1 -16
  21. package/conf/distros/fedora/calamares/calamares-modules/bootloaderspecification/bootloaderspecification.sh +0 -0
  22. package/conf/distros/noble/calamares/calamares-modules/cleanup/cleanup.sh +0 -0
  23. package/conf/distros/noble/calamares/calamares-modules/sources-yolk/sources-yolk.sh +0 -0
  24. package/conf/distros/noble/calamares/libexec/calamares-aptsources.sh +0 -0
  25. package/conf/distros/noble/calamares/libexec/calamares-l10n-helper.sh +0 -0
  26. package/conf/distros/noble/calamares/libexec/calamares-logs-helper.sh +1 -1
  27. package/conf/distros/noble/calamares/libexec/calamares-nomodeset.sh +0 -0
  28. package/conf/distros/noble/calamares/modules/shellprocess@boot_deploy.yml +1 -11
  29. package/conf/distros/noble/calamares/modules/shellprocess@logs.yml +1 -1
  30. package/conf/distros/opensuse/calamares/calamares-modules/bootloaderspecification/bootloaderspecification.sh +0 -0
  31. package/conf/distros/opensuse/calamares/settings.yml +0 -0
  32. package/conf/distros/opensuse/calamares/zstd2lzo.sh +0 -0
  33. package/conf/distros/trixie/calamares/calamares-modules/cleanup/cleanup.sh +0 -0
  34. package/conf/distros/trixie/calamares/calamares-modules/dpkg-unsafe-io/dpkg-unsafe-io.sh +0 -0
  35. package/conf/distros/trixie/calamares/calamares-modules/sources-yolk/sources-yolk.sh +0 -0
  36. package/conf/distros/trixie/calamares/modules/shellprocess@boot_deploy.yml +2 -10
  37. package/conf/init/unattended.sh +0 -0
  38. package/dist/classes/cli-autologin.d.ts +1 -39
  39. package/dist/classes/cli-autologin.js +85 -110
  40. package/dist/classes/daddy.d.ts +30 -12
  41. package/dist/classes/daddy.js +166 -137
  42. package/dist/classes/distro-hossein.d.ts +52 -0
  43. package/dist/classes/distro-hossein.js +239 -0
  44. package/dist/classes/diversions.d.ts +3 -37
  45. package/dist/classes/diversions.js +72 -103
  46. package/dist/classes/incubation/fisherman.d.ts +5 -0
  47. package/dist/classes/incubation/fisherman.js +21 -1
  48. package/dist/classes/incubation/incubator.d/noble.js +6 -2
  49. package/dist/classes/incubation/incubator.js +2 -3
  50. package/dist/classes/keyboards.d.ts +11 -30
  51. package/dist/classes/keyboards.js +100 -251
  52. package/dist/classes/ovary.d/initrd.js +2 -7
  53. package/dist/classes/pacman.js +7 -9
  54. package/dist/commands/tools/repo.js +198 -31
  55. package/dist/krill/classes/sequence.d/unpackfs.js +3 -2
  56. package/dracut/create-symlink +0 -0
  57. package/dracut/export +0 -0
  58. package/dracut/export-dracut-analysis +0 -0
  59. package/dracut/export-dracut-log +0 -0
  60. package/dracut/mkisofs +0 -0
  61. package/dracut/modules.d/00debug-shell/debug-hook.sh +0 -0
  62. package/dracut/modules.d/00debug-shell/module-setup.sh +0 -0
  63. package/dracut/modules.d/90block/block-cmdline.sh +0 -0
  64. package/dracut/modules.d/90block/module-setup.sh +0 -0
  65. package/dracut/modules.d/95iso-scan/iso-scan-fallback.sh +0 -0
  66. package/dracut/modules.d/95iso-scan/iso-scan.sh +0 -0
  67. package/dracut/modules.d/95iso-scan/module-setup.sh +0 -0
  68. package/dracut/modules.d/95luks-loop/luks-loop.sh +0 -0
  69. package/dracut/modules.d/95luks-loop/module-setup.sh +0 -0
  70. package/dracut/renew-initramfs +0 -0
  71. package/dracut/sbin2bin +0 -0
  72. package/dracut/update-dracut-conf-d +0 -0
  73. package/dracut/update-dracut-modules +0 -0
  74. package/eui/eui-autostart-cinnamon.desktop +0 -0
  75. package/eui/eui-autostart-xfce.desktop +0 -0
  76. package/eui/eui-create-image.sh +0 -0
  77. package/eui/eui-start.sh +0 -0
  78. package/package.json +130 -124
  79. package/perrisbrewery/scripts/postinst +0 -0
  80. package/perrisbrewery/scripts/postrm +0 -0
  81. package/perrisbrewery/scripts/preinst +0 -0
  82. package/perrisbrewery/scripts/prerm +0 -0
  83. package/perrisbrewery/template/dependencies.yaml +7 -6
  84. package/scripts/99clean +0 -0
  85. package/scripts/adapt.sh +0 -0
  86. package/scripts/boot-encrypted-root.sh +0 -0
  87. package/scripts/bros/waydroid-helper.sh +0 -0
  88. package/scripts/lsb_release +0 -0
  89. package/scripts/mom.sh +0 -0
  90. package/scripts/mount-encrypted-home.sh +0 -0
  91. package/scripts/pve-live.service +0 -0
  92. package/scripts/pve-live.sh +0 -0
  93. package/scripts/resy +0 -0
  94. package/conf/distros/focal/calamares/calamares-modules/.keepit +0 -0
  95. package/conf/distros/focal/calamares/calamares-modules/cleanup/cleanup.sh +0 -20
  96. package/conf/distros/focal/calamares/calamares-modules/cleanup/module.yml +0 -9
  97. package/conf/distros/focal/calamares/calamares-modules/sources-yolk/module.yml +0 -8
  98. package/conf/distros/focal/calamares/calamares-modules/sources-yolk/sources-yolk.sh +0 -50
  99. package/conf/distros/focal/calamares/calamares-modules/sources-yolk-undo/module.yml +0 -8
  100. package/conf/distros/focal/calamares/modules/after_bootloader_context.yml +0 -19
  101. package/conf/distros/focal/calamares/modules/automirror.yml +0 -6
  102. package/conf/distros/focal/calamares/modules/before_bootloader_context.yml +0 -19
  103. package/conf/distros/focal/calamares/modules/before_bootloader_mkdirs_context.yml +0 -11
  104. package/conf/distros/focal/calamares/modules/bootloader.yml +0 -34
  105. package/conf/distros/focal/calamares/modules/displaymanager.yml +0 -12
  106. package/conf/distros/focal/calamares/modules/finished.yml +0 -4
  107. package/conf/distros/focal/calamares/modules/fstab.yml +0 -13
  108. package/conf/distros/focal/calamares/modules/grubcfg.yml +0 -5
  109. package/conf/distros/focal/calamares/modules/locale.yml +0 -9
  110. package/conf/distros/focal/calamares/modules/machineid.yml +0 -9
  111. package/conf/distros/focal/calamares/modules/mount.yml +0 -41
  112. package/conf/distros/focal/calamares/modules/packages.mustache +0 -5
  113. package/conf/distros/focal/calamares/modules/partition.yml +0 -10
  114. package/conf/distros/focal/calamares/modules/removeuser.mustache +0 -3
  115. package/conf/distros/focal/calamares/modules/shellprocess_add386arch.yml +0 -6
  116. package/conf/distros/focal/calamares/modules/shellprocess_bug-LP#1829805.yml +0 -5
  117. package/conf/distros/focal/calamares/modules/shellprocess_logs.yml +0 -6
  118. package/conf/distros/focal/calamares/modules/unpackfs.mustache +0 -6
  119. package/conf/distros/focal/calamares/modules/users.yml +0 -19
  120. package/conf/distros/focal/calamares/modules/welcome.yml +0 -26
  121. package/conf/distros/focal/calamares/settings.yml +0 -72
  122. package/dist/classes/incubation/incubator.d/focal.d.ts +0 -32
  123. package/dist/classes/incubation/incubator.d/focal.js +0 -85
@@ -1,53 +1,19 @@
1
1
  /**
2
2
  * ./src/classes/diversions.ts
3
3
  * penguins-eggs v.25.7.x / ecmascript 2020
4
- * author: Piero Proietti
5
- * email: piero.proietti@gmail.com
4
+ * author: Piero Proietti (modified by Hossein Seilani)
6
5
  * license: MIT
7
- */
8
- /**
9
- * contiene le variazione di nome
10
- * per ogni famiglia
6
+ *
7
+ * NEW VERSION: Improved and cleaned with detailed comments and new changes
11
8
  */
12
9
  import { IDistro } from '../interfaces/index.js';
13
10
  export default class Diversions {
14
- /**
15
- *
16
- * @param familyId
17
- * @returns
18
- */
19
11
  static isSystemDBoot(familyId: string, isEfi: boolean): boolean;
20
- /**
21
- *
22
- * @param familyId
23
- * @returns deluser
24
- */
25
12
  static deluser(familyId: string): string;
26
- /**
27
- *
28
- * @param familyId
29
- * @returns
30
- */
31
13
  static grubName(familyId: string): string;
32
- /**
33
- * grubForce
34
- */
35
14
  static grubForce(familyId: string): string;
36
- /**
37
- *
38
- * @param familyId
39
- * @param volid
40
- * @returns
41
- */
42
15
  static kernelParameters(familyId: string, volid: string, fullCrypt?: boolean): string;
43
- /**
44
- *
45
- * @returns
46
- */
47
16
  static distro(): IDistro;
48
- /**
49
- * isManjaroBased
50
- */
51
17
  static isManjaroBased(distro: string): boolean;
52
18
  static bootloaders(familyId: string): string;
53
19
  }
@@ -1,131 +1,100 @@
1
1
  /**
2
2
  * ./src/classes/diversions.ts
3
3
  * penguins-eggs v.25.7.x / ecmascript 2020
4
- * author: Piero Proietti
5
- * email: piero.proietti@gmail.com
4
+ * author: Piero Proietti (modified by Hossein Seilani)
6
5
  * license: MIT
6
+ *
7
+ * NEW VERSION: Improved and cleaned with detailed comments and new changes
7
8
  */
8
9
  import Distro from './distro.js';
9
10
  export default class Diversions {
10
- /**
11
- *
12
- * @param familyId
13
- * @returns
14
- */
11
+ // NEW CHANGE [1]
12
+ // Made isSystemDBoot more readable by using direct return without extra variable.
13
+ // Simplified logic for clarity.
15
14
  static isSystemDBoot(familyId, isEfi) {
16
- let isSystemDBoot = false;
17
- if (familyId === 'fedora' && isEfi) {
18
- isSystemDBoot = true;
19
- }
20
- return isSystemDBoot;
15
+ return familyId === 'fedora' && isEfi;
21
16
  }
22
- /**
23
- *
24
- * @param familyId
25
- * @returns deluser
26
- */
17
+ // NEW CHANGE [2]
18
+ // Simplified deluser function using array.includes and default value.
19
+ // This makes adding new families easier and avoids long OR chains.
27
20
  static deluser(familyId) {
28
- let deluser = 'deluser';
29
- if (familyId === 'aldos' ||
30
- familyId === 'archlinux' ||
31
- familyId === 'fedora' ||
32
- familyId === 'openmamba' ||
33
- familyId === 'opensuse' ||
34
- familyId === 'voidlinux') {
35
- deluser = 'userdel';
36
- }
37
- return deluser;
21
+ const userdelFamilies = ['aldos', 'archlinux', 'fedora', 'openmamba', 'opensuse', 'voidlinux'];
22
+ return userdelFamilies.includes(familyId) ? 'userdel' : 'deluser';
38
23
  }
39
- /**
40
- *
41
- * @param familyId
42
- * @returns
43
- */
24
+ // NEW CHANGE [3]
25
+ // Improved grubName using array.includes and direct return
26
+ // Cleaner, easier to maintain if new families are added
44
27
  static grubName(familyId) {
45
- let grubName = 'grub';
46
- if (familyId === 'aldos' ||
47
- familyId === 'fedora' ||
48
- familyId === 'opensuse') {
49
- grubName = 'grub2';
50
- }
51
- return grubName;
28
+ const grub2Families = ['aldos', 'fedora', 'opensuse'];
29
+ return grub2Families.includes(familyId) ? 'grub2' : 'grub';
52
30
  }
53
- /**
54
- * grubForce
55
- */
31
+ // NEW CHANGE [4]
32
+ // Simplified grubForce function with array.includes
33
+ // Provides explicit "--force" only for specific families
56
34
  static grubForce(familyId) {
57
- let grubForce = '';
58
- if (familyId === 'aldos' || familyId === 'fedora') {
59
- grubForce = '--force';
60
- }
61
- return grubForce;
35
+ const forceFamilies = ['aldos', 'fedora'];
36
+ return forceFamilies.includes(familyId) ? '--force' : '';
62
37
  }
63
- /**
64
- *
65
- * @param familyId
66
- * @param volid
67
- * @returns
68
- */
38
+ // NEW CHANGE [5]
39
+ // Improved kernelParameters function:
40
+ // - Use template literals consistently
41
+ // - Reduce redundant code
42
+ // - Added optional `fullCrypt` handling for debian
69
43
  static kernelParameters(familyId, volid, fullCrypt = false) {
70
- // GRUB_CMDLINE_LINUX='ipv6.disable=1'
71
- let kp = "";
72
- if (familyId === 'alpine') {
73
- kp += `alpinelivelabel=${volid} alpinelivesquashfs=/mnt/live/filesystem.squashfs`;
74
- }
75
- else if (familyId === 'archlinux') {
76
- kp += `boot=live components locales=${process.env.LANG}`;
77
- const distroId = this.distro().distroId;
78
- if (this.isManjaroBased(distroId)) {
79
- kp += ` misobasedir=manjaro misolabel=${volid}`;
80
- }
81
- else {
82
- kp += ` archisobasedir=arch archisolabel=${volid}`;
83
- }
84
- }
85
- else if (familyId === 'debian') {
86
- kp += `boot=live components locales=${process.env.LANG} cow_spacesize=2G`;
87
- if (fullCrypt) {
88
- kp += ` live-media=/run/live/medium`;
44
+ let kp = '';
45
+ switch (familyId) {
46
+ case 'alpine':
47
+ kp += `alpinelivelabel=${volid} alpinelivesquashfs=/mnt/live/filesystem.squashfs`;
48
+ break;
49
+ case 'archlinux': {
50
+ const distroId = this.distro().distroId;
51
+ kp += `boot=live components locales=${process.env.LANG}`;
52
+ if (this.isManjaroBased(distroId)) {
53
+ kp += ` misobasedir=manjaro misolabel=${volid}`;
54
+ }
55
+ else {
56
+ kp += ` archisobasedir=arch archisolabel=${volid}`;
57
+ }
58
+ break;
89
59
  }
90
- }
91
- else if (familyId === 'fedora') {
92
- kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs selinux=0`;
93
- }
94
- else if (familyId === 'openmamba') {
95
- kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs selinux=0`;
96
- }
97
- else if (familyId === 'opensuse') {
98
- kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs apparmor=0`;
99
- }
100
- else if (familyId === 'voidlinux') {
101
- kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs rd.debug`;
60
+ case 'debian':
61
+ kp += `boot=live components locales=${process.env.LANG} cow_spacesize=2G`;
62
+ if (fullCrypt)
63
+ kp += ` live-media=/run/live/medium`;
64
+ break;
65
+ case 'fedora':
66
+ case 'openmamba':
67
+ kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs selinux=0`;
68
+ break;
69
+ case 'opensuse':
70
+ kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs apparmor=0`;
71
+ break;
72
+ case 'voidlinux':
73
+ kp += `root=live:CDLABEL=${volid} rd.live.image rd.live.dir=/live rd.live.squashimg=filesystem.squashfs rd.debug`;
74
+ break;
75
+ default:
76
+ kp += '';
77
+ break;
102
78
  }
103
79
  return kp;
104
80
  }
105
- /**
106
- *
107
- * @returns
108
- */
81
+ // NEW CHANGE [6]
82
+ // Centralized creation of Distro instance
83
+ // Ensures only one point of modification for Distro
109
84
  static distro() {
110
85
  return new Distro();
111
86
  }
112
- /**
113
- * isManjaroBased
114
- */
87
+ // NEW CHANGE [7]
88
+ // Simplified isManjaroBased function using array.includes
89
+ // Makes it easier to maintain and extend to new derivatives
115
90
  static isManjaroBased(distro) {
116
- let found = false;
117
- if (distro === 'Manjaro' ||
118
- distro === `Biglinux` ||
119
- distro === `Bigcommunity`) {
120
- found = true;
121
- }
122
- return found;
91
+ const manjaroFamilies = ['Manjaro', 'Biglinux', 'Bigcommunity'];
92
+ return manjaroFamilies.includes(distro);
123
93
  }
94
+ // NEW CHANGE [8]
95
+ // bootloaders path handling improved
96
+ // Default path for debian, custom path for all other families
124
97
  static bootloaders(familyId) {
125
- let bootloaders = '/usr/lib/';
126
- if (familyId !== 'debian') {
127
- bootloaders = '/usr/lib/penguins-eggs/bootloaders/';
128
- }
129
- return bootloaders;
98
+ return familyId === 'debian' ? '/usr/lib/' : '/usr/lib/penguins-eggs/bootloaders/';
130
99
  }
131
100
  }
@@ -35,6 +35,11 @@ export default class Fisherman {
35
35
  * @param name
36
36
  */
37
37
  shellprocess(name: string): Promise<void>;
38
+ /**
39
+ *
40
+ * @param name
41
+ */
42
+ helper(name: string): Promise<void>;
38
43
  /**
39
44
  *
40
45
  * @param module
@@ -145,12 +145,32 @@ export default class Fisherman {
145
145
  if (fs.existsSync(moduleSource)) {
146
146
  if (this.verbose)
147
147
  this.show(name, 'shellprocess', moduleDest);
148
- shx.cp(moduleSource, moduleDest);
148
+ let fileContent = fs.readFileSync(moduleSource, 'utf-8');
149
+ fileContent = fileContent.replace(/__LIVE_MEDIUM_PATH__/g, this.distro.liveMediumPath);
150
+ fs.writeFileSync(moduleDest, fileContent, 'utf-8');
149
151
  }
150
152
  else if (this.verbose) {
151
153
  console.log(`calamares: ${name} shellprocess, nothing to do`);
152
154
  }
153
155
  }
156
+ /**
157
+ *
158
+ * @param name
159
+ */
160
+ async helper(name) {
161
+ const helperSource = path.resolve(__dirname, this.installer.template + 'libexec/' + name + '.sh');
162
+ const helperDest = '/usr/libexec/calamares/' + name + '.sh';
163
+ if (fs.existsSync(helperSource)) {
164
+ if (this.verbose)
165
+ this.show(name, 'helper', helperDest);
166
+ let fileContent = fs.readFileSync(helperSource, 'utf-8');
167
+ fileContent = fileContent.replace(/__LIVE_MEDIUM_PATH__/g, this.distro.liveMediumPath);
168
+ fs.writeFileSync(helperDest, fileContent, { encoding: 'utf-8', mode: 0o755 });
169
+ }
170
+ else if (this.verbose) {
171
+ console.log(`calamares: ${name} helper, nothing to do`);
172
+ }
173
+ }
154
174
  /**
155
175
  *
156
176
  * @param module
@@ -84,8 +84,12 @@ export class Noble {
84
84
  // libexec recreate
85
85
  await exec(`rm -rf /usr/libexec/calamares`);
86
86
  await exec(`mkdir -p /usr/libexec/calamares`);
87
- const scriptSrc = path.resolve(__dirname, '../../../../conf/distros/noble/calamares/libexec/');
88
- await exec(`cp ${scriptSrc}/*.sh /usr/libexec/calamares/`);
87
+ // const scriptSrc=path.resolve(__dirname, '../../../../conf/distros/noble/calamares/libexec/')
88
+ // await exec (`cp ${scriptSrc}/*.sh /usr/libexec/calamares/`)
89
+ await fisherman.helper('calamares-aptsources');
90
+ await fisherman.helper('calamares-l10n-helper');
91
+ await fisherman.helper('calamares-logs-helper'); // Sostituzione __LIVE_MEDIUM_PATH__
92
+ await fisherman.helper('calamares-nomodeset');
89
93
  /**
90
94
  * cfs: custom final steps
91
95
  */
@@ -25,7 +25,6 @@ import { Archlinux } from './incubator.d/archlinux.js';
25
25
  import { Buster } from './incubator.d/buster.js';
26
26
  import { Trixie } from './incubator.d/trixie.js';
27
27
  import { Fedora } from './incubator.d/fedora.js';
28
- import { Focal } from './incubator.d/focal.js';
29
28
  import { Noble } from './incubator.d/noble.js';
30
29
  import { Openmamba } from './incubator.d/openmamba.js';
31
30
  import { Opensuse } from './incubator.d/opensuse.js';
@@ -161,11 +160,11 @@ export default class Incubator {
161
160
  */
162
161
  }
163
162
  else if (distroUniqueId === 'focal') {
164
- const focal = new Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.theme, this.isClone, this.verbose);
163
+ const focal = new Noble(this.installer, this.remix, this.distro, this.user_opt, release, this.theme, this.isClone, this.verbose);
165
164
  await focal.create();
166
165
  }
167
166
  else if (distroUniqueId === 'jammy') {
168
- const jammy = new Focal(this.installer, this.remix, this.distro, this.user_opt, release, this.theme, this.isClone, this.verbose);
167
+ const jammy = new Noble(this.installer, this.remix, this.distro, this.user_opt, release, this.theme, this.isClone, this.verbose);
169
168
  await jammy.create();
170
169
  }
171
170
  else if (distroUniqueId === 'noble') {
@@ -1,50 +1,31 @@
1
1
  /**
2
2
  * ./src/classes/keyboards.ts
3
3
  * penguins-eggs v.25.7.x / ecmascript 2020
4
- * author: Piero Proietti
4
+ * author: Piero Proietti (modified)
5
5
  * email: piero.proietti@gmail.com
6
6
  * license: MIT
7
7
  */
8
8
  import { IXkbLayout, IXkbModel, IXkbOption, IXkbVariant } from '../interfaces/i-xkb-model.js';
9
9
  /**
10
- * /usr/share/X11/xkb/rules/xorg.lst
10
+ * Keyboard class - reads and manages X11 keyboard configuration
11
11
  */
12
12
  export default class Keyboard {
13
- layouts: string[];
14
- models: string[];
15
- options: string[];
16
- variants: string[];
13
+ layouts: IXkbLayout[];
14
+ models: IXkbModel[];
15
+ options: IXkbOption[];
16
+ variants: IXkbVariant[];
17
+ private defaultKeyboardFile;
18
+ private xorgLstFile;
17
19
  constructor();
18
- /**
19
- * XKBLAYOUT='us'
20
- */
20
+ private parseXorgLst;
21
+ private setDefaults;
22
+ private readKeyboardConfig;
21
23
  getLayout(): Promise<string>;
22
- /**
23
- * XKBLAYOUT=[]
24
- */
25
24
  getLayouts(): IXkbLayout[];
26
- /**
27
- * XKBMODEL='pc105'
28
- */
29
25
  getModel(): Promise<string>;
30
- /**
31
- * XKBMODEL[]
32
- */
33
26
  getModels(): IXkbModel[];
34
- /**
35
- * XKBOPTIONS=''
36
- */
37
27
  getOption(): Promise<string>;
38
- /**
39
- * XKBOPTIONS[]
40
- */
41
28
  getOptions(): IXkbOption[];
42
- /**
43
- * XKBVARIANT=''
44
- */
45
29
  getVariant(): Promise<string>;
46
- /**
47
- * IXkbVariant[]
48
- */
49
30
  getVariants(layout: string): IXkbVariant[];
50
31
  }