help-guix
[Top][All Lists]
Advanced

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

Re: Meaning of symbol prefixed with "#$"


From: Ricardo Wurmus
Subject: Re: Meaning of symbol prefixed with "#$"
Date: Fri, 26 May 2023 21:14:27 +0200
User-agent: mu4e 1.10.2; emacs 28.2

(Moving this to help-guix instead of guile-user.)

"N. Y." <ningyuan.sg@gmail.com> writes:

> (arguments
>   '(#:phases (modify-phases %standard-phases
>     (add-after 'unpack 'amend-version
>       (lambda _
>         (substitute* "setup.py"
>           (("versioneer.get_version\\(\\)")
>           (string-append "\"" #$version "\"")))))

You can only use #$ inside an expression starting with #~.  This should
work:

--8<---------------cut here---------------start------------->8---
(arguments
  (list
    #:phases
    #~(modify-phases %standard-phases
       (add-after 'unpack 'amend-version
         (lambda _
           (substitute* "setup.py"
             (("versioneer.get_version\\(\\)")
             (string-append "\"" #$version "\""))))))))
--8<---------------cut here---------------end--------------->8---

-- 
Ricardo



reply via email to

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