Hello! Ricardo Wurmus skribis: > Okay. Here’s something simpler using “partition”: > > commit 96fb123832b262a3453fe1b7646758da235a343e > Author: Ricardo Wurmus > Date: Tue Jan 3 10:14:52 2023 +0100 > > WIP > > diff --git a/guix/scripts/refresh.scm b/guix/scripts/refresh.scm > index e0b94ce48d..bbda2df35a 100644 > --- a/guix/scripts/refresh.scm > +++ b/guix/scripts/refresh.scm > @@ -183,9 +183,9 @@ (define (show-help) > (newline) > (show-bug-report-information)) > > -(define (options->update-specs opts) > - "Return the list of packages requested by OPTS, honoring options like > -'--recursive'." > +(define (options->packages+update-specs opts) > + "Return the list of packages and update-specs requested by OPTS, honoring > +options like '--recursive'." > (define core-package? > (let* ((input->package (match-lambda > ((name (? package? package) _ ...) package) > @@ -220,7 +220,7 @@ (define (keep-newest package lst) > (_ > (cons package lst))))) > > - (define args-packages > + (define args-packages+update-specs > ;; Packages explicitly passed as command-line arguments. > (match (filter-map (match-lambda > (('argument . spec) > @@ -244,17 +244,18 @@ (define args-packages > (some ;user-specified packages > some))) > > - (define packages > + (define packages+update-specs > (match (assoc-ref opts 'manifest) > - (#f args-packages) > + (#f args-packages+update-specs) > ((? string? file) (packages-from-manifest file)))) I tried something different and perhaps simpler: making sure ‘options->update-specs’ always returns a list of , as the name implies, and does the right thing with manifests, -r, and -e. (Part of the patch moves the definition before its first use.) WDYT? This is on top of , which also clarified a couple of things. After that I’d like to thing about tests for the CLI. Thanks, Ludo’.