aboutsummaryrefslogtreecommitdiff
path: root/emacs/guix-profiles.el
diff options
context:
space:
mode:
Diffstat (limited to 'emacs/guix-profiles.el')
-rw-r--r--emacs/guix-profiles.el8
1 files changed, 8 insertions, 0 deletions
diff --git a/emacs/guix-profiles.el b/emacs/guix-profiles.el
index 43ad1d42eb..12cf46dbf8 100644
--- a/emacs/guix-profiles.el
+++ b/emacs/guix-profiles.el
@@ -40,6 +40,14 @@
(defvar guix-current-profile guix-default-profile
"Current profile.")
+(defvar guix-system-profile-regexp
+ (concat "\\`" (regexp-quote guix-system-profile))
+ "Regexp matching system profiles.")
+
+(defun guix-system-profile? (profile)
+ "Return non-nil, if PROFILE is a system one."
+ (string-match-p guix-system-profile-regexp profile))
+
(defun guix-profile-prompt (&optional default)
"Prompt for profile and return it.
Use DEFAULT as a start directory. If it is nil, use