From 2a2a22f72c3141866a1660efae27e38b22d9ea03 Mon Sep 17 00:00:00 2001 From: vikingowl Date: Mon, 29 Dec 2025 16:56:49 +0100 Subject: [PATCH] refactor: restructure project directories to follow FHS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Move themes/ → data/themes/ (installable to /usr/share/owlry/themes/) - Move resources/ → src/resources/ (embedded into binary) - Move config.example.toml → data/ (installable to /usr/share/doc/owlry/) - Update include_str! paths in app.rs New structure follows Filesystem Hierarchy Standard: - data/ → files installed to /usr/share/ - src/resources → embedded resources compiled into binary 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- config.example.toml => data/config.example.toml | 0 {themes => data/themes}/catppuccin-mocha.css | 0 {themes => data/themes}/dracula.css | 0 {themes => data/themes}/gruvbox-dark.css | 0 {themes => data/themes}/nord.css | 0 {themes => data/themes}/one-dark.css | 0 {themes => data/themes}/owl.css | 0 {themes => data/themes}/rose-pine.css | 0 {themes => data/themes}/solarized-dark.css | 0 {themes => data/themes}/tokyo-night.css | 0 src/app.rs | 4 ++-- {resources => src/resources}/base.css | 0 {resources => src/resources}/owl-theme.css | 0 13 files changed, 2 insertions(+), 2 deletions(-) rename config.example.toml => data/config.example.toml (100%) rename {themes => data/themes}/catppuccin-mocha.css (100%) rename {themes => data/themes}/dracula.css (100%) rename {themes => data/themes}/gruvbox-dark.css (100%) rename {themes => data/themes}/nord.css (100%) rename {themes => data/themes}/one-dark.css (100%) rename {themes => data/themes}/owl.css (100%) rename {themes => data/themes}/rose-pine.css (100%) rename {themes => data/themes}/solarized-dark.css (100%) rename {themes => data/themes}/tokyo-night.css (100%) rename {resources => src/resources}/base.css (100%) rename {resources => src/resources}/owl-theme.css (100%) diff --git a/config.example.toml b/data/config.example.toml similarity index 100% rename from config.example.toml rename to data/config.example.toml diff --git a/themes/catppuccin-mocha.css b/data/themes/catppuccin-mocha.css similarity index 100% rename from themes/catppuccin-mocha.css rename to data/themes/catppuccin-mocha.css diff --git a/themes/dracula.css b/data/themes/dracula.css similarity index 100% rename from themes/dracula.css rename to data/themes/dracula.css diff --git a/themes/gruvbox-dark.css b/data/themes/gruvbox-dark.css similarity index 100% rename from themes/gruvbox-dark.css rename to data/themes/gruvbox-dark.css diff --git a/themes/nord.css b/data/themes/nord.css similarity index 100% rename from themes/nord.css rename to data/themes/nord.css diff --git a/themes/one-dark.css b/data/themes/one-dark.css similarity index 100% rename from themes/one-dark.css rename to data/themes/one-dark.css diff --git a/themes/owl.css b/data/themes/owl.css similarity index 100% rename from themes/owl.css rename to data/themes/owl.css diff --git a/themes/rose-pine.css b/data/themes/rose-pine.css similarity index 100% rename from themes/rose-pine.css rename to data/themes/rose-pine.css diff --git a/themes/solarized-dark.css b/data/themes/solarized-dark.css similarity index 100% rename from themes/solarized-dark.css rename to data/themes/solarized-dark.css diff --git a/themes/tokyo-night.css b/data/themes/tokyo-night.css similarity index 100% rename from themes/tokyo-night.css rename to data/themes/tokyo-night.css diff --git a/src/app.rs b/src/app.rs index 202b3f7..f575a9f 100644 --- a/src/app.rs +++ b/src/app.rs @@ -82,7 +82,7 @@ impl OwlryApp { // 1. Load base structural CSS (always applied) let base_provider = CssProvider::new(); - base_provider.load_from_string(include_str!("../resources/base.css")); + base_provider.load_from_string(include_str!("resources/base.css")); gtk4::style_context_add_provider_for_display( &display, &base_provider, @@ -95,7 +95,7 @@ impl OwlryApp { let theme_provider = CssProvider::new(); match theme_name.as_str() { "owl" => { - theme_provider.load_from_string(include_str!("../resources/owl-theme.css")); + theme_provider.load_from_string(include_str!("resources/owl-theme.css")); debug!("Loaded built-in owl theme"); } _ => { diff --git a/resources/base.css b/src/resources/base.css similarity index 100% rename from resources/base.css rename to src/resources/base.css diff --git a/resources/owl-theme.css b/src/resources/owl-theme.css similarity index 100% rename from resources/owl-theme.css rename to src/resources/owl-theme.css