guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#36555] [PATCH 0/2] Refactor out common behavior for system reconfig


From: Jakob L. Kreuze
Subject: [bug#36555] [PATCH 0/2] Refactor out common behavior for system reconfiguration.
Date: Mon, 08 Jul 2019 15:52:12 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux)

Hello, Guix!

This is the preliminary version of a patch series to turn the behavior
common between 'guix deploy' and 'guix system reconfigure' into a module
that both can use. I am submitting it as-is both for comments and for
tracking the refactoring effort.

Note that this is _not_ ready to be merged. There are several things
that I need to do before I would consider it ready for upstream Guix:

- This passes my old test suite for 'guix deploy', but I haven't dared
  to run the new 'guix system reconfigure'. I'll set up a new virtual
  machine so I don't put myself out of a working laptop.
- 'switch-system-program', 'upgrade-services-program', and
  'install-bootloader-program' omit some of the features that were
  present in the procedures they replace. For example,
  'install-bootloader' previously supported installing the bootloader
  configuration without actually running the installation script. This
  was fine for 'guix deploy', but I'll need to add it back in for
  'guix system reconfigure'.
- I plan to implement system tests for '(guix scripts system
  reconfigure)'. I suppose I can always submit them as a separate patch,
  but I'll likely finish them before we're through with code review, so
  it may make sense to include them with as part of this patch series,
  albeit as a distinct commit.
- I suspect that some of the effectful procedures in 'system.scm' could
  be refactored out in a similar fashion. Not that 'guix deploy' would
  necessarily be using them, but it would be more consistent to have
  them as 'program-file' objects, and those procedures could then also
  be tested.

I look forward to your comments.

Regards,
Jakob


Jakob L. Kreuze (2):
  guix system: Add 'reconfigure' module.
  guix system: Reimplement 'reconfigure'.

 Makefile.am                         |   1 +
 gnu/machine/ssh.scm                 | 235 ++++++++--------------------
 guix/scripts/system.scm             | 140 +++++------------
 guix/scripts/system/reconfigure.scm | 158 +++++++++++++++++++
 4 files changed, 255 insertions(+), 279 deletions(-)
 create mode 100644 guix/scripts/system/reconfigure.scm

--
2.22.0

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]