feat(cli): More argument handling

This commit is contained in:
2026-05-15 16:58:00 +02:00
parent 78eecfc81a
commit afe8d29340
3 changed files with 14 additions and 3 deletions
+1
View File
@@ -8,5 +8,6 @@ def add_parser(sp: ap._SubParsersAction[ap.ArgumentParser]):
dest="show", dest="show",
required=True, required=True,
) )
show_sp.add_parser("config", help="show details about your configuration. Alias of config show")
pkgs = show_sp.add_parser("pkgs", help="show details on package presets") pkgs = show_sp.add_parser("pkgs", help="show details on package presets")
pkgs.add_argument("show_pkg") pkgs.add_argument("show_pkg")
+3
View File
@@ -8,3 +8,6 @@ def config(args: argparse.Namespace, config: ArchMgrConfig):
Your config can be found at Your config can be found at
""") """)
print(config) print(config)
elif args.conf_update == "pkgs":
print("Updating config's package list")
# TODO: Config saver
+10 -3
View File
@@ -8,15 +8,22 @@
- Retrieve explicitly installed packages and remove those that are not present in goal and install those that are not present in current state - Retrieve explicitly installed packages and remove those that are not present in goal and install those that are not present in current state
# Concept for updating config automatically
1. Track which files contain the setting
2. If there are multiple and is no array, then simply overwrite the last
3. If there are multiple and is array, then remove from the file where it is present and add to last file in requires list
-> To enable this, update the loader to keep more metadata (list of all requires, list of files for each setting)
# Ideas # Ideas
- [ ] function to collect new configs - [X] function to collect new configs -> Not smart because templates
- [ ] config options for users and groups - [X] config options for users and groups
- [ ] presets for things like desktops (like Hyprland) - [ ] presets for things like desktops (like Hyprland)
- [ ] config options for the template rendering - [ ] config options for the template rendering
- [ ] config options for themes - [ ] config options for themes
- [ ] grub config - [ ] grub config
- [ ] Dynamic selection of more configs (i.e. require syntax) - [ ] Dynamic selection of more configs (i.e. require syntax)
- [ ] Own config syntax? - [X] Own config syntax? -> just use yaml
- [ ] Autocompletion - [ ] Autocompletion
- [ ] Basic arch install how? -> Probably manual (or semi-automatic) - [ ] Basic arch install how? -> Probably manual (or semi-automatic)
- [ ] Mounts? - [ ] Mounts?