diff --git a/Cargo.lock b/Cargo.lock index d81184b..e066429 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1132,53 +1132,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "cosmic-tasks" -version = "0.1.0" -dependencies = [ - "chrono", - "cli-clipboard", - "cosmic-tasks-core", - "dirs", - "emojis", - "env_logger", - "fork", - "i18n-embed", - "i18n-embed-fl", - "libcosmic", - "log", - "once_cell", - "open", - "paste", - "rust-embed", - "serde", - "slotmap", - "smol_str", - "tokio", - "tracing", - "vergen", -] - -[[package]] -name = "cosmic-tasks-core" -version = "0.1.0" -dependencies = [ - "anyhow", - "async-trait", - "chrono", - "derive-getters", - "derive_setters", - "dirs", - "emojis", - "libset", - "ron", - "serde", - "serde_json", - "sqlx", - "tracing", - "uuid", -] - [[package]] name = "cosmic-text" version = "0.11.2" @@ -3731,6 +3684,53 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "orderly" +version = "0.1.0" +dependencies = [ + "chrono", + "cli-clipboard", + "dirs", + "emojis", + "env_logger", + "fork", + "i18n-embed", + "i18n-embed-fl", + "libcosmic", + "log", + "once_cell", + "open", + "orderly-core", + "paste", + "rust-embed", + "serde", + "slotmap", + "smol_str", + "tokio", + "tracing", + "vergen", +] + +[[package]] +name = "orderly-core" +version = "0.1.0" +dependencies = [ + "anyhow", + "async-trait", + "chrono", + "derive-getters", + "derive_setters", + "dirs", + "emojis", + "libset", + "ron", + "serde", + "serde_json", + "sqlx", + "tracing", + "uuid", +] + [[package]] name = "os_pipe" version = "1.1.5" diff --git a/Cargo.toml b/Cargo.toml index 5eceb76..ad55add 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "cosmic-tasks" +name = "orderly" version = "0.1.0" edition = "2021" @@ -19,7 +19,7 @@ open = "5.0.2" dirs = "5.0.1" chrono = "0.4.35" tokio = "1" -cosmic-tasks-core = { path = "src/core" } +orderly-core = { path = "src/core" } tracing = "0.1.40" cli-clipboard = "0.4.0" slotmap = "1.0.7" diff --git a/README.md b/README.md index 18c746d..d41991b 100644 --- a/README.md +++ b/README.md @@ -1,25 +1,25 @@

- -

COSMIC Tasks

- + +

Orderly

+

A simple task management application for the COSMIC desktop.

- ![window-light.png](https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/main/res/screenshots/window-light.png#gh-light-mode-only) - ![window-dark.png](https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/main/res/screenshots/window-dark.png#gh-dark-mode-only) + ![window-light.png](https://raw.githubusercontent.com/edfloreshz/orderly/main/res/screenshots/window-light.png#gh-light-mode-only) + ![window-dark.png](https://raw.githubusercontent.com/edfloreshz/orderly/main/res/screenshots/window-dark.png#gh-dark-mode-only)
# Installation ``` -git clone https://github.com/edfloreshz/cosmic-tasks.git -cd cosmic-tasks +git clone https://github.com/edfloreshz/orderly.git +cd orderly sudo just install ``` # Build ``` -git clone https://github.com/edfloreshz/cosmic-tasks.git -cd cosmic-tasks +git clone https://github.com/edfloreshz/orderly.git +cd orderly cargo build ``` @@ -41,4 +41,4 @@ sudo apt install sqlite-devel Copyright 2024 © Eduardo Flores -Done is released under the terms of the [GPL-3.0](https://github.com/edfloreshz/cosmic-tasks/blob/main/LICENSE) +Done is released under the terms of the [GPL-3.0](https://github.com/edfloreshz/orderly/blob/main/LICENSE) diff --git a/com.system76.CosmicTasks.json b/com.system76.CosmicTasks.json index a1d5ae6..9f96207 100644 --- a/com.system76.CosmicTasks.json +++ b/com.system76.CosmicTasks.json @@ -1,12 +1,10 @@ { - "id": "com.system76.CosmicTasks", + "id": "dev.edfloreshz.Orderly", "runtime": "org.freedesktop.Platform", "runtime-version": "23.08", "sdk": "org.freedesktop.Sdk", - "sdk-extensions": [ - "org.freedesktop.Sdk.Extension.rust-stable" - ], - "command": "cosmic-tasks", + "sdk-extensions": ["org.freedesktop.Sdk.Extension.rust-stable"], + "command": "orderly", "finish-args": [ "--share=ipc", "--socket=fallback-x11", @@ -15,20 +13,16 @@ ], "build-options": { "append-path": "/usr/lib/sdk/rust-stable/bin", - "build-args": [ - "--share=network" - ], + "build-args": ["--share=network"], "env": { - "CARGO_HOME": "/run/build/cosmic-tasks/cargo" + "CARGO_HOME": "/run/build/orderly/cargo" } }, "modules": [ { "name": "just", "buildsystem": "simple", - "build-commands": [ - "install -Dm0755 just /app/bin/just" - ], + "build-commands": ["install -Dm0755 just /app/bin/just"], "sources": [ { "type": "archive", @@ -36,9 +30,7 @@ "dest-filename": "just.tar.gz", "url": "https://github.com/casey/just/releases/download/1.25.2/just-1.25.2-x86_64-unknown-linux-musl.tar.gz", "sha256": "ad56bf1a804243b51ef2c2eec4b3a8177f970ccc414cbbee219c2e5c06f7bcc9", - "only_arches": [ - "x86_64" - ] + "only_arches": ["x86_64"] }, { "type": "archive", @@ -46,27 +38,21 @@ "dest-filename": "just.tar.gz", "url": "https://github.com/casey/just/releases/download/1.25.2/just-1.25.2-aarch64-unknown-linux-musl.tar.gz", "sha256": "049d624255d150f18b0f3a1257a163366b0dc22e16526214773903125145e515", - "only_arches": [ - "aarch64" - ] + "only_arches": ["aarch64"] } ] }, { - "name": "cosmic-tasks", + "name": "orderly", "buildsystem": "simple", - "build-commands": [ - "just vendor", - "just build-vendored", - "just flatpak" - ], + "build-commands": ["just vendor", "just build-vendored", "just flatpak"], "sources": [ { "type": "git", "branch": "main", - "url": "https://github.com/edfloreshz/cosmic-tasks.git" + "url": "https://github.com/edfloreshz/orderly.git" } ] } ] -} \ No newline at end of file +} diff --git a/com.system76.CosmicTasks.yml b/com.system76.CosmicTasks.yml index a18da1f..3a37197 100644 --- a/com.system76.CosmicTasks.yml +++ b/com.system76.CosmicTasks.yml @@ -1,10 +1,10 @@ -id: com.system76.CosmicTasks +id: dev.edfloreshz.Orderly runtime: org.freedesktop.Platform -runtime-version: '23.08' +runtime-version: "23.08" sdk: org.freedesktop.Sdk sdk-extensions: - org.freedesktop.Sdk.Extension.rust-stable -command: cosmic-tasks +command: orderly finish-args: - "--share=ipc" - "--socket=fallback-x11" @@ -15,7 +15,7 @@ build-options: build-args: - "--share=network" env: - CARGO_HOME: "/run/build/cosmic-tasks/cargo" + CARGO_HOME: "/run/build/orderly/cargo" modules: - name: just buildsystem: simple @@ -36,7 +36,7 @@ modules: sha256: 049d624255d150f18b0f3a1257a163366b0dc22e16526214773903125145e515 only_arches: - aarch64 - - name: cosmic-tasks + - name: orderly buildsystem: simple build-commands: - just vendor @@ -45,4 +45,4 @@ modules: sources: - type: git branch: main - url: https://github.com/edfloreshz/cosmic-tasks.git \ No newline at end of file + url: https://github.com/edfloreshz/orderly.git diff --git a/docs/index.html b/docs/index.html index 07cb020..60aa8a4 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1,84 +1,125 @@ - + - - - COSMIC Tasks - - - - - - + -
-
-
- Workflow -
-
-
-

- Go Supernova -

-

- Unleash your interstellar potential -

-

- A simple task management app, reaching across the cosmos to help you get things done -

+
+
+
+ Workflow +
+
+
+

+ Go Supernova +

+

+ Unleash your interstellar potential +

+

+ A simple task management app, reaching across the cosmos + to help you get things done +

+
+ + +
- - -
-
- - \ No newline at end of file + + diff --git a/docs/style.css b/docs/style.css index f2c7cb2..7a6420c 100644 --- a/docs/style.css +++ b/docs/style.css @@ -1,6 +1,6 @@ @media (prefers-color-scheme: dark) { #screenshot { - content: url("https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/main/res/screenshots/window-dark.png?raw=true"); + content: url("https://raw.githubusercontent.com/edfloreshz/orderly/main/res/screenshots/window-dark.png?raw=true"); } html { @@ -10,10 +10,10 @@ @media (prefers-color-scheme: light) { #screenshot { - content: url("https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/main/res/screenshots/window-light.png?raw=true"); + content: url("https://raw.githubusercontent.com/edfloreshz/orderly/main/res/screenshots/window-light.png?raw=true"); } body { background: linear-gradient(to right top, #eee1ffff, #a8acfe); } -} \ No newline at end of file +} diff --git a/i18n/cs/cosmic_tasks.ftl b/i18n/cs/orderly.ftl similarity index 100% rename from i18n/cs/cosmic_tasks.ftl rename to i18n/cs/orderly.ftl diff --git a/i18n/de/cosmic_tasks.ftl b/i18n/de/orderly.ftl similarity index 96% rename from i18n/de/cosmic_tasks.ftl rename to i18n/de/orderly.ftl index b188442..99028db 100644 --- a/i18n/de/cosmic_tasks.ftl +++ b/i18n/de/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMIC Tasks +orderly = Orderly trash = Papierkorb about = Über @@ -86,4 +86,4 @@ delete = Löschen ## View view = Ansicht menu-settings = Einstellungen... -menu-about = Über COSMIC Tasks... +menu-about = Über Orderly... diff --git a/i18n/en/cosmic_tasks.ftl b/i18n/en/orderly.ftl similarity index 95% rename from i18n/en/cosmic_tasks.ftl rename to i18n/en/orderly.ftl index 1cec451..2208a08 100644 --- a/i18n/en/cosmic_tasks.ftl +++ b/i18n/en/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMIC Tasks +orderly = Orderly trash = Trash about = About @@ -86,4 +86,4 @@ delete = Delete ## View view = View menu-settings = Settings... -menu-about = About COSMIC Tasks... +menu-about = About Orderly... diff --git a/i18n/it/cosmic_tasks.ftl b/i18n/it/orderly.ftl similarity index 96% rename from i18n/it/cosmic_tasks.ftl rename to i18n/it/orderly.ftl index d5bfdd2..2bf925c 100644 --- a/i18n/it/cosmic_tasks.ftl +++ b/i18n/it/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMIC Tasks +orderly = Orderly empty-folder = Cartella vuota empty-folder-hidden = Cartella vuota (contiene elementi nascosti) filesystem = Filesystem @@ -97,4 +97,4 @@ view = Vista grid-view = Griglia list-view = Lista menu-settings = Impostazioni... -menu-about = Informazioni su COSMIC Tasks... +menu-about = Informazioni su Orderly... diff --git a/i18n/ja/cosmic_tasks.ftl b/i18n/ja/orderly.ftl similarity index 98% rename from i18n/ja/cosmic_tasks.ftl rename to i18n/ja/orderly.ftl index 1dcd4ff..e273c4d 100644 --- a/i18n/ja/cosmic_tasks.ftl +++ b/i18n/ja/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMICファイル +orderly = COSMICファイル empty-folder = 空のフォルダ empty-folder-hidden = 空のフォルダ(隠しファイルあり) filesystem = ファイルシステム diff --git a/i18n/pl/cosmic_tasks.ftl b/i18n/pl/orderly.ftl similarity index 100% rename from i18n/pl/cosmic_tasks.ftl rename to i18n/pl/orderly.ftl diff --git a/i18n/pt/cosmic_tasks.ftl b/i18n/pt/orderly.ftl similarity index 98% rename from i18n/pt/cosmic_tasks.ftl rename to i18n/pt/orderly.ftl index 54991d2..cb5fc6f 100644 --- a/i18n/pt/cosmic_tasks.ftl +++ b/i18n/pt/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = Ficheiros COSMIC +orderly = Ficheiros COSMIC empty-folder = Pasta vazia empty-folder-hidden = Pasta vazia (tem ficheiros ocultos) filesystem = Sistema de ficheiros @@ -83,7 +83,7 @@ new-tab = Novo separador new-window = Nova janela rename = Renomear close-tab = Fechar separador -quit = Sair +quit = Sair ## Edit edit = Editar diff --git a/i18n/pt_BR/cosmic_tasks.ftl b/i18n/pt_BR/orderly.ftl similarity index 100% rename from i18n/pt_BR/cosmic_tasks.ftl rename to i18n/pt_BR/orderly.ftl diff --git a/i18n/ru/cosmic_tasks.ftl b/i18n/ru/orderly.ftl similarity index 96% rename from i18n/ru/cosmic_tasks.ftl rename to i18n/ru/orderly.ftl index fc3175c..8d6347c 100644 --- a/i18n/ru/cosmic_tasks.ftl +++ b/i18n/ru/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = Задачи COSMIC +orderly = Задачи COSMIC trash = Корзина about = О программе @@ -86,4 +86,4 @@ delete = Удалить ## View view = Вид menu-settings = Параметры... -menu-about = О Задачах COSMIC... \ No newline at end of file +menu-about = О Задачах COSMIC... diff --git a/i18n/sr-Cyrl/cosmic_tasks.ftl b/i18n/sr-Cyrl/orderly.ftl similarity index 98% rename from i18n/sr-Cyrl/cosmic_tasks.ftl rename to i18n/sr-Cyrl/orderly.ftl index fd527c7..bdecef2 100644 --- a/i18n/sr-Cyrl/cosmic_tasks.ftl +++ b/i18n/sr-Cyrl/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMIC Задаци +orderly = COSMIC Задаци trash = Отпад about = О програму diff --git a/i18n/sr-Latn/cosmic_tasks.ftl b/i18n/sr-Latn/orderly.ftl similarity index 98% rename from i18n/sr-Latn/cosmic_tasks.ftl rename to i18n/sr-Latn/orderly.ftl index bc5521b..3a439d9 100644 --- a/i18n/sr-Latn/cosmic_tasks.ftl +++ b/i18n/sr-Latn/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMIC Zadaci +orderly = COSMIC Zadaci trash = Otpad about = O programu diff --git a/i18n/sv/cosmic_tasks.ftl b/i18n/sv/orderly.ftl similarity index 100% rename from i18n/sv/cosmic_tasks.ftl rename to i18n/sv/orderly.ftl diff --git a/i18n/tr/cosmic_tasks.ftl b/i18n/tr/orderly.ftl similarity index 98% rename from i18n/tr/cosmic_tasks.ftl rename to i18n/tr/orderly.ftl index 06bcf58..8247eed 100644 --- a/i18n/tr/cosmic_tasks.ftl +++ b/i18n/tr/orderly.ftl @@ -1,4 +1,4 @@ -cosmic-tasks = COSMIC Görevler +orderly = COSMIC Görevler trash = Çöp about = Hakkında diff --git a/i18n/uk/cosmic_tasks.ftl b/i18n/uk/orderly.ftl similarity index 100% rename from i18n/uk/cosmic_tasks.ftl rename to i18n/uk/orderly.ftl diff --git a/i18n/zh-cn/cosmic_tasks.ftl b/i18n/zh-cn/orderly.ftl similarity index 100% rename from i18n/zh-cn/cosmic_tasks.ftl rename to i18n/zh-cn/orderly.ftl diff --git a/justfile b/justfile index 9096313..46140ad 100644 --- a/justfile +++ b/justfile @@ -1,5 +1,5 @@ -name := 'cosmic-tasks' -export APPID := 'com.system76.CosmicTasks' +name := 'orderly' +export APPID := 'dev.edfloreshz.Orderly' rootdir := '' prefix := '/usr' @@ -62,7 +62,7 @@ dev *args: # Run with debug logs run *args: - env RUST_LOG=cosmic_tasks=info RUST_BACKTRACE=full cargo run --release {{args}} + env RUST_LOG=orderly=info RUST_BACKTRACE=full cargo run --release {{args}} # Installs files install: diff --git a/res/com.system76.CosmicTasks.desktop b/res/com.system76.CosmicTasks.desktop index 4f0126f..c526d0e 100644 --- a/res/com.system76.CosmicTasks.desktop +++ b/res/com.system76.CosmicTasks.desktop @@ -1,11 +1,11 @@ #TODO: more build-out, desktop actions, translations? [Desktop Entry] -Name=COSMIC Tasks -Exec=cosmic-tasks %F +Name=Orderly +Exec=orderly %F Terminal=false Type=Application StartupNotify=true -Icon=com.system76.CosmicTasks +Icon=dev.edfloreshz.Orderly Categories=COSMIC;Utility;FileManager; Keywords=Folder;Manager; MimeType=inode/directory; diff --git a/res/com.system76.CosmicTasks.metainfo.xml b/res/com.system76.CosmicTasks.metainfo.xml index 14e7b37..6070d66 100644 --- a/res/com.system76.CosmicTasks.metainfo.xml +++ b/res/com.system76.CosmicTasks.metainfo.xml @@ -1,14 +1,14 @@ - com.system76.CosmicTasks + dev.edfloreshz.Orderly CC0-1.0 GPL-3.0-only COSMIC System76 edfloreshz@proton.me - https://github.com/edfloreshz/cosmic-tasks - https://github.com/edfloreshz/cosmic-tasks - COSMIC Tasks + https://github.com/edfloreshz/orderly + https://github.com/edfloreshz/orderly + Orderly Tasks application for the COSMIC desktop

Tasks application that provides advanced features with high performance

@@ -17,14 +17,14 @@
  • Organize your tasks into lists.
  • - com.system76.CosmicTasks.desktop - https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/master/res/icons/hicolor/256x256/apps/com.system76.CosmicTasks.svg + dev.edfloreshz.Orderly.desktop + https://raw.githubusercontent.com/edfloreshz/orderly/master/res/icons/hicolor/256x256/apps/dev.edfloreshz.Orderly.svg - https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/main/res/screenshots/window-light.png + https://raw.githubusercontent.com/edfloreshz/orderly/main/res/screenshots/window-light.png - https://raw.githubusercontent.com/edfloreshz/cosmic-tasks/main/res/screenshots/window-dark.png + https://raw.githubusercontent.com/edfloreshz/orderly/main/res/screenshots/window-dark.png @@ -32,7 +32,7 @@ text/plain - cosmic-tasks + orderly
    diff --git a/res/icons/hicolor/128x128/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/128x128/apps/dev.edfloreshz.Orderly.svg similarity index 99% rename from res/icons/hicolor/128x128/apps/com.system76.CosmicTasks.svg rename to res/icons/hicolor/128x128/apps/dev.edfloreshz.Orderly.svg index 9d94bf5..1e15033 100644 --- a/res/icons/hicolor/128x128/apps/com.system76.CosmicTasks.svg +++ b/res/icons/hicolor/128x128/apps/dev.edfloreshz.Orderly.svg @@ -9,7 +9,7 @@ id="svg1" xml:space="preserve" inkscape:version="1.3.2 (091e20ef0f, 2023-11-25)" - sodipodi:docname="com.system76.CosmicTasks.svg" + sodipodi:docname="dev.edfloreshz.Orderly.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:xlink="http://www.w3.org/1999/xlink" diff --git a/res/icons/hicolor/16x16/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/16x16/apps/dev.edfloreshz.Orderly.svg similarity index 99% rename from res/icons/hicolor/16x16/apps/com.system76.CosmicTasks.svg rename to res/icons/hicolor/16x16/apps/dev.edfloreshz.Orderly.svg index 9d94bf5..1e15033 100644 --- a/res/icons/hicolor/16x16/apps/com.system76.CosmicTasks.svg +++ b/res/icons/hicolor/16x16/apps/dev.edfloreshz.Orderly.svg @@ -9,7 +9,7 @@ id="svg1" xml:space="preserve" inkscape:version="1.3.2 (091e20ef0f, 2023-11-25)" - sodipodi:docname="com.system76.CosmicTasks.svg" + sodipodi:docname="dev.edfloreshz.Orderly.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:xlink="http://www.w3.org/1999/xlink" diff --git a/res/icons/hicolor/24x24/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/24x24/apps/dev.edfloreshz.Orderly.svg similarity index 99% rename from res/icons/hicolor/24x24/apps/com.system76.CosmicTasks.svg rename to res/icons/hicolor/24x24/apps/dev.edfloreshz.Orderly.svg index 9d94bf5..1e15033 100644 --- a/res/icons/hicolor/24x24/apps/com.system76.CosmicTasks.svg +++ b/res/icons/hicolor/24x24/apps/dev.edfloreshz.Orderly.svg @@ -9,7 +9,7 @@ id="svg1" xml:space="preserve" inkscape:version="1.3.2 (091e20ef0f, 2023-11-25)" - sodipodi:docname="com.system76.CosmicTasks.svg" + sodipodi:docname="dev.edfloreshz.Orderly.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:xlink="http://www.w3.org/1999/xlink" diff --git a/res/icons/hicolor/256x256/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/256x256/apps/dev.edfloreshz.Orderly.svg similarity index 99% rename from res/icons/hicolor/256x256/apps/com.system76.CosmicTasks.svg rename to res/icons/hicolor/256x256/apps/dev.edfloreshz.Orderly.svg index 9d94bf5..1e15033 100644 --- a/res/icons/hicolor/256x256/apps/com.system76.CosmicTasks.svg +++ b/res/icons/hicolor/256x256/apps/dev.edfloreshz.Orderly.svg @@ -9,7 +9,7 @@ id="svg1" xml:space="preserve" inkscape:version="1.3.2 (091e20ef0f, 2023-11-25)" - sodipodi:docname="com.system76.CosmicTasks.svg" + sodipodi:docname="dev.edfloreshz.Orderly.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:xlink="http://www.w3.org/1999/xlink" diff --git a/res/icons/hicolor/32x32/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/32x32/apps/com.system76.CosmicTasks.svg deleted file mode 100644 index 9d94bf5..0000000 --- a/res/icons/hicolor/32x32/apps/com.system76.CosmicTasks.svg +++ /dev/null @@ -1,478 +0,0 @@ - - - - diff --git a/res/icons/hicolor/32x32/apps/dev.edfloreshz.Orderly.svg b/res/icons/hicolor/32x32/apps/dev.edfloreshz.Orderly.svg new file mode 100644 index 0000000..1e15033 --- /dev/null +++ b/res/icons/hicolor/32x32/apps/dev.edfloreshz.Orderly.svg @@ -0,0 +1,478 @@ + + + + diff --git a/res/icons/hicolor/48x48/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/48x48/apps/com.system76.CosmicTasks.svg deleted file mode 100644 index 9d94bf5..0000000 --- a/res/icons/hicolor/48x48/apps/com.system76.CosmicTasks.svg +++ /dev/null @@ -1,478 +0,0 @@ - - - - diff --git a/res/icons/hicolor/48x48/apps/dev.edfloreshz.Orderly.svg b/res/icons/hicolor/48x48/apps/dev.edfloreshz.Orderly.svg new file mode 100644 index 0000000..1e15033 --- /dev/null +++ b/res/icons/hicolor/48x48/apps/dev.edfloreshz.Orderly.svg @@ -0,0 +1,478 @@ + + + + diff --git a/res/icons/hicolor/64x64/apps/com.system76.CosmicTasks.svg b/res/icons/hicolor/64x64/apps/com.system76.CosmicTasks.svg deleted file mode 100644 index 9d94bf5..0000000 --- a/res/icons/hicolor/64x64/apps/com.system76.CosmicTasks.svg +++ /dev/null @@ -1,478 +0,0 @@ - - - - diff --git a/res/icons/hicolor/64x64/apps/dev.edfloreshz.Orderly.svg b/res/icons/hicolor/64x64/apps/dev.edfloreshz.Orderly.svg new file mode 100644 index 0000000..1e15033 --- /dev/null +++ b/res/icons/hicolor/64x64/apps/dev.edfloreshz.Orderly.svg @@ -0,0 +1,478 @@ + + + + diff --git a/src/app.rs b/src/app.rs index b6c8abb..fb3a23b 100644 --- a/src/app.rs +++ b/src/app.rs @@ -18,9 +18,9 @@ use cosmic::{ app, cosmic_config, cosmic_theme, executor, theme, widget, Application, ApplicationExt, Command, Element, }; -use cosmic_tasks_core::models::list::List; -use cosmic_tasks_core::models::task::Task; -use cosmic_tasks_core::service::{Provider, TaskService}; +use orderly_core::models::list::List; +use orderly_core::models::task::Task; +use orderly_core::service::{Provider, TaskService}; use crate::app::config::{AppTheme, CONFIG_VERSION}; use crate::app::key_bind::key_binds; @@ -36,14 +36,14 @@ pub mod markdown; pub mod menu; pub mod settings; -pub struct App { +pub struct Orderly { core: Core, service: TaskService, nav_model: segmented_button::SingleSelectModel, content: Content, details: Details, config_handler: Option, - config: config::CosmicTasksConfig, + config: config::OrderlyConfig, app_themes: Vec, context_page: ContextPage, key_binds: HashMap, @@ -112,7 +112,7 @@ pub enum DialogPage { #[derive(Clone, Debug)] pub struct Flags { pub config_handler: Option, - pub config: config::CosmicTasksConfig, + pub config: config::OrderlyConfig, } #[derive(Clone, Copy, Debug, Eq, PartialEq)] @@ -162,33 +162,38 @@ impl MenuAction for NavMenuAction { } } -impl App { +impl Orderly { fn update_config(&mut self) -> Command> { app::command::set_theme(self.config.app_theme.theme()) } fn about(&self) -> Element { let spacing = theme::active().cosmic().spacing; - let repository = "https://github.com/edfloreshz/cosmic-tasks"; + let repository = "https://github.com/edfloreshz/orderly"; let hash = env!("VERGEN_GIT_SHA"); let short_hash: String = hash.chars().take(7).collect(); let date = env!("VERGEN_GIT_COMMIT_DATE"); widget::column::with_children(vec![ widget::svg(widget::svg::Handle::from_memory( - &include_bytes!( - "../res/icons/hicolor/128x128/apps/com.system76.CosmicTasks.svg" - )[..], + &include_bytes!("../res/icons/hicolor/128x128/apps/dev.edfloreshz.Orderly.svg")[..], )) - .into(), - widget::text::title3(fl!("cosmic-tasks")).into(), + .into(), + widget::text::title3(fl!("orderly")).into(), widget::button::link(repository) .on_press(Message::LaunchUrl(repository.to_string())) .padding(spacing.space_none) .into(), - widget::button::link(fl!("git-description", hash = short_hash.as_str(), date = date)) - .on_press(Message::LaunchUrl(format!("{}/commits/{}", repository, hash))) - .padding(spacing.space_none) - .into(), + widget::button::link(fl!( + "git-description", + hash = short_hash.as_str(), + date = date + )) + .on_press(Message::LaunchUrl(format!( + "{}/commits/{}", + repository, hash + ))) + .padding(spacing.space_none) + .into(), ]) .align_items(Alignment::Center) .spacing(spacing.space_xxs) @@ -228,11 +233,11 @@ impl App { } } -impl Application for App { +impl Application for Orderly { type Executor = executor::Default; type Flags = Flags; type Message = Message; - const APP_ID: &'static str = "com.system76.CosmicTasks"; + const APP_ID: &'static str = "dev.edfloreshz.Orderly"; fn core(&self) -> &Core { &self.core @@ -246,7 +251,7 @@ impl Application for App { core.nav_bar_toggle_condensed(); let nav_model = segmented_button::ModelBuilder::default().build(); let service = TaskService::new(Self::APP_ID, Provider::Computer); - let app = App { + let app = Orderly { core, service: service.clone(), nav_model, @@ -466,7 +471,7 @@ impl Application for App { if let Some(list) = location_opt { let message = Message::Content(content::Message::List(Some(list.clone()))); - let window_title = format!("{} - {}", list.name, fl!("cosmic-tasks")); + let window_title = format!("{} - {}", list.name, fl!("orderly")); commands.push(self.set_window_title(window_title, self.main_window_id())); return self.update(message); } diff --git a/src/app/config.rs b/src/app/config.rs index 4f9a7fe..9778fe1 100644 --- a/src/app/config.rs +++ b/src/app/config.rs @@ -1,4 +1,4 @@ -use crate::app::App; +use crate::app::Orderly; use cosmic::{ cosmic_config::{self, cosmic_config_derive::CosmicConfigEntry, Config, CosmicConfigEntry}, theme, Application, @@ -8,27 +8,26 @@ use serde::{Deserialize, Serialize}; pub const CONFIG_VERSION: u64 = 1; #[derive(Clone, Default, Debug, Eq, PartialEq, Deserialize, Serialize, CosmicConfigEntry)] -pub struct CosmicTasksConfig { +pub struct OrderlyConfig { pub app_theme: AppTheme, } -impl CosmicTasksConfig { +impl OrderlyConfig { pub fn config_handler() -> Option { - Config::new(App::APP_ID, CONFIG_VERSION).ok() + Config::new(Orderly::APP_ID, CONFIG_VERSION).ok() } - pub fn config() -> CosmicTasksConfig { + pub fn config() -> OrderlyConfig { match Self::config_handler() { Some(config_handler) => { - let config = CosmicTasksConfig::get_entry(&config_handler).unwrap_or_else( - |(errs, config)| { + let config = + OrderlyConfig::get_entry(&config_handler).unwrap_or_else(|(errs, config)| { log::info!("errors loading config: {:?}", errs); config - }, - ); + }); config } - None => CosmicTasksConfig::default(), + None => OrderlyConfig::default(), } } } diff --git a/src/app/markdown.rs b/src/app/markdown.rs index f85a1c6..e41e6c2 100644 --- a/src/app/markdown.rs +++ b/src/app/markdown.rs @@ -1,6 +1,6 @@ -use cosmic_tasks_core::models::list::List; -use cosmic_tasks_core::models::status::Status; -use cosmic_tasks_core::models::task::Task; +use orderly_core::models::list::List; +use orderly_core::models::status::Status; +use orderly_core::models::task::Task; pub trait Markdown { fn markdown(&self) -> String; diff --git a/src/app/settings.rs b/src/app/settings.rs index f03ccd1..3bcd311 100644 --- a/src/app/settings.rs +++ b/src/app/settings.rs @@ -2,22 +2,25 @@ use crate::app::icon_cache::{IconCache, ICON_CACHE}; use crate::app::Flags; use cosmic::app::Settings; use cosmic::iced::{Limits, Size}; +use cosmic::Application; use std::sync::Mutex; -use super::config::CosmicTasksConfig; +use super::config::OrderlyConfig; use super::localize::set_localization; +use super::Orderly; pub fn init() -> (Settings, Flags) { set_localization(); set_icon_cache(); set_logger(); + migrate(); let settings = get_app_settings(); let flags = get_flags(); (settings, flags) } pub fn get_app_settings() -> Settings { - let config = CosmicTasksConfig::config(); + let config = OrderlyConfig::config(); let mut settings = Settings::default(); settings = settings.theme(config.app_theme.theme()); @@ -36,10 +39,7 @@ pub fn set_icon_cache() { } pub fn get_flags() -> Flags { - let (config_handler, config) = ( - CosmicTasksConfig::config_handler(), - CosmicTasksConfig::config(), - ); + let (config_handler, config) = (OrderlyConfig::config_handler(), OrderlyConfig::config()); let flags = Flags { config_handler, @@ -47,3 +47,15 @@ pub fn get_flags() -> Flags { }; flags } + +pub fn migrate() { + const PREV_APP_ID: &str = "com.system76.CosmicTasks"; + let prev = dirs::data_local_dir().unwrap().join(PREV_APP_ID); + let new = dirs::data_local_dir().unwrap().join(Orderly::APP_ID); + if prev.exists() { + match std::fs::rename(prev, new) { + Ok(_) => log::info!("migrated data to new directory"), + Err(err) => log::error!("error migrating data: {:?}", err), + } + } +} diff --git a/src/content.rs b/src/content.rs index cd75585..a09a83f 100644 --- a/src/content.rs +++ b/src/content.rs @@ -3,9 +3,9 @@ use cosmic::iced::alignment::{Horizontal, Vertical}; use cosmic::iced::{Alignment, Length, Subscription}; use cosmic::iced_widget::row; use cosmic::{theme, widget, Apply, Element}; -use cosmic_tasks_core::models::list::List; -use cosmic_tasks_core::models::status::Status; -use cosmic_tasks_core::models::task::Task; +use orderly_core::models::list::List; +use orderly_core::models::status::Status; +use orderly_core::models::task::Task; use slotmap::{DefaultKey, SecondaryMap, SlotMap}; use crate::fl; diff --git a/src/core/Cargo.toml b/src/core/Cargo.toml index 611a93a..9d61b8d 100644 --- a/src/core/Cargo.toml +++ b/src/core/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "cosmic-tasks-core" +name = "orderly-core" version = "0.1.0" edition = "2021" diff --git a/src/details.rs b/src/details.rs index 851a481..9d73646 100644 --- a/src/details.rs +++ b/src/details.rs @@ -5,9 +5,9 @@ use cosmic::iced_widget::row; use cosmic::widget::segmented_button; use cosmic::widget::segmented_button::Entity; use cosmic::{theme, widget, Element}; -use cosmic_tasks_core::models::priority::Priority; -use cosmic_tasks_core::models::status::Status; -use cosmic_tasks_core::models::task::Task; +use orderly_core::models::priority::Priority; +use orderly_core::models::status::Status; +use orderly_core::models::task::Task; use slotmap::{DefaultKey, SecondaryMap, SlotMap}; use crate::fl; diff --git a/src/main.rs b/src/main.rs index 3e27070..135e127 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,7 +1,7 @@ // Copyright 2023 System76 // SPDX-License-Identifier: GPL-3.0-only -use crate::app::App; +use crate::app::Orderly; mod app; mod content; mod details; @@ -10,6 +10,6 @@ mod todo; #[rustfmt::skip] pub fn main() -> Result<(), Box> { let (settings, flags) = app::settings::init(); - cosmic::app::run::(settings, flags)?; + cosmic::app::run::(settings, flags)?; Ok(()) } diff --git a/src/todo.rs b/src/todo.rs index d5e8c4b..3e12b7f 100644 --- a/src/todo.rs +++ b/src/todo.rs @@ -1,7 +1,7 @@ use crate::app::markdown::Markdown; -use cosmic_tasks_core::models::list::List; -use cosmic_tasks_core::models::task::Task; -use cosmic_tasks_core::service::TaskService; +use orderly_core::models::list::List; +use orderly_core::models::task::Task; +use orderly_core::service::TaskService; use std::error::Error; pub async fn update_list(list: List, service: TaskService) -> Result<(), Box> {