From d6e65f12b4668d5ebcd47c8d809868f4ca44a1c1 Mon Sep 17 00:00:00 2001 From: LordMZTE Date: Thu, 25 May 2023 14:44:04 +0200 Subject: [PATCH] Improve style of setup.rkt script Co-authored-by: Jimmy McNutt --- setup.rkt | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/setup.rkt b/setup.rkt index 898fda0..30c0400 100755 --- a/setup.rkt +++ b/setup.rkt @@ -27,20 +27,20 @@ (current-directory script-dir)) ;; Verify valid verb -(when (not (for/or ([valid-verb verbs]) - (symbol=? valid-verb verb))) - (error "Invalid verb" verb)) +(unless (for/or ([valid-verb verbs]) + (symbol=? valid-verb verb)) + (raise-user-error "Invalid verb" verb)) -(case verb - [(install-scripts) +(match verb + ['install-scripts (local-require "setup/commands/install-scripts.rkt") (run)] - [(install-lsps-paru) + ['install-lsps-paru (local-require "setup/commands/install-lsps-paru.rkt") (run)] - [(setup-nvim-config) + ['setup-nvim-config (local-require "setup/commands/setup-nvim-config.rkt") (run)] - [(confgen) + ['confgen (local-require "setup/commands/confgen.rkt") (run)])