mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 13:28:12 -05:00
system: Add helper file-system-mount-point-predicate.
* gnu/system/file-systems.scm (file-system-mount-point-predicate): Add it. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
parent
7f6dd3be3d
commit
0055a803e2
1 changed files with 7 additions and 0 deletions
|
@ -60,6 +60,7 @@ (define-module (gnu system file-systems)
|
||||||
file-system-location
|
file-system-location
|
||||||
|
|
||||||
file-system-type-predicate
|
file-system-type-predicate
|
||||||
|
file-system-mount-point-predicate
|
||||||
btrfs-subvolume?
|
btrfs-subvolume?
|
||||||
btrfs-store-subvolume-file-name
|
btrfs-store-subvolume-file-name
|
||||||
|
|
||||||
|
@ -671,6 +672,12 @@ (define (file-system-type-predicate type)
|
||||||
(lambda (fs)
|
(lambda (fs)
|
||||||
(string=? (file-system-type fs) type)))
|
(string=? (file-system-type fs) type)))
|
||||||
|
|
||||||
|
(define (file-system-mount-point-predicate mount-point)
|
||||||
|
"Return a predicate that, when passed a file system, returns #t if that file
|
||||||
|
system has the given MOUNT-POINT."
|
||||||
|
(lambda (fs)
|
||||||
|
(string=? (file-system-mount-point fs) mount-point)))
|
||||||
|
|
||||||
|
|
||||||
;;;
|
;;;
|
||||||
;;; Btrfs specific helpers.
|
;;; Btrfs specific helpers.
|
||||||
|
|
Loading…
Reference in a new issue