Skip to content
This repository has been archived by the owner on Jan 25, 2019. It is now read-only.

Commit

Permalink
Download boot/base jars from Clojars (disabled)
Browse files Browse the repository at this point in the history
This change shouldn't have any effect until the respective
FEATURE FLAG is switched on.
  • Loading branch information
martinklepsch committed Jan 12, 2018
1 parent c5760f9 commit b5ea8a7
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/Boot.java
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,17 @@ public class Boot {

public static String
downloadUrl(String version, String name) throws Exception {
return String.format("https://github.com/boot-clj/boot/releases/download/%s/%s", version, name); }
// FEATURE FLAG - Enabling this will all cause all non-snapshot
// releases from 2.8 onwards to be downloaded from Clojars
Boolean clojarsDownloadEnabled = false;
if (clojarsDownloadEnabled &&
0 < version.compareTo("2.8") &&
!version.endsWith("SNAPSHOT") &&
name.equals("boot.jar")) {
String urlFormat = "https://repo.clojars.org/boot/base/%s/base-%s-uber.jar";
return String.format(urlFormat, version, version);
} else { // 2.7.2 and lower download releases from github
return String.format("https://github.com/boot-clj/boot/releases/download/%s/%s", version, name); }}

public static File
validateBinaryFile(File f) throws Exception {
Expand Down

0 comments on commit b5ea8a7

Please sign in to comment.