Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDylan M. Taylor <dylan@dylanmtaylor.com>2021-04-09 15:28:35 -0400
committerDylan Taylor <dylan@dylanmtaylor.com>2021-04-09 15:32:01 -0400
commit40df2d6e805edd643d8ed28698128247b3bdb44e (patch)
treec48844c6c41828b8b6b88aff679a65b1555bb4c6
parentf57b533275251b8f249a1a396261489e4f0266d8 (diff)
Further i3 simplification and cleanup
-rw-r--r--profiles/i3-gaps.py17
-rw-r--r--profiles/i3-wm.py17
-rw-r--r--profiles/i3.py17
3 files changed, 4 insertions, 47 deletions
diff --git a/profiles/i3-gaps.py b/profiles/i3-gaps.py
deleted file mode 100644
index ddca34b7..00000000
--- a/profiles/i3-gaps.py
+++ /dev/null
@@ -1,17 +0,0 @@
-import archinstall, subprocess
-
-is_top_level_profile = False
-
-def _prep_function(*args, **kwargs):
- """
- Magic function called by the importing installer
- before continuing any further. It also avoids executing any
- other code in this stage. So it's a safe way to ask the user
- for more input before any other installer steps start.
- """
- return True
-
-if __name__ == 'i3-gaps':
- # install the i3 group now
- i3 = archinstall.Application(installation, 'i3-gaps')
- i3.install()
diff --git a/profiles/i3-wm.py b/profiles/i3-wm.py
deleted file mode 100644
index 4a0415fc..00000000
--- a/profiles/i3-wm.py
+++ /dev/null
@@ -1,17 +0,0 @@
-import archinstall, subprocess
-
-is_top_level_profile = False
-
-def _prep_function(*args, **kwargs):
- """
- Magic function called by the importing installer
- before continuing any further. It also avoids executing any
- other code in this stage. So it's a safe way to ask the user
- for more input before any other installer steps start.
- """
- return True
-
-if __name__ == 'i3-wm':
- # install the i3 group now
- i3 = archinstall.Application(installation, 'i3-wm')
- i3.install()
diff --git a/profiles/i3.py b/profiles/i3.py
index 9f58e7eb..9ab5f88d 100644
--- a/profiles/i3.py
+++ b/profiles/i3.py
@@ -22,7 +22,7 @@ def _prep_function(*args, **kwargs):
# Temporarily store the selected desktop profile
# in a session-safe location, since this module will get reloaded
# the next time it gets executed.
- archinstall.storage['_desktop_profile'] = desktop
+ archinstall.storage['_i3_configuration'] = desktop
# i3 requires a functioning Xorg installation.
profile = archinstall.Profile(None, 'xorg')
@@ -32,14 +32,6 @@ def _prep_function(*args, **kwargs):
else:
print('Deprecated (??): xorg profile has no _prep_function() anymore')
- profile = archinstall.Profile(None, desktop)
- # Loading the instructions with a custom namespace, ensures that a __name__ comparison is never triggered.
- with profile.load_instructions(namespace=f"{desktop}.py") as imported:
- if hasattr(imported, '_prep_function'):
- return imported._prep_function()
- else:
- print(f"Deprecated (??): {desktop} profile has no _prep_function() anymore")
-
if __name__ == 'i3':
"""
This "profile" is a meta-profile.
@@ -66,7 +58,6 @@ if __name__ == 'i3':
# Auto start lightdm for all users
installation.enable_service('lightdm')
- # TODO: Remove magic variable 'installation' and place it
- # in archinstall.storage or archinstall.session/archinstall.installation
- installation.install_profile(archinstall.storage['_desktop_profile'])
-
+ # install the i3 group now
+ i3 = archinstall.Application(installation, archinstall.storage['_i3_configuration'])
+ i3.install()