Skip to content

Commit

Permalink
Version 4.1.1
Browse files Browse the repository at this point in the history
-> Version number is now a String to support patch
-> Version number needs only to be change once in the pom files and once in Constants

-> GithubVersionCheck now refers to my repository
-> AboutDialog shows the repository instead of the user
  • Loading branch information
extremeCrazyCoder committed Aug 4, 2021
1 parent b45f101 commit 1a2b4cd
Show file tree
Hide file tree
Showing 9 changed files with 21 additions and 24 deletions.
2 changes: 1 addition & 1 deletion Core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>de.tor.dswb</groupId>
<artifactId>dsworkbench</artifactId>
<version>4.1</version>
<version>${revision}</version>
</parent>

<modelVersion>4.0.0</modelVersion>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
<Property name="foreground" type="java.awt.Color" editor="org.netbeans.beaninfo.editors.ColorEditor">
<Color blue="ff" green="33" red="0" type="rgb"/>
</Property>
<Property name="text" type="java.lang.String" value="https://github.com/extremeCrazyCoder"/>
<Property name="text" type="java.lang.String" value="https://github.com/extremeCrazyCoder/dsworkbench"/>
<Property name="toolTipText" type="java.lang.String" value=""/>
</Properties>
<Events>
Expand Down
26 changes: 11 additions & 15 deletions Core/src/main/java/de/tor/tribes/ui/windows/AboutDialog.java
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ private void initComponents() {
getContentPane().add(jLabelWeb, gridBagConstraints);

jLabelWebLink.setForeground(new java.awt.Color(0, 51, 255));
jLabelWebLink.setText("https://github.com/extremeCrazyCoder");
jLabelWebLink.setText("https://github.com/extremeCrazyCoder/dsworkbench");
jLabelWebLink.setToolTipText("");
jLabelWebLink.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
Expand Down Expand Up @@ -216,20 +216,16 @@ private void buildSystemInfo() {
* @param args the command line arguments
*/
public static void main(String args[]) {
java.awt.EventQueue.invokeLater(new Runnable() {

@Override
public void run() {
AboutDialog dialog = new AboutDialog(new javax.swing.JFrame(), true);
dialog.addWindowListener(new java.awt.event.WindowAdapter() {

@Override
public void windowClosing(java.awt.event.WindowEvent e) {
System.exit(0);
}
});
dialog.setVisible(true);
}
java.awt.EventQueue.invokeLater(() -> {
AboutDialog dialog = new AboutDialog(new javax.swing.JFrame(), true);
dialog.addWindowListener(new java.awt.event.WindowAdapter() {

@Override
public void windowClosing(java.awt.event.WindowEvent e) {
System.exit(0);
}
});
dialog.setVisible(true);
});
}
// Variables declaration - do not modify//GEN-BEGIN:variables
Expand Down
2 changes: 1 addition & 1 deletion Core/src/main/java/de/tor/tribes/util/Constants.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
* @author Torridity
*/
public class Constants {
public final static double VERSION = 4.1;
public final static String VERSION = "4.1.1";
public final static String VERSION_ADDITION = "";
public final static Color DS_BACK = new Color(225, 213, 190);
public final static Color DS_BACK_LIGHT = new Color(239, 235, 223);
Expand Down
4 changes: 2 additions & 2 deletions Core/src/main/java/de/tor/tribes/util/GithubVersionCheck.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
public final class GithubVersionCheck {
private static final Logger LOGGER = LogManager.getLogger("GithubVersionCheck");

private static final String API_URL = "https://api.github.com/repos/torridity/dsworkbench/releases/latest";
private static final String API_URL = "https://api.github.com/repos/extremeCrazyCoder/dsworkbench/releases/latest";

public static class UpdateInfo {

Expand Down Expand Up @@ -105,7 +105,7 @@ public static UpdateInfo getUpdateInformation() {
JSONObject latestRelease = new JSONObject(new String(result.toByteArray()));
String latestTagName = (String) latestRelease.get("tag_name");

String ownVersion = Double.toString(Constants.VERSION) + Constants.VERSION_ADDITION;
String ownVersion = Constants.VERSION + Constants.VERSION_ADDITION;
if (ownVersion.equals(latestTagName)) {
//no update available
return UpdateInfo.factoryNoUpdateAvailableInfo();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ private static String replaceHeadFootVariables(String pBlock, String pPlanName,
result = result.replace(SERVER, "-");
}
//replace version
result = result.replace(VERSION, Double.toString(Constants.VERSION) + Constants.VERSION_ADDITION);
result = result.replace(VERSION, Constants.VERSION + Constants.VERSION_ADDITION);
//replace creation date
SimpleDateFormat f = TimeManager.getSimpleDateFormat("dd.MM.yyyy 'um' HH:mm:ss 'Uhr'");
result = result.replace(CREATION_DATE, f.format(new Date(System.currentTimeMillis())));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ public static void doExport(File pHtmlFile, List<Village> pVillages) {

// <editor-fold defaultstate="collapsed" desc=" build footer">
String foot = FOOTER;
foot = foot.replace(VERSION, Double.toString(Constants.VERSION) + Constants.VERSION_ADDITION);
foot = foot.replace(VERSION, Constants.VERSION + Constants.VERSION_ADDITION);

SimpleDateFormat f = TimeManager.getSimpleDateFormat("dd.MM.yyyy 'um' HH:mm:ss 'Uhr'");

Expand Down
2 changes: 1 addition & 1 deletion ParserPlugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>de.tor.dswb</groupId>
<artifactId>dsworkbench</artifactId>
<version>4.1</version>
<version>${revision}</version>
</parent>

<modelVersion>4.0.0</modelVersion>
Expand Down
3 changes: 2 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<artifactId>dsworkbench</artifactId>
<name>DSWorkbench</name>
<packaging>pom</packaging>
<version>4.1</version>
<version>${revision}</version>

<description>
Parent project for DS Workbench. The project contains two modules: core and plugins which are put together
Expand All @@ -17,6 +17,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<release.version>${project.version}</release.version>
<revision>4.1.1</revision>
</properties>

<repositories>
Expand Down

0 comments on commit 1a2b4cd

Please sign in to comment.