Skip to content

Commit

Permalink
Debugging
Browse files Browse the repository at this point in the history
rhennigan committed Mar 31, 2022
1 parent 3ed3692 commit bd3e0b5
Showing 1 changed file with 17 additions and 5 deletions.
22 changes: 17 additions & 5 deletions src/install_dependencies.wls
Original file line number Diff line number Diff line change
@@ -17,13 +17,25 @@ $pacletsRoot = "https://www.wolframcloud.com/obj/rhennigan/Paclets";

pacletInstall[ n_String -> v_String ] := pacletInstall[ n <> "-" <> v ];

pacletInstall[ url_String? urlQ ] := Enclose[
Module[ { installed },
print[ "Installing paclet from: ", url ];
installed = PacletInstall[ url, ForceVersionInstall -> True ];
If[ PacletObjectQ @ installed,
print[ "Paclet installed to: ", installed[ "Location" ] ],
print[ "::error:: Paclet installation failed: ", installed ];
Exit[ 1 ]
]
],
Function[
print[ "::error:: Paclet installation failed: ", url ];
Exit[ 1 ]
]
];

pacletInstall[ spec_String ] := Enclose[
Module[ { url, zip, tmp, pacs, dir, downloaded, installed },
url = If[ urlQ @ spec,
url,
URLBuild @ { $pacletsRoot, spec <> ".paclet" }
];

url = URLBuild @ { $pacletsRoot, spec <> ".paclet" };
ConfirmAssert @ StringQ @ url;
print[ "Installing paclet from: ", url ];
If[ StringEndsQ[ url, ".zip" ],

0 comments on commit bd3e0b5

Please sign in to comment.