diff --git a/CHANGELOG.md b/CHANGELOG.md index a536f9da..6ea3de24 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## [Unreleased] +## [0.30.0] ### Changed @@ -535,7 +535,7 @@ Nothing changes, this release to build for multiarch docker image - fix panic when using local source -[Unreleased]: https://github.com/faldez/tanoshi/compare/v0.29.2...HEAD +[0.30.0]: https://github.com/faldez/tanoshi/compare/v0.29.2...v0.30.0 [0.29.2]: https://github.com/faldez/tanoshi/compare/v0.29.1...v0.29.2 [0.29.1]: https://github.com/faldez/tanoshi/compare/v0.29.0...v0.29.1 [0.29.0]: https://github.com/faldez/tanoshi/compare/v0.28.1...v0.29.0 diff --git a/Cargo.lock b/Cargo.lock index 71957e7e..b5a8afbf 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -5219,7 +5219,7 @@ checksum = "20f34339676cdcab560c9a82300c4c2581f68b9369aedf0fae86f2ff9565ff3e" [[package]] name = "tanoshi" -version = "0.29.2" +version = "0.30.0" dependencies = [ "aes", "anyhow", diff --git a/crates/tanoshi-web/Trunk.toml b/crates/tanoshi-web/Trunk.toml index 5493d5eb..70b5af76 100644 --- a/crates/tanoshi-web/Trunk.toml +++ b/crates/tanoshi-web/Trunk.toml @@ -12,3 +12,6 @@ backend = "http://localhost:3030/image" sass = "1.50.0" wasm_bindgen = "0.2.80" wasm_opt = "version_108" + +[serve] +address = "0.0.0.0" diff --git a/crates/tanoshi/Cargo.toml b/crates/tanoshi/Cargo.toml index bd52210a..0d67bce1 100644 --- a/crates/tanoshi/Cargo.toml +++ b/crates/tanoshi/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "tanoshi" -version = "0.29.2" +version = "0.30.0" edition = "2021" description = "Tanoshi" repository = "https://github.com/faldez/tanoshi" diff --git a/crates/tanoshi/src-tauri/tauri.conf.json b/crates/tanoshi/src-tauri/tauri.conf.json index 07a4d99e..7a1ffb9b 100644 --- a/crates/tanoshi/src-tauri/tauri.conf.json +++ b/crates/tanoshi/src-tauri/tauri.conf.json @@ -1,7 +1,7 @@ { "package": { "productName": "Tanoshi", - "version": "0.29.2" + "version": "0.30.0" }, "build": { "distDir": "../../tanoshi-web/dist", diff --git a/crates/tanoshi/src/infrastructure/database.rs b/crates/tanoshi/src/infrastructure/database.rs index 2188accd..2da1727d 100644 --- a/crates/tanoshi/src/infrastructure/database.rs +++ b/crates/tanoshi/src/infrastructure/database.rs @@ -1,6 +1,9 @@ use std::ops::{Deref, DerefMut}; -use sqlx::sqlite::{SqliteConnectOptions, SqlitePool, SqlitePoolOptions}; +use sqlx::{ + migrate::MigrateError, + sqlite::{SqliteConnectOptions, SqlitePool, SqlitePoolOptions}, +}; #[derive(Clone)] pub struct Pool(SqlitePool); @@ -40,7 +43,15 @@ pub async fn establish_connection( .connect_with(opts) .await?; - sqlx::migrate!("./migrations").run(&pool).await?; + match sqlx::migrate!("./migrations").run(&pool).await { + Err(MigrateError::VersionMismatch(version)) => { + warn!("migration {version} was previously applied but has been modified") + } + Err(e) => { + return Err(e.into()); + } + _ => {} + } Ok(Pool(pool)) }