Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
5a112d7
比較対象Bookへの着色に失敗しても先に進むように変更
nmby Sep 5, 2025
9038b58
過剰なtry-catchの削除
nmby Sep 5, 2025
2133366
GoogleDriveファイルダウンロード失敗時のエラーダイアログ表示
nmby Sep 5, 2025
d10c1f7
Merge pull request #143 from nmby/improveErrorHandling
nmby Sep 5, 2025
a2fed83
詳細設定ダイアログの導入
nmby Sep 8, 2025
fe9aaa7
CheckUpdatesの導入
nmby Sep 12, 2025
eca7f26
GoogleCredential取得タスクのデーモン化
nmby Sep 12, 2025
9c45cab
xmlnsの考慮
nmby Sep 12, 2025
ce137ff
xmlnsの考慮
nmby Sep 12, 2025
60e2e20
SAX読み取り不可時の挙動を修正
nmby Sep 12, 2025
ffb3fa1
Merge pull request #144 from nmby/improveXMLProcessing
nmby Sep 12, 2025
7fdbf5b
Github Pages用JSON
nmby Sep 13, 2025
1ce868b
最新バージョンチェック機能の追加
nmby Sep 13, 2025
13d96cb
新バージョン有無を直ちに確認する機能の追加
nmby Sep 13, 2025
4c7db61
設定ファイル表示・設定リセット機能の追加
nmby Sep 13, 2025
2790704
UI整理
nmby Sep 14, 2025
23b9a8a
メッセージの国際化
nmby Sep 14, 2025
3529cc9
メッセージの国際化
nmby Sep 14, 2025
c436031
メッセージの国際化
nmby Sep 14, 2025
91dd927
UI微調整
nmby Sep 14, 2025
ab611c5
Merge pull request #145 from nmby/improveSettings
nmby Sep 14, 2025
3978129
xmlnsの考慮
nmby Sep 14, 2025
04f22c4
xmlnsの考慮
nmby Sep 15, 2025
83fc13c
Merge pull request #146 from nmby/improveXMLProcessing
nmby Sep 15, 2025
bb17e84
update version (0.26.2 -> 0.27.0)
nmby Sep 15, 2025
bce24ff
バージョン管理を専用クラス化
nmby Sep 19, 2025
0263f85
不要な設定項目CLIENT_UUIDの廃止
nmby Sep 19, 2025
320681c
実装整理
nmby Sep 19, 2025
14b7728
バージョンチェック間隔の変更
nmby Sep 19, 2025
af018f1
バージョンチェック機能の微修正
nmby Sep 19, 2025
920a67d
Merge pull request #147 from nmby/updateVersion
nmby Sep 19, 2025
87d320c
update gradle (9.0.0 -> 9.1.0)
nmby Sep 19, 2025
2383258
update google lib
nmby Sep 19, 2025
d9d1603
update javafx (24.0.2 -> 25)
nmby Sep 19, 2025
e7fee4c
名前変更:DirLoader -> DirInfoLoader
nmby Sep 20, 2025
d7040ac
名前変更:SheetNamesLoader -> BookInfoLoader
nmby Sep 20, 2025
b31a7ab
Merge pull request #148 from nmby/refactoring
nmby Sep 20, 2025
716730e
不要なjdk設定の削除
nmby Sep 25, 2025
7db392a
update java (24.0.2 -> 25)
nmby Sep 26, 2025
0ed4149
update log4j (2.25.1 -> 2.25.2)
nmby Sep 26, 2025
7b30b8f
Merge pull request #149 from nmby/updateLibs
nmby Sep 26, 2025
e1100a4
未使用パラメータの匿名化
nmby Sep 26, 2025
4b9df8c
Merge pull request #150 from nmby/refactoring
nmby Sep 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ hs_err_pid*
# Ignore Gradle build output directory
.DS_Store

gradle.properties
#gradle.properties
xyz.hotchpotch.hogandiff/src/main/resources/xyz/hotchpotch/hogandiff/google/credentials.json
2 changes: 1 addition & 1 deletion .settings/org.eclipse.buildship.core.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ connection.gradle.distribution=GRADLE_DISTRIBUTION(WRAPPER)
connection.project.dir=
eclipse.preferences.version=1
gradle.user.home=
java.home=C\:/UserLibs/jdk-24.0.1+9-win-x64
java.home=
jvm.arguments=
offline.mode=false
override.workspace.settings=true
Expand Down
6 changes: 0 additions & 6 deletions .vscode/settings.json

This file was deleted.

6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import java.time.format.DateTimeFormatter
import java.nio.file.Files
import java.nio.file.Path

final def version = '0.26.2'
final def version = '0.27.0'

final def timetag = LocalDateTime.now().format(DateTimeFormatter.ofPattern('yyyyMMdd-HHmmss-SSS'))
final def baseDir = projectDir.toPath()
Expand Down Expand Up @@ -83,7 +83,7 @@ task exewrapForWinX64(type: Exec, dependsOn: pickupAndExpandFatJar) {
commandLine project['myprop.cmd.exewrap'],
'-g',
// 直近の LTS-version とする。
'-t', '21',
'-t', '25',
'-i', baseDir.resolve('resources/favicon.ico'),
'-v', version,
'-V', version,
Expand Down Expand Up @@ -220,7 +220,7 @@ task checkDependencies(type: Exec, dependsOn: pickupAndExpandFatJar) {

commandLine project['myprop.cmd.jdeps'],
// 直近の LTS-version とする。
'--multi-release', 21,
'--multi-release', 25,
'--module-path', "${project['myprop.jre.mod.win.x64']};${project['myprop.jfx.sdk.win.x64']};${outputDirTmpJars}",
'-s', outputDirTmpJars.resolve("xyz.hotchpotch.hogandiff.jar")
}
3 changes: 3 additions & 0 deletions docs/api/versions/latest
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"version": "0.27.0",
}
17 changes: 17 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
org.gradle.java.home=C:/UserLibs/jdk-25+36-win-x64

myprop.cmd.exewrap=C:/UserLibs/exewrap-1.6.6/x64/exewrap.exe
myprop.cmd.jlink=C:/UserLibs/jdk-25+36-win-x64/bin/jlink
myprop.cmd.jdeps=C:/UserLibs/jdk-25+36-win-x64/bin/jdeps
myprop.cmd.jpackage=C:/UserLibs/jdk-25+36-win-x64/bin/jpackage

myprop.userlib=C:/UserLibs
myprop.jre.mod.win.x64=C:/UserLibs/jdk-25+36-jmods-win-x64
myprop.jre.mod.mac.x64=C:/UserLibs/jdk-25+36-jmods-mac-x64

myprop.jfx.mod.win.x64=C:/UserLibs/javafx-jmods-25-win-x64
myprop.jfx.mod.mac.x64=C:/UserLibs/javafx-jmods-25-mac-x64

myprop.jfx.sdk.win.x64=C:/UserLibs/javafx-sdk-25-win-x64/lib
myprop.poi.src=C:/UserLibs/apache-poi-src-5.4.1-20250401
myprop.log4j.bin=C:/UserLibs/apache-log4j-2.25.2-bin
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
4 changes: 2 additions & 2 deletions resources/hogandiff.app/Contents/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
<string>xyz.hotchpotch.hogandiff</string>

<key>CFBundleShortVersionString</key>
<string>0.26.2</string>
<string>0.27.0</string>

<key>CFBundleVersion</key>
<string>0.26.2</string>
<string>0.27.0</string>

<key>CFBundleExecutable</key>
<string>Launcher.sh</string>
Expand Down
2 changes: 1 addition & 1 deletion xyz.hotchpotch.hogandiff/.classpath
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21/"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-25/"/>
<classpathentry kind="con" path="org.eclipse.buildship.core.gradleclasspathcontainer"/>
<classpathentry kind="output" path="bin/default"/>
</classpath>
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ connection.gradle.distribution=GRADLE_DISTRIBUTION(WRAPPER)
connection.project.dir=
eclipse.preferences.version=1
gradle.user.home=
java.home=C\:/UserLibs/jdk-24.0.1+9-win-x64
java.home=
jvm.arguments=
offline.mode=false
override.workspace.settings=true
Expand Down
6 changes: 3 additions & 3 deletions xyz.hotchpotch.hogandiff/.settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.targetPlatform=21
org.eclipse.jdt.core.compiler.compliance=21
org.eclipse.jdt.core.compiler.source=21
org.eclipse.jdt.core.compiler.codegen.targetPlatform=25
org.eclipse.jdt.core.compiler.compliance=25
org.eclipse.jdt.core.compiler.source=25
10 changes: 5 additions & 5 deletions xyz.hotchpotch.hogandiff/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ repositories {

dependencies {
implementation 'org.apache.poi:poi-ooxml:5.4.1'
implementation 'org.apache.logging.log4j:log4j-core:2.25.1'
implementation 'org.apache.logging.log4j:log4j-core:2.25.2'
implementation 'com.google.oauth-client:google-oauth-client-jetty:1.39.0'
implementation 'com.google.apis:google-api-services-drive:v3-rev20250723-2.0.0'
implementation 'com.google.apis:google-api-services-drive:v3-rev20250910-2.0.0'
implementation 'com.google.apis:google-api-services-oauth2:v2-rev20200213-2.0.0'
implementation 'org.json:json:20250517'
implementation 'io.github.cdimascio:dotenv-java:3.2.0'
Expand All @@ -29,8 +29,8 @@ test {

java {
// 直近の LTS-version とする。
sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
sourceCompatibility = JavaVersion.VERSION_25
targetCompatibility = JavaVersion.VERSION_25
}

tasks.withType(JavaCompile) {
Expand All @@ -39,7 +39,7 @@ tasks.withType(JavaCompile) {

javafx {
// 直近の LTS-version とする。
version = 21
version = 25
modules = [ 'javafx.controls', 'javafx.fxml' ]
}

Expand Down
2 changes: 1 addition & 1 deletion xyz.hotchpotch.hogandiff/gradle.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
org.gradle.java.home=C:/UserLibs/jdk-24.0.2+12-win-x64
org.gradle.java.home=C:/UserLibs/jdk-25+36-win-x64
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Binary file modified xyz.hotchpotch.hogandiff/messages.properties管理.xlsx
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
package xyz.hotchpotch.hogandiff;

import java.awt.Desktop;
import java.io.IOException;
import java.net.URI;
import java.util.UUID;

import org.apache.poi.openxml4j.util.ZipSecureFile;

import javafx.application.Application;
Expand All @@ -25,9 +20,6 @@ public class AppMain extends Application {

// [static members] ********************************************************

/** このアプリケーションのバージョン */
public static final String VERSION = "v0.26.2";

/** このアプリケーションのドメイン(xyz.hotchpotch.hogandiff) */
public static final String APP_DOMAIN = AppMain.class.getPackageName();

Expand All @@ -53,7 +45,8 @@ public class AppMain extends Application {
/**
* このアプリケーションのエントリポイントです。<br>
*
* @param args アプリケーション実行時引数
* @param args
* アプリケーション実行時引数
*/
public static void main(String[] args) {
appResource.reflectArgs(args);
Expand All @@ -70,7 +63,7 @@ public static void main(String[] args) {
public void start(Stage primaryStage) throws Exception {
stage = primaryStage;

announceNewFeature();
VersionMaster.announceNewFeature1();

// Zip bomb対策の制限の緩和。規定値の0.01から0.001に変更する。
// いささか乱暴ではあるものの、ファイルを開く都度ではなくここで一括で設定してしまう。
Expand All @@ -91,7 +84,7 @@ public void start(Stage primaryStage) throws Exception {
primaryStage.setTitle(
appResource.get().getString("AppMain.010")
+ " - "
+ VERSION);
+ VersionMaster.APP_VERSION);

primaryStage.setMinHeight(
settings.get(SettingKeys.SHOW_SETTINGS)
Expand All @@ -108,54 +101,27 @@ public void start(Stage primaryStage) throws Exception {
if (settings.containsKey(SettingKeys.STAGE_MAXIMIZED)) {
primaryStage.setMaximized(settings.get(SettingKeys.STAGE_MAXIMIZED));
}
primaryStage.heightProperty().addListener((target, oldValue, newValue) -> {
primaryStage.heightProperty().addListener((_, _, newValue) -> {
if (!primaryStage.isMaximized()) {
appResource.changeSetting(SettingKeys.STAGE_HEIGHT, (Double) newValue);
}
});
primaryStage.widthProperty().addListener((target, oldValue, newValue) -> {
primaryStage.widthProperty().addListener((_, _, newValue) -> {
if (!primaryStage.isMaximized()) {
appResource.changeSetting(SettingKeys.STAGE_WIDTH, (Double) newValue);
}
});
primaryStage.maximizedProperty().addListener((target, oldValue, newValue) -> {
primaryStage.maximizedProperty().addListener((_, _, newValue) -> {
appResource.changeSetting(SettingKeys.STAGE_MAXIMIZED, newValue);
});

primaryStage.show();
VersionMaster.announceNewFeature2();

MainController controller = loader.getController();
if (controller.isReady().getValue()) {
controller.updateActiveComparison();
controller.execute();
}
}

/**
* ユーザーが現在のバージョンを初めて起動した際の処理を行います。<br>
*/
private void announceNewFeature() {
// UUIDが未採番の場合は採番する。
UUID uuid = appResource.settings().get(SettingKeys.CLIENT_UUID);
if (uuid == null) {
appResource.changeSetting(SettingKeys.CLIENT_UUID, UUID.randomUUID());
}

// 前回までの利用Versionを調べ、新バージョンの初回起動の場合は新バージョンに応じた処理を行う。
String prevVersion = appResource.settings().get(SettingKeys.APP_VERSION);
if (!VERSION.equals(prevVersion)) {

assert VERSION.equals("v0.26.2");
// v0.26.2 では次を行う。
// ・新機能紹介ページの表示

try {
Desktop.getDesktop().browse(URI.create("https://hogandiff.hotchpotch.xyz/releasenotes/v0-26-2/"));
} catch (IOException e) {
e.printStackTrace();
// nop
}
appResource.changeSetting(SettingKeys.APP_VERSION, VERSION);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public class AppResource {
}

/** プロパティファイルの相対パス */
private static Path APP_PROP_PATH = USER_HOME != null
public static Path APP_PROP_PATH = USER_HOME != null
? USER_HOME.resolve("hogandiff.properties")
: null;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
import java.awt.Color;
import java.lang.reflect.Modifier;
import java.nio.file.Path;
import java.time.Instant;
import java.util.Locale;
import java.util.Map;
import java.util.Set;
import java.util.UUID;
import java.util.function.Function;
import java.util.stream.Collectors;
import java.util.stream.Stream;
Expand All @@ -28,19 +28,11 @@ public class SettingKeys {
// [static members] ********************************************************

private static <T> Function<String, T> decodeNotSupported(String msg) {
return str -> {
return _ -> {
throw new UnsupportedOperationException(msg);
};
}

/** クライアント上で生成されたUUID */
public static final Key<UUID> CLIENT_UUID = new Key<>(
"client.uuid",
() -> null,
UUID::toString,
UUID::fromString,
true);

/** このアプリケーションの実行したことのあるバージョン */
public static final Key<String> APP_VERSION = new Key<>(
"application.appVersion",
Expand Down Expand Up @@ -117,7 +109,7 @@ private static <T> Function<String, T> decodeNotSupported(String msg) {
public static final Key<Map<Path, String>> CURR_READ_PASSWORDS = new Key<>(
"current.readPasswords",
() -> Map.of(),
readPasswords -> "*****",
_ -> "*****",
decodeNotSupported("cannot decode."),
false);

Expand Down Expand Up @@ -316,6 +308,30 @@ private static <T> Function<String, T> decodeNotSupported(String msg) {
Boolean::valueOf,
true);

/** 起動時に新規バージョンの有無を確認するか */
public static final Key<Boolean> CHECK_UPDATES = new Key<>(
"application.checkUpdates",
() -> false,
String::valueOf,
Boolean::valueOf,
true);

/** 新バージョン有無の最終チェック日時 */
public static final Key<Instant> LAST_CHECK_UPDATES = new Key<>(
"application.lastCheckUpdates",
() -> null,
Instant::toString,
Instant::parse,
true);

/** 新バージョン有無チェックの最短間隔(時間) */
public static final Key<Integer> CHECK_UPDATES_INTERVAL_MINUTES = new Key<>(
"application.checkUpdatesIntervalHours",
() -> 120,
String::valueOf,
Integer::valueOf,
false);

/** 全ての定義済み設定項目を含むセット */
// Collectors#toSet は現在の実装では immutable set を返すが
// 保証されないということなので、一応 Set#copyOf でラップしておく。
Expand Down
Loading