mirror of
				https://codeberg.org/hako/Rosenthal.git
				synced 2025-11-04 11:44:48 +00:00 
			
		
		
		
	services: Add greetd-tuigreet-session.
* modules/rosenthal/services/base.scm: New file.
This commit is contained in:
		
							parent
							
								
									4ce201dc6d
								
							
						
					
					
						commit
						afe32807aa
					
				
							
								
								
									
										29
									
								
								modules/rosenthal/services/base.scm
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								modules/rosenthal/services/base.scm
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,29 @@
 | 
			
		||||
;;; SPDX-FileCopyrightText: 2025 Hilton Chain <hako@ultrarare.space>
 | 
			
		||||
;;;
 | 
			
		||||
;;; SPDX-License-Identifier: GPL-3.0-or-later
 | 
			
		||||
 | 
			
		||||
(define-module (rosenthal services base)
 | 
			
		||||
  #:use-module (guix gexp)
 | 
			
		||||
  #:use-module (guix records)
 | 
			
		||||
  #:use-module (rosenthal utils packages)
 | 
			
		||||
  #:use-module (gnu services base)
 | 
			
		||||
  #:use-module (gnu packages bash)
 | 
			
		||||
  #:export (greetd-tuigreet-session))
 | 
			
		||||
 | 
			
		||||
(define-record-type* <greetd-tuigreet-session>
 | 
			
		||||
  greetd-tuigreet-session make-greetd-tuigreet-session
 | 
			
		||||
  greetd-tuigreet-session?
 | 
			
		||||
  this-greetd-tuigreet-session
 | 
			
		||||
  (tuigreet greetd-tuigreet-session-tuigreet
 | 
			
		||||
            (default (spec->pkg "tuigreet"))))
 | 
			
		||||
 | 
			
		||||
(define-gexp-compiler (greetd-tuigreet-session-compiler
 | 
			
		||||
                       (session <greetd-tuigreet-session>)
 | 
			
		||||
                       system target)
 | 
			
		||||
  (match-record session <greetd-tuigreet-session> (tuigreet)
 | 
			
		||||
    (lower-object
 | 
			
		||||
     (program-file "tuigreet-wrapper"
 | 
			
		||||
       #~(execl #$tuigreet #$tuigreet
 | 
			
		||||
                "--issue" "--time" "--user-menu" "--asterisks"
 | 
			
		||||
                "--power-shutdown" "loginctl power-off"
 | 
			
		||||
                "--power-reboot" "loginctl reboot")))))
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user