Compare commits

...

2 Commits

Author SHA1 Message Date
HorizonCode 80bd096834 chore: bump version 2026-01-04 19:36:57 +01:00
HorizonCode e1c6e35f95 chore: refactor version syncing logic in sync-version.ts 2026-01-04 19:36:39 +01:00
5 changed files with 16 additions and 9 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "ezpplauncher", "name": "ezpplauncher",
"version": "3.0.9", "version": "3.0.10",
"description": "", "description": "",
"type": "module", "type": "module",
"scripts": { "scripts": {
+12 -5
View File
@@ -3,19 +3,26 @@ import path from 'path';
import * as toml from '@iarna/toml'; import * as toml from '@iarna/toml';
import { cwd } from 'process'; import { cwd } from 'process';
const packageJsonPath = path.join(cwd(), 'package.json');
const cargoTomlPath = path.join(cwd(), 'src-tauri', 'Cargo.toml'); const cargoTomlPath = path.join(cwd(), 'src-tauri', 'Cargo.toml');
const tauriConfPath = path.join(cwd(), 'src-tauri', 'tauri.conf.json'); const tauriConfPath = path.join(cwd(), 'src-tauri', 'tauri.conf.json');
const cargoToml = fs.readFileSync(cargoTomlPath, 'utf8'); const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf8'));
const cargo = toml.parse(cargoToml) as Record<string, string>; const version = packageJson.version;
if (!version) throw new Error('Could not find version in package.json');
const version = cargo.package['version']; let cargoTomlContent = fs.readFileSync(cargoTomlPath, 'utf8');
if (!version) throw new Error('Could not find version in Cargo.toml'); const cargo = toml.parse(cargoTomlContent) as { package: { version: string } };
if (cargo.package.version !== version) {
cargoTomlContent = cargoTomlContent.replace(/version = ".*?"/, `version = "${version}"`);
fs.writeFileSync(cargoTomlPath, cargoTomlContent);
console.log(`✅ Synced Cargo.toml version to ${version}`);
}
const tauriConf = JSON.parse(fs.readFileSync(tauriConfPath, 'utf8')); const tauriConf = JSON.parse(fs.readFileSync(tauriConfPath, 'utf8'));
if (tauriConf.version !== version) { if (tauriConf.version !== version) {
tauriConf.version = version; tauriConf.version = version;
fs.writeFileSync(tauriConfPath, JSON.stringify(tauriConf, null, 2)); fs.writeFileSync(tauriConfPath, JSON.stringify(tauriConf, null, 2));
console.log(`✅ Synced tauri.conf.json version to ${version}`); console.log(`✅ Synced tauri.conf.json version to ${version}`);
} }
+1 -1
View File
@@ -1007,7 +1007,7 @@ dependencies = [
[[package]] [[package]]
name = "ezpplauncher" name = "ezpplauncher"
version = "3.0.9" version = "3.0.10"
dependencies = [ dependencies = [
"base64 0.22.1", "base64 0.22.1",
"discord-rich-presence", "discord-rich-presence",
+1 -1
View File
@@ -1,6 +1,6 @@
[package] [package]
name = "ezpplauncher" name = "ezpplauncher"
version = "3.0.9" version = "3.0.10"
description = "EZPPLauncher redefined." description = "EZPPLauncher redefined."
authors = ["HorizonCode"] authors = ["HorizonCode"]
edition = "2024" edition = "2024"
+1 -1
View File
@@ -1,7 +1,7 @@
{ {
"$schema": "https://schema.tauri.app/config/2", "$schema": "https://schema.tauri.app/config/2",
"productName": "EZPPLauncher", "productName": "EZPPLauncher",
"version": "3.0.9", "version": "3.0.10",
"identifier": "farm.EZPPFarm.Launcher", "identifier": "farm.EZPPFarm.Launcher",
"mainBinaryName": "ezpplauncher", "mainBinaryName": "ezpplauncher",
"build": { "build": {