|
9 | 9 |
|
10 | 10 | ∇ r←Version;fully |
11 | 11 | :Access Public Shared |
12 | | - r←'0.31.1+410' |
| 12 | + r←'0.32.0+410' |
| 13 | + ⍝ * 0.32.0 ⋄ 2023-08-25 |
| 14 | + ⍝ * `APLGit2` is now part of `Cider` and therefore always available |
| 15 | + ⍝ * Bug fixes |
| 16 | + ⍝ * The function `GetCiderGlobalConfigHomeFolder` crashed when Cider was not properly installed |
| 17 | + ⍝ * Loading Tatin packages did not act appropriately when there were packages installed but they |
| 18 | + ⍝ did not fit to the dependency list and/or the build list |
| 19 | + ⍝ * Inconsistencies between the build list and the dependency file were not discovered. Now Cider |
| 20 | + ⍝ does a re-install if the user permits that. |
| 21 | + ⍝ * It was possible to load a package and then open it as a project; this is now prevented |
13 | 22 | ⍝ * 0.31.1 ⋄ 2023-08-05 |
14 | | - ⍝ * The function `GetCiderGlobalConfigHomeFolder` crashed when Cider was not properly installed |
15 | | - ⍝ * The absence of APLGit2 is now reported by OpenProject in case the project is managed by Git |
16 | 23 | ⍝ * Version 0.30.0 wrongly pretended to be a beta release when it wasn't |
17 | 24 | ⍝ * 0.31.0 ⋄ 2023-08-04 |
18 | 25 | ⍝ * Step added to `OpenProject`: checks for a non-empty variable `ToDo` in the root of the project now |
|
175 | 182 | :EndTrap |
176 | 183 | :EndIf |
177 | 184 | :Trap 0 |
178 | | - {}LoadTatinPackages config parms.folder(⍕projectSpace_) |
| 185 | + :If 0=parms.quietFlag LoadTatinPackages config parms.folder(⍕projectSpace_) |
| 186 | + 1 p↓Frame'Package folder ',parms.folder,' needs attention!' |
| 187 | + :EndIf |
179 | 188 | :Else |
180 | 189 | qdmx←⎕DMX |
181 | 190 | buff←'' |
|
233 | 242 | ⍝ This function looks for "tatinFolder", and if it is found suggests an automated conversion. |
234 | 243 | ⍝ It expects to find either a single comma or no comma at all in "tatinFolder", otherwise it throws an error. |
235 | 244 | ⍝ II. |
236 | | - ⍝ The property `githubUsername` is deleted from the config file because is not used anymore |
| 245 | + ⍝ The property `githubUsername` is deleted from the config file because it is not used anymore |
237 | 246 | ⍝ III. |
238 | 247 | ⍝ With version 0.26.0 the property `distributionFolder` was introduced. |
239 | 248 | ⍝ If not found it is injected as an empty character vector. |
|
547 | 556 | p' All fine' |
548 | 557 | ∇ |
549 | 558 |
|
550 | | - ∇ {r}←CheckForGit(path config);status;dmx;success |
| 559 | + ∇ {r}←CheckForGit(path config);status;dmx |
551 | 560 | ⍝ Checks whether the project is managed by Git, and if so offers some help |
552 | 561 | r←⍬ |
553 | | - success←0 |
554 | 562 | :If ##.FilesAndDirs.Exists(AddSlash path),'.git' |
555 | | - :If 9=⎕SE.⎕NC'APLGit2' |
556 | | - :Trap 0 |
557 | | - status←⎕SE.APLGit2.Status path |
558 | | - success←1 |
559 | | - :Else |
560 | | - dmx←⎕DMX |
561 | | - :If 127=dmx.EN |
562 | | - p'The project appears to be managed by Git but Git is not installed?!' |
563 | | - :ElseIf 128=dmx.EN |
564 | | - p'The project appears to be managed by Git but user.email and/or user.name are not defined' |
565 | | - :ElseIf 0<≢dmx.Message |
566 | | - ⎕←'The Git status of the project could not be determined due to an error:' |
567 | | - ⎕←dmx.Message,'; rc=',⍕dmx.EN |
568 | | - :Else |
569 | | - ⎕←'The Git status of the project could not be determined due to an error' |
570 | | - :EndIf |
571 | | - :EndTrap |
572 | | - :If success |
573 | | - :If ∧/∨/¨'nothing to commit' 'working tree clean'⍷¨⊂∊status |
574 | | - :AndIf ~∨/∨/¨'on branch main' 'on branch master'⍷¨⊂⎕C∊status |
575 | | - ⎕←'Git: ',(1⊃status),', ',⊃{⍺,', ',⍵}/1↓status |
576 | | - :Else |
577 | | - status←(↓(,[0.5]'Git status report')⍪'='),status |
578 | | - {{}(#.⎕NS'').(⎕ED⍠('ReadOnly' 1)&{'GIT_Status_Report'}GIT_Status_Report←⍵)}⍪status |
579 | | - :EndIf |
| 563 | + :Trap 0 |
| 564 | + status←##.APLGit2.Status path |
| 565 | + :Else |
| 566 | + dmx←⎕DMX |
| 567 | + :If 127=dmx.EN |
| 568 | + p'The project appears to be managed by Git but Git is not installed?!' |
| 569 | + :Return |
| 570 | + :ElseIf 128=dmx.EN |
| 571 | + p'The project appears to be managed by Git but user.email and/or user.name are not defined' |
| 572 | + :Return |
| 573 | + :ElseIf 0<≢dmx.Message |
| 574 | + ⎕←'The Git status of the project could not be determined due to an error:' |
| 575 | + ⎕←dmx.Message,'; rc=',⍕dmx.EN |
| 576 | + :Return |
580 | 577 | :Else |
581 | | - p'The project appears to be managed by Git but the user command ]APLGit2 and' |
582 | | - p'it''s API are missing, therefore no information can be provided regarding Git' |
| 578 | + ⎕←'The Git status of the project could not be determined due to an error' |
| 579 | + :Return |
583 | 580 | :EndIf |
| 581 | + :EndTrap |
| 582 | + :If ∧/∨/¨'nothing to commit' 'working tree clean'⍷¨⊂∊status |
| 583 | + :AndIf ~∨/∨/¨'on branch main' 'on branch master'⍷¨⊂⎕C∊status |
| 584 | + ⎕←'Git: ',(1⊃status),', ',⊃{⍺,', ',⍵}/1↓status |
584 | 585 | :Else |
585 | | - p'The project appears to be managed by Git, but the package "APLGit2" is not installed...' |
| 586 | + status←(↓(,[0.5]'Git status report')⍪'='),status |
| 587 | + {{}(#.⎕NS'').(⎕ED⍠('ReadOnly' 1)&{'GIT_Status_Report'}GIT_Status_Report←⍵)}⍪status |
586 | 588 | :EndIf |
587 | 589 | :EndIf |
588 | 590 | ∇ |
|
704 | 706 | :EndFor |
705 | 707 | ∇ |
706 | 708 |
|
707 | | - ∇ {r}←LoadTatinPackages(config folder projectSpace);pkgFolders;pkgFolder;folder2;target;pkgFolder_;noOf;p |
| 709 | + ∇ {r}←quiet LoadTatinPackages(config folder projectSpace);pkgFolders;pkgFolder;folder2;target;pkgFolder_;noOf;qdmx;q;parms;p |
708 | 710 | ⍝ Load all installed packages (if any) into their designated host namespaces. |
709 | | - r←FAILURE |
710 | | - p←{⍺←~parms.quietFlag ⋄ ⍺ PrintToSession ⍵} |
| 711 | + r←SUCCESS |
711 | 712 | pkgFolders←GetTatinDepedencyFolders config |
| 713 | + p←quiet∘{⍺ PrintToSession ⍵} |
712 | 714 | :If 0<≢pkgFolders |
713 | 715 | :For pkgFolder :In pkgFolders |
| 716 | + ∆Retry: |
714 | 717 | :If '='∊pkgFolder |
715 | 718 | (pkgFolder_ target)←SplitTatinFolders pkgFolder |
716 | 719 | 'Target namespace for Tatin packages is addressed with absolute path (invalid)'Assert~(⊃target)∊'#⎕' |
|
724 | 727 | :If ##.FilesAndDirs.Exists folder2 |
725 | 728 | :If 0<0<≢⊃0 ⎕NINFO⍠('Wildcard' 1)⊣folder2,'/*' |
726 | 729 | p ReportPackageOrigins folder2 |
727 | | - noOf←≢⎕SE.Tatin.LoadDependencies folder2 target |
728 | | - p(⍕noOf),' Tatin package',((1<noOf)/'s'),' loaded' |
| 730 | + :Trap 0 |
| 731 | + noOf←≢⎕SE.Tatin.LoadDependencies folder2 target |
| 732 | + p(⍕noOf),' Tatin package',((1<noOf)/'s'),' loaded' |
| 733 | + :Else |
| 734 | + qdmx←⎕DMX |
| 735 | + :If 998=qdmx.EN |
| 736 | + :If ∧/∨/¨'The build list in ' ' that are not installed:'⍷¨⊂qdmx.EM |
| 737 | + q←'ReinstallBecauseOfInconsistency@The installed packages don''t fit the dependency/build list file(s); re-install?' |
| 738 | + :If YesOrNo q |
| 739 | + parms←⎕SE.Tatin.CreateReInstallParms |
| 740 | + {}parms ⎕SE.Tatin.ReInstallDependencies folder2 |
| 741 | + →∆Retry |
| 742 | + :Else |
| 743 | + p'*** Packages in ',folder2,' need attention!' |
| 744 | + :EndIf |
| 745 | + :ElseIf ∨/'Invalid entry:'⍷qdmx.EM |
| 746 | + q←'ReinstallBecauseOfInvalidPkg@There are invalid entries in the dependency list; re-install?' |
| 747 | + :If YesOrNo q |
| 748 | + ⎕SE.Tatin.ReInstallDependencies folder2 |
| 749 | + →∆Retry |
| 750 | + :Else |
| 751 | + p'*** Packages in ',folder2,' need attention!' |
| 752 | + r←FAILURE |
| 753 | + :EndIf |
| 754 | + :Else |
| 755 | + p'*** ',qdmx.EM |
| 756 | + r←FAILURE |
| 757 | + :EndIf |
| 758 | + :EndIf |
| 759 | + :EndTrap |
729 | 760 | :Else |
730 | 761 | p'Tatin installation folder "',folder2,'" is empty, therefore no packages loaded' |
731 | 762 | :EndIf |
732 | 763 | :Else |
733 | 764 | p'Tatin installation folder "',folder2,'" does not exists, therefore no packages loaded' |
734 | 765 | :EndIf |
735 | | - r←SUCCESS |
736 | 766 | :EndFor |
737 | 767 | :EndIf |
738 | 768 | ∇ |
|
1403 | 1433 | ⍝ be empty, otherwise an error is thrown. |
1404 | 1434 | :If (⎕NC⊂⍕ref)∊9.1 9.4 9.5 |
1405 | 1435 | nsIsEmpty←0=≢' '~¨⍨↓ref.⎕NL⍳16 |
| 1436 | + 'Cannot open, is already loaded as a package'Assert'_tatin'≢{⍵↑⍨¯1+⍵⍳'.'}{⍵↓⍨⍵⍳'.'}⍕ref |
1406 | 1437 | :If 0=##.FilesAndDirs.Exists parms.folder,'/',source |
1407 | 1438 | folderIsEmpty←1 |
1408 | 1439 | :Else |
|
0 commit comments