mirror of
https://github.com/0PandaDEV/Qopy.git
synced 2025-04-21 21:24:05 +02:00
feat: add autostart toggle setting
This commit is contained in:
parent
6d7874c1ae
commit
3bfd72b638
7 changed files with 11 additions and 16 deletions
|
@ -69,9 +69,9 @@ async fn apply_migrations(pool: &SqlitePool) -> Result<(), Box<dyn std::error::E
|
|||
.files()
|
||||
.filter_map(|file| {
|
||||
let file_name = file.path().file_name()?.to_str()?;
|
||||
if file_name.ends_with(".sql") && file_name.starts_with("migration") {
|
||||
if file_name.ends_with(".sql") && file_name.starts_with("v") {
|
||||
let version: i64 = file_name
|
||||
.trim_start_matches("migration")
|
||||
.trim_start_matches("v")
|
||||
.trim_end_matches(".sql")
|
||||
.parse()
|
||||
.ok()?;
|
||||
|
|
1
src-tauri/src/db/migrations/v3.sql
Normal file
1
src-tauri/src/db/migrations/v3.sql
Normal file
|
@ -0,0 +1 @@
|
|||
INSERT INTO settings (key, value) VALUES ('autostart', 'true');
|
Loading…
Add table
Add a link
Reference in a new issue