13.4
This commit is contained in:
parent
d27ef185e6
commit
9986f477b2
2
pom.xml
2
pom.xml
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>net.t2code</groupId>
|
<groupId>net.t2code</groupId>
|
||||||
<artifactId>T2CodeLib</artifactId>
|
<artifactId>T2CodeLib</artifactId>
|
||||||
<version>13.4_SNAPSHOT-2</version>
|
<version>13.4</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>T2CodeLib</name>
|
<name>T2CodeLib</name>
|
||||||
|
@ -208,7 +208,7 @@ public class T2CupdateAPI {
|
|||||||
|
|
||||||
public static void onUpdateCheck(Plugin plugin, String prefix, String gitKey, Integer spigotID, String discord, Boolean updateCheckOnJoin, Boolean seePreReleaseUpdates, Integer timeInterval) {
|
public static void onUpdateCheck(Plugin plugin, String prefix, String gitKey, Integer spigotID, String discord, Boolean updateCheckOnJoin, Boolean seePreReleaseUpdates, Integer timeInterval) {
|
||||||
String RepoURL = "https://git.t2code.net/api/v1/repos/" + gitKey + "/releases?limit=1";
|
String RepoURL = "https://git.t2code.net/api/v1/repos/" + gitKey + "/releases?limit=1";
|
||||||
if (!SelectLibConfig.getSeePreReleaseUpdates()) {
|
if (!seePreReleaseUpdates) {
|
||||||
RepoURL = RepoURL + "&pre-release=false";
|
RepoURL = RepoURL + "&pre-release=false";
|
||||||
}
|
}
|
||||||
if (!RepoURL.contains("?limit=1")) {
|
if (!RepoURL.contains("?limit=1")) {
|
||||||
|
@ -30,10 +30,13 @@ public class Commands {
|
|||||||
"after <red>14</red> days!<br>The file can also be deleted manually by you via command!</dark_red><br><dark_green><hover:show_text:'<yellow>Confirm the" +
|
"after <red>14</red> days!<br>The file can also be deleted manually by you via command!</dark_red><br><dark_green><hover:show_text:'<yellow>Confirm the" +
|
||||||
" upload</yellow>'><click:run_command:'/t2c debug createReportLog confirmupload'>upload</click></hover></dark_green> <dark_gray>|</dark_gray> " +
|
" upload</yellow>'><click:run_command:'/t2c debug createReportLog confirmupload'>upload</click></hover></dark_green> <dark_gray>|</dark_gray> " +
|
||||||
"<gold><hover:show_text:'<red>Do not upload</red>'><click:run_command:'/t2c debug createReportLog noupload'>keep the file on your server</click></hover></gold>");
|
"<gold><hover:show_text:'<red>Do not upload</red>'><click:run_command:'/t2c debug createReportLog noupload'>keep the file on your server</click></hover></gold>");
|
||||||
} else T2Csend.sender(sender, "<dark_red>The debug zip file is <red>automatically uploaded</red> to T2Code's servers<br>and <red>automatically deleted</red> " +
|
} else T2Csend.sender(sender, "<dark_red>The debug zip file is <red>automatically uploaded</red> to T2Code's servers</dark_red>" +
|
||||||
"after <red>14</red> days!<br>The file can also be deleted manually by you via command!</dark_red><br><green>Confirm the upload with the command:" +
|
"<br><dark_red>and <red>automatically deleted</red> after <red>14</red> days!</dark_red>" +
|
||||||
"</green><br><yellow>/t2c debug createReportLog confirmupload</yellow><br><red>Keep the file on your server and do not upload it with the command:" +
|
"<br><dark_red>The file can also be deleted manually by you via command!</dark_red>" +
|
||||||
"</red><br><yellow>/t2c debug createReportLog noupload</yellow>");
|
"<br><green>Confirm the upload with the command:</green>" +
|
||||||
|
"<br><yellow>/t2c debug createReportLog confirmupload</yellow>" +
|
||||||
|
"<br><red>Keep the file on your server and do not upload it with the command:</red>" +
|
||||||
|
"<br><yellow>/t2c debug createReportLog noupload</yellow>");
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
Boolean upload = args[2].equalsIgnoreCase("confirmupload");
|
Boolean upload = args[2].equalsIgnoreCase("confirmupload");
|
||||||
|
@ -155,7 +155,6 @@ public class CreateReportLog {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
HttpClient httpclient = new DefaultHttpClient();
|
HttpClient httpclient = new DefaultHttpClient();
|
||||||
HttpPost httppost = new HttpPost("https://debug.t2code.net/uploadFile");
|
HttpPost httppost = new HttpPost("https://debug.t2code.net/uploadFile");
|
||||||
|
|
||||||
@ -175,15 +174,18 @@ public class CreateReportLog {
|
|||||||
directoryTemp.delete();
|
directoryTemp.delete();
|
||||||
if (sender instanceof Player) {
|
if (sender instanceof Player) {
|
||||||
T2Csend.sender(sender, ("[prefix] <green>A DebugLog zip has been created." +
|
T2Csend.sender(sender, ("[prefix] <green>A DebugLog zip has been created." +
|
||||||
"<br>[prefix] You can download it <click:open_url:'[url]'><gold><hover:show_text:'<yellow>Download the debug file</yellow>'>here</hover></gold></click>." +
|
"<br>[prefix] <green>You can download it <click:open_url:'[url]'><gold><hover:show_text:'<yellow>Download the debug file</yellow>'>here</hover></gold></click>." +
|
||||||
"<br>[prefix] Please enter the following key in the ticket: <gold><click:copy_to_clipboard:[key]><hover:show_text:'<yellow>Copy to clipboard</yellow>'>[key]</hover></click></gold></green>" +
|
"<br>[prefix] <green>Please enter the following key in the ticket: <gold><click:copy_to_clipboard:[key]><hover:show_text:'<yellow>Copy to clipboard</yellow>'>[key]</hover></click></gold></green>" +
|
||||||
"<br>[prefix] <dark_red>Do not share the download URL with anyone!</dark_red>" +
|
"<br>[prefix] <dark_red>Do not share the download URL with anyone!</dark_red>" +
|
||||||
"<br>[prefix] <click:run_command:'/t2code debug deleteReportLog [key]'><hover:show_text:'<yellow>Click to delete</yellow>'><green>You can <b>delte</b> yor Debug-File by clicking me.</green></click>" +
|
"<br><hover:show_text:'<yellow>Click to delete</yellow>'><click:run_command:'/t2code debug deleteReportLog [key]'>[prefix] <green>You can <b>delte</b> yor Debug-File by clicking me.</green>" +
|
||||||
"<br>[prefix] <color:#910d06>(If you do not delete the debug file, it will be deleted automatically after <red>14</red> days!)</color></hover>").replace("[key]", fileID)
|
"<br>[prefix] <color:#910d06>(If you do not delete the debug file, it will be deleted automatically after <red>14</red> days!)</color></click></hover>")
|
||||||
.replace("[url]", downloadURL).replace("[prefix]",Util.getPrefix()));
|
.replace("[key]", fileID).replace("[url]", downloadURL).replace("[prefix]",Util.getPrefix()));
|
||||||
}
|
}
|
||||||
T2Csend.console(Util.getPrefix() + (" §6A DebugLog zip has been created. You can download it here: [url].\n§6Please enter the following key in the ticket:" +
|
T2Csend.console(Util.getPrefix() + (" <gold>A DebugLog zip has been created. You can download it here:</gold> <yellow>[url]</yellow>" +
|
||||||
" §e[key].\n§4Do not share the download URL with anyone!\nYou can delte yor Debug-File with the following command: /t2code debug deleteReportLog [key].")
|
"<br><gold>Please enter the following key in the ticket:</gold> <yellow>[key]</yellow>." +
|
||||||
|
"<br><dark_red>Do not share the download URL with anyone!</dark_red>" +
|
||||||
|
"<br><color:#910d06>(If you do not delete the debug file, it will be deleted automatically after <red>14</red> days!)</color>" +
|
||||||
|
"<br><dark_red>You can delte yor Debug-File with the following command:</dark_red> <red>/t2code debug deleteReportLog [key]</red>.")
|
||||||
.replace("[key]", fileID).replace("[url]", downloadURL));
|
.replace("[key]", fileID).replace("[url]", downloadURL));
|
||||||
ReportLogStorage.add(fileID);
|
ReportLogStorage.add(fileID);
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@ public class Util {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static String getPrefix() {
|
public static String getPrefix() {
|
||||||
return "§8[§4T2Code§5Lib§8]";
|
return "<dark_gray>[<dark_red>T2Code</dark_red><dark_purple>Lib</dark_purple>]</dark_gray>";
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Integer getSpigotID() {
|
public static Integer getSpigotID() {
|
||||||
|
Loading…
Reference in New Issue
Block a user