mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 21:38:07 -05:00
guix: import: Don't include indirect dependencies in go.
* guix/import/go.scm (parse-go.mod)[define-peg-patern require]: Adjust the peg pattern to reject lines with the 'indirect' comment in them. Change-Id: I9618bbaa1cb8c6549ced875e3c8d32afc72c3b9b
This commit is contained in:
parent
ed9d47c6ae
commit
e35dd13d8a
1 changed files with 5 additions and 1 deletions
|
@ -7,6 +7,7 @@
|
|||
;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz>
|
||||
;;; Copyright © 2021 Sarah Morgensen <iskarian@mgsn.dev>
|
||||
;;; Copyright © 2021 Simon Tournier <zimon.toutoune@gmail.com>
|
||||
;;; Copyright © 2023 Efraim Flashner <efraim@flashner.co.il>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
|
@ -293,7 +294,10 @@ (define-peg-pattern module all
|
|||
|
||||
;; The following directives may all be used solo or in a block
|
||||
;; RequireSpec = ModulePath Version newline .
|
||||
(define-peg-pattern require all (and module-path version EOL))
|
||||
(define-peg-pattern require all
|
||||
(and module-path version
|
||||
;; We don't want the transitive dependencies.
|
||||
(not-followed-by (and (* WS) "//" (* WS) "indirect")) EOL))
|
||||
(define-peg-pattern require-top body
|
||||
(and (ignore "require")
|
||||
(or (and block-start (* (or require block-line)) block-end) require)))
|
||||
|
|
Loading…
Reference in a new issue