Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 99de143c89 | |||
| 9809657b84 | |||
| 2b61520524 | |||
| 8b7bced138 |
+1
-1
Submodule cinny updated: 6a05ff5840...80fd8863c9
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "cinny",
|
"name": "cinny",
|
||||||
"version": "4.11.2",
|
"version": "4.12.2",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "cinny",
|
"name": "cinny",
|
||||||
"version": "4.11.2",
|
"version": "4.12.2",
|
||||||
"license": "AGPL-3.0-only",
|
"license": "AGPL-3.0-only",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@tauri-apps/api": "2.7.0",
|
"@tauri-apps/api": "2.7.0",
|
||||||
|
|||||||
+3
-2
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "cinny",
|
"name": "cinny",
|
||||||
"version": "4.11.2",
|
"version": "4.12.2",
|
||||||
"description": "Yet another matrix client",
|
"description": "Yet another matrix client",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -8,7 +8,8 @@
|
|||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"tauri": "cp config.json cinny/ && tauri",
|
"tauri": "cp config.json cinny/ && tauri",
|
||||||
"release": "node scripts/release.mjs"
|
"release": "node scripts/release.mjs",
|
||||||
|
"bump": "node scripts/update-version.mjs"
|
||||||
},
|
},
|
||||||
"keywords": [],
|
"keywords": [],
|
||||||
"author": "Ajay Bura",
|
"author": "Ajay Bura",
|
||||||
|
|||||||
@@ -0,0 +1,63 @@
|
|||||||
|
import fs from "fs";
|
||||||
|
import path from "path";
|
||||||
|
import { execSync } from "child_process";
|
||||||
|
|
||||||
|
const version = process.argv[2];
|
||||||
|
|
||||||
|
if (!version) {
|
||||||
|
console.error("Missing version");
|
||||||
|
process.exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log(`Preparing release ${version}`);
|
||||||
|
|
||||||
|
// 1. Update npm versions
|
||||||
|
execSync(`npm version ${version} --no-git-tag-version`, {
|
||||||
|
stdio: "inherit"
|
||||||
|
});
|
||||||
|
console.log(`Updated package.json and package-lock.json → ${version}`);
|
||||||
|
|
||||||
|
// 2. Update Cargo.toml
|
||||||
|
const cargoToml = "src-tauri/Cargo.toml";
|
||||||
|
let cargoContent = fs.readFileSync(cargoToml, "utf8");
|
||||||
|
|
||||||
|
cargoContent = cargoContent.replace(
|
||||||
|
/^version\s*=\s*".*"/m,
|
||||||
|
`version = "${version}"`
|
||||||
|
);
|
||||||
|
|
||||||
|
fs.writeFileSync(cargoToml, cargoContent);
|
||||||
|
console.log(`Updated ${cargoToml} → ${version}`);
|
||||||
|
|
||||||
|
// 3. Update tauri.conf.json
|
||||||
|
const tauriConfigPath = "src-tauri/tauri.conf.json";
|
||||||
|
const tauriConfig = JSON.parse(fs.readFileSync(tauriConfigPath));
|
||||||
|
|
||||||
|
tauriConfig.version = version;
|
||||||
|
|
||||||
|
fs.writeFileSync(
|
||||||
|
tauriConfigPath,
|
||||||
|
JSON.stringify(tauriConfig, null, 2) + "\n"
|
||||||
|
);
|
||||||
|
console.log(`Updated ${tauriConfigPath} → ${version}`);
|
||||||
|
|
||||||
|
// 4. Update Cinny web submodule to latest tag
|
||||||
|
console.log("Updating cinny web submodule");
|
||||||
|
|
||||||
|
execSync("git submodule update --init --recursive", { stdio: "inherit" });
|
||||||
|
|
||||||
|
execSync("cd cinny && git fetch --tags", { stdio: "inherit" });
|
||||||
|
|
||||||
|
const latestTag = execSync(
|
||||||
|
"cd cinny && git describe --tags $(git rev-list --tags --max-count=1)"
|
||||||
|
)
|
||||||
|
.toString()
|
||||||
|
.trim();
|
||||||
|
|
||||||
|
console.log(`Latest cinny tag: ${latestTag}`);
|
||||||
|
|
||||||
|
execSync(`cd cinny && git checkout ${latestTag}`, { stdio: "inherit" });
|
||||||
|
|
||||||
|
execSync("git add cinny", { stdio: "inherit" });
|
||||||
|
|
||||||
|
console.log("Release preparation complete");
|
||||||
Generated
+1
-1
@@ -512,7 +512,7 @@ checksum = "6e4de3bc4ea267985becf712dc6d9eed8b04c953b3fcfb339ebc87acd9804901"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "cinny"
|
name = "cinny"
|
||||||
version = "4.11.2"
|
version = "4.12.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"serde",
|
"serde",
|
||||||
"serde_json",
|
"serde_json",
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "cinny"
|
name = "cinny"
|
||||||
version = "4.11.2"
|
version = "4.12.2"
|
||||||
description = "Yet another matrix client"
|
description = "Yet another matrix client"
|
||||||
authors = ["Ajay Bura"]
|
authors = ["Ajay Bura"]
|
||||||
license = "AGPL-3.0-only"
|
license = "AGPL-3.0-only"
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ pub fn run() {
|
|||||||
let app_handle = app.handle().clone();
|
let app_handle = app.handle().clone();
|
||||||
WebviewWindowBuilder::new(app, "main".to_string(), window_url)
|
WebviewWindowBuilder::new(app, "main".to_string(), window_url)
|
||||||
.title("Cinny")
|
.title("Cinny")
|
||||||
|
.disable_drag_drop_handler()
|
||||||
.on_new_window(move |url, _features| {
|
.on_new_window(move |url, _features| {
|
||||||
let _ = app_handle.opener().open_url(url.as_str(), None::<&str>);
|
let _ = app_handle.opener().open_url(url.as_str(), None::<&str>);
|
||||||
NewWindowResponse::Deny
|
NewWindowResponse::Deny
|
||||||
|
|||||||
@@ -47,7 +47,7 @@
|
|||||||
},
|
},
|
||||||
"productName": "Cinny",
|
"productName": "Cinny",
|
||||||
"mainBinaryName": "cinny",
|
"mainBinaryName": "cinny",
|
||||||
"version": "4.11.2",
|
"version": "4.12.2",
|
||||||
"identifier": "in.cinny.app",
|
"identifier": "in.cinny.app",
|
||||||
"plugins": {
|
"plugins": {
|
||||||
"updater": {
|
"updater": {
|
||||||
@@ -59,7 +59,7 @@
|
|||||||
},
|
},
|
||||||
"app": {
|
"app": {
|
||||||
"security": {
|
"security": {
|
||||||
"csp": "default-src 'self' blob: data: filesystem: ws: wss: http: https: tauri:; script-src 'self' 'unsafe-eval' 'unsafe-inline' blob: data: filesystem: ws: wss: http: https: tauri:; img-src 'self' data: blob: filesystem: http: https:; connect-src 'self' blob: ipc: ws: wss: http: https: http://ipc.localhost"
|
"csp": "default-src 'self' blob: data: filesystem: ws: wss: http: https: tauri:; script-src 'self' 'unsafe-eval' 'unsafe-inline' blob: data: filesystem: ws: wss: http: https: tauri:; style-src 'self' 'unsafe-inline' blob: data: filesystem: http: https:; img-src 'self' data: blob: filesystem: http: https:; connect-src 'self' blob: ipc: ws: wss: http: https: http://ipc.localhost"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user