From 8571a14d9ace62ffdeeb6881bf537896e1c5319a Mon Sep 17 00:00:00 2001 From: Kai Jaeger Date: Mon, 25 Sep 2023 16:30:32 +0200 Subject: [PATCH] VALUE ERROR fixed in AddAlias --- APLSource/Cider/AddAlias.aplf | 7 +++---- APLSource/Cider/PrintToSession.aplf | 5 ++--- APLSource/Cider/Version.aplf | 2 +- apl-package.json | 2 +- 4 files changed, 7 insertions(+), 9 deletions(-) diff --git a/APLSource/Cider/AddAlias.aplf b/APLSource/Cider/AddAlias.aplf index af44830d..bb8b8223 100644 --- a/APLSource/Cider/AddAlias.aplf +++ b/APLSource/Cider/AddAlias.aplf @@ -13,9 +13,8 @@ :AndIf 0<≢ciderAliasFilename :If F.Exists ciderAliasFilename data←⊃F.NGET ciderAliasFilename 1 - :If ~F.Exists folder - (1 parms.batch)p'Could not find "',folder,'"' - :ElseIf 0=+/(alias,'=')∘{⍺≡(≢⍺)↑⍵}¨data + ('Could not find "',folder,'"')Assert F.Exists folder + :If 0=+/(alias,'=')∘{⍺≡(≢⍺)↑⍵}¨data ind←({⍵↓⍨⍵⍳'='}¨data)⍳⊂folder :If ind≤≢data DropAlias{⍵↑⍨¯1+⍵⍳'='}ind⊃data @@ -41,7 +40,7 @@ data←⊃¨{⍺,'=',⍵}/¨↓data (⊂data)F.NPUT ciderAliasFilename 1 :Else - (1 parms.batch)p'Alias "',alias,'" is already in use with a different path - alias not assigned' + 1 PrintToSession 'Alias "',alias,'" is associated with another folder - alias not assigned' :EndIf :EndIf :EndIf diff --git a/APLSource/Cider/PrintToSession.aplf b/APLSource/Cider/PrintToSession.aplf index 94b5812a..9f829d95 100644 --- a/APLSource/Cider/PrintToSession.aplf +++ b/APLSource/Cider/PrintToSession.aplf @@ -1,12 +1,11 @@ {r}←flags PrintToSession msg;quiet;sessionFlag ⍝ If `msg` is not empty: -⍝ * Prints `msg` to rte session in case `flag` is 1 +⍝ * Prints `msg` to the session in case `flag` is 1 ⍝ * Adds `msg` to `∆LOG` if that variable already exists ⍝ `msg` might be a simple character vector or a vector of character vectors.\\ ⍝ `flags` must be a scalar Boolean or a vector of two Booleans, defaulting to 0 0: ⍝ * `flags[1]` must be 1 in order to print `msg` to the session -⍝ * `flags[2]` must be 1 in order add -⍝ only added to `∆LOG`. +⍝ * `flags[2]` must be 1 in order to suppress output and only add `msg` to `∆LOG` r←0 0⍴⍬ Assert∧/flags∊0 1 (sessionFlag quiet)←2↑flags,0 diff --git a/APLSource/Cider/Version.aplf b/APLSource/Cider/Version.aplf index f48ec42a..584b582d 100644 --- a/APLSource/Cider/Version.aplf +++ b/APLSource/Cider/Version.aplf @@ -1,3 +1,3 @@ r←Version ⍝ See als History - r←'0.36.0+578' + r←'0.36.0+579' diff --git a/apl-package.json b/apl-package.json index 6e3a2d32..79e74e17 100644 --- a/apl-package.json +++ b/apl-package.json @@ -19,5 +19,5 @@ source: "APLSource/Cider/", tags: "project-management", userCommandScript: "APLSource/Cider_UC.dyalog", - version: "0.36.0+578", + version: "0.36.0+579", }