diff --git a/hosts/vali/hermit/configuration.nix b/hosts/vali/hermit/configuration.nix
index 5c4a096..8a0dc9b 100644
--- a/hosts/vali/hermit/configuration.nix
+++ b/hosts/vali/hermit/configuration.nix
@@ -74,6 +74,7 @@
nh.enable = true;
wtfutil.enable = true;
waybar.enable = true;
+ beets.enable = true;
spicetify.enable = true;
schizofox.enable = true;
anyrun.enable = true;
diff --git a/modules/cli/beets.nix b/modules/cli/beets.nix
new file mode 100644
index 0000000..ffb70fc
--- /dev/null
+++ b/modules/cli/beets.nix
@@ -0,0 +1,79 @@
+{
+ config,
+ lib,
+ ...
+}: let
+ cfg = config.modules.programs.beets;
+ inherit (lib) mkIf mkEnableOption;
+ inherit (config.modules.other.system) username;
+ inherit (config.modules.services.mpd) musicDirectory;
+in {
+ options.modules.programs.beets.enable = mkEnableOption "beets";
+ config = mkIf cfg.enable {
+ home-manager.users.${username} = {
+ programs.beets = {
+ enable = true;
+
+ settings = {
+ ui.color = true;
+ directory = musicDirectory;
+ library = "${musicDirectory}/musiclibrary.db";
+
+ clutter = [
+ "Thumbs.DB"
+ ".DS_Store"
+ ".directory"
+ ];
+
+ plugins = [
+ # "acousticbrainz" # DEPRECATED
+ "mpdupdate"
+ "lyrics"
+ "thumbnails"
+ "fetchart"
+ "embedart"
+ "chroma"
+ "fromfilename"
+ "lastgenre"
+ #"absubmit" # DEPRECATED
+ "duplicates"
+ "edit"
+ #"mbcollection" # not set up yet
+ # "mbsync"
+ "replaygain"
+ "scrub"
+ ];
+
+ import = {
+ move = true;
+ timid = true;
+ detail = true;
+ bell = true;
+ write = true;
+ };
+
+ mpd = {
+ host = "localhost";
+ port = 6600;
+ };
+
+ lyrics = {
+ auto = true;
+ };
+
+ thumbnails.auto = true;
+ fetchart.auto = true;
+
+ embedart = {
+ auto = true;
+ remove_art_file = true;
+ };
+
+ acousticbrainz.auto = true;
+ chroma.auto = true;
+ replaygain.backend = "gstreamer";
+ };
+ };
+ };
+ };
+}
diff --git a/modules/cli/default.nix b/modules/cli/default.nix
index e8000c8..3a7345d 100644
--- a/modules/cli/default.nix
+++ b/modules/cli/default.nix
@@ -1 +1 @@
-_: {imports = [./fish.nix ./nh.nix ./starship.nix];}
+_: {imports = [./fish.nix ./nh.nix ./starship.nix ./beets.nix];}
diff --git a/modules/editors/nvf/plugins/settings/utility.nix b/modules/editors/nvf/plugins/settings/utility.nix
index 4d51fbd..bb619ee 100644
--- a/modules/editors/nvf/plugins/settings/utility.nix
+++ b/modules/editors/nvf/plugins/settings/utility.nix
@@ -15,10 +15,10 @@
# leap.enable = false;
# };
#
- # preview = {
- # glow.enable = true;
- # markdownPreview.enable = true;
- # };
+ preview = {
+ glow.enable = true;
+ markdownPreview.enable = true;
+ };
};
};
}
diff --git a/modules/editors/nvf/plugins/settings/visuals.nix b/modules/editors/nvf/plugins/settings/visuals.nix
index 2635023..65bec2d 100644
--- a/modules/editors/nvf/plugins/settings/visuals.nix
+++ b/modules/editors/nvf/plugins/settings/visuals.nix
@@ -1,13 +1,11 @@
-{config, ...}: let
- inherit (config.modules.other.system) username;
-in {
+_: {
programs.neovim-flake.settings.vim = {
visuals = {
enable = true;
nvimWebDevicons.enable = true;
scrollBar.enable = false;
smoothScroll.enable = false;
- cellularAutomaton.enable = false;
+ cellularAutomaton.enable = true;
highlight-undo.enable = true;
indentBlankline = {
diff --git a/modules/gui/default.nix b/modules/gui/default.nix
index d693f49..cfbe3da 100644
--- a/modules/gui/default.nix
+++ b/modules/gui/default.nix
@@ -14,7 +14,7 @@ _: {
#./vivado.nix
./steam.nix
./waybar.nix
- ./schizofox.nix
+ ./schizofox
./minecraft.nix
# ./emacs
];
diff --git a/modules/gui/foot.nix b/modules/gui/foot.nix
index 40e51de..b45efd4 100644
--- a/modules/gui/foot.nix
+++ b/modules/gui/foot.nix
@@ -69,7 +69,7 @@ in {
};
cursor = {
style = "block";
- blink = "true";
+ blink = "false";
};
mouse = {
hide-when-typing = "yes";
diff --git a/modules/gui/schizofox/default.nix b/modules/gui/schizofox/default.nix
new file mode 100644
index 0000000..19a352d
--- /dev/null
+++ b/modules/gui/schizofox/default.nix
@@ -0,0 +1,146 @@
+{
+ config,
+ inputs,
+ lib,
+ ...
+}: let
+ cfg = config.modules.programs.schizofox;
+ inherit (config.modules.other.system) username;
+
+ inherit (lib) mkEnableOption mkIf;
+in {
+ options.modules.programs.schizofox = {enable = mkEnableOption "schizofox";};
+
+ config = mkIf cfg.enable {
+ home-manager.users.${username} = {
+ imports = [inputs.schizofox.homeManagerModule];
+
+ programs.schizofox = {
+ enable = true;
+ theme = {
+ # colors = {
+ # background-darker = "181825";
+ # background = "1e1e2e";
+ # foreground = "cdd6f4";
+ # };
+ colors = {
+ background-darker = "1d2021";
+ background = "282828";
+ foreground = "ebdbb2";
+ };
+
+ font = "Lexend";
+ extraUserChrome = ''
+ body {
+ color: red !important;
+ }
+ '';
+ };
+ search = {
+ defaultSearchEngine = "DuckDuckGo";
+ removeEngines = ["Google" "Bing" "Amazon.com" "eBay" "Twitter" "Wikipedia"];
+ addEngines = [
+ {
+ Name = "NixOS Packages";
+ Description = "NixOS Unstable package search";
+ Alias = "!np";
+ Method = "GET";
+ URLTemplate = "https://search.nixos.org/packages?channel=unstable&query={searchTerms}";
+ }
+ {
+ Name = "NixOS Options";
+ Description = "NixOS Unstable option search";
+ Alias = "!no";
+ Method = "GET";
+ URLTemplate = "https://search.nixos.org/options?channel=unstable&query={searchTerms}";
+ }
+ {
+ Name = "NixOS Wiki";
+ Description = "NixOS Wiki search";
+ Alias = "!nw";
+ Method = "GET";
+ URLTemplate = "https://nixos.wiki/index.php?search={searchTerms}";
+ }
+ {
+ Name = "Home Manager Options";
+ Description = "Home Manager option search";
+ Alias = "!hm";
+ Method = "GET";
+ URLTemplate = "https://home-manager-options.extranix.com/?query={searchTerms}&release=master";
+ }
+ {
+ Name = "Arch Wiki";
+ Description = "Arch Wiki search";
+ Alias = "!aw";
+ Method = "GET";
+ URLTemplate = "https://wiki.archlinux.org/index.php?search={searchTerms}";
+ }
+ {
+ Name = "Gentoo Wiki";
+ Description = "Gentoo Wiki search";
+ Alias = "!gw";
+ Method = "GET";
+ URLTemplate = "https://wiki.gentoo.org/index.php?search={searchTerms}";
+ }
+ {
+ Name = "Debian Wiki";
+ Description = "Debian Wiki search";
+ Alias = "!dw";
+ Method = "GET";
+ URLTemplate = "https://wiki.debian.org/FrontPage?action=fullsearch&value={searchTerms}";
+ }
+ {
+ Name = "noogle";
+ Descriptiom = "Noogle Search";
+ Alias = "!no";
+ Method = "GET";
+ URLTemplate = "https://noogle.dev/";
+ }
+ ];
+ };
+ extensions = {
+ simplefox.enable = true;
+ darkreader.enable = true;
+ extraExtensions = let
+ mkUrl = name: "https://addons.mozilla.org/firefox/downloads/latest/${name}/latest.xpi";
+ extensions = [
+ {
+ id = "1018e4d6-728f-4b20-ad56-37578a4de76";
+ name = "flagfox";
+ }
+ {
+ id = "{c2c003ee-bd69-42a2-b0e9-6f34222cb046}";
+ name = "auto-tab-discard";
+ }
+ {
+ id = "{a4c4eda4-fb84-4a84-b4a1-f7c1cbf2a1ad}";
+ name = "refined-github-";
+ }
+ {
+ id = "sponsorBlocker@ajay.app";
+ name = "sponsorblock";
+ }
+ {
+ id = "uBlock0@raymondhill.net";
+ name = "UBlock Origin";
+ }
+ ];
+ extraExtensions = builtins.foldl' (acc: ext: acc // {ext.id = {install_url = mkUrl ext.name;};}) {} extensions;
+ in
+ extraExtensions;
+ };
+ security = {
+ sanitizeOnShutdown = false;
+ sandbox = true;
+ userAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:106.0) Gecko/20100101 Firefox/106.0";
+ };
+
+ misc = {
+ drm.enable = true;
+ disableWebgl = true;
+ #startPageURL = "file://${./src}/index.html";
+ };
+ };
+ };
+ };
+}
diff --git a/modules/gui/schizofox/package.nix b/modules/gui/schizofox/package.nix
new file mode 100644
index 0000000..681e1cc
--- /dev/null
+++ b/modules/gui/schizofox/package.nix
@@ -0,0 +1,26 @@
+# Stolen from Raf, kinda
+{
+ lib,
+ stdenvNoCC,
+}: let
+ name = "schizofox-startpage";
+ version = "2023-12-29-unstable";
+in
+ stdenvNoCC.mkDerivation {
+ inherit name version;
+ src = ./src;
+
+ dontBuild = true;
+ installPhase = ''
+ runHook preInstall
+ mkdir -p $out
+ cp -rv $src/* $out
+ runHook postInstall
+ '';
+
+ meta = {
+ description = "My personal startpage";
+ license = lib.licenses.gpl3Only;
+ maintainers = with lib.maintainers; [NotAShelf];
+ };
+ }
diff --git a/modules/gui/schizofox/src/.eslintrc.js b/modules/gui/schizofox/src/.eslintrc.js
new file mode 100644
index 0000000..a2bb9b1
--- /dev/null
+++ b/modules/gui/schizofox/src/.eslintrc.js
@@ -0,0 +1,17 @@
+module.exports = {
+ env: {
+ es2021: true,
+ },
+ extends: "eslint:recommended",
+ overrides: [],
+ parserOptions: {
+ ecmaVersion: "latest",
+ sourceType: "module",
+ },
+ rules: {
+ indent: ["error", 4],
+ "linebreak-style": ["error", "unix"],
+ quotes: ["error", "double"],
+ semi: ["error", "always"],
+ },
+};
diff --git a/modules/gui/schizofox/src/assets/blossom.png b/modules/gui/schizofox/src/assets/blossom.png
new file mode 100644
index 0000000..2559b86
Binary files /dev/null and b/modules/gui/schizofox/src/assets/blossom.png differ
diff --git a/modules/gui/schizofox/src/assets/desperation.png b/modules/gui/schizofox/src/assets/desperation.png
new file mode 100644
index 0000000..55b4625
Binary files /dev/null and b/modules/gui/schizofox/src/assets/desperation.png differ
diff --git a/modules/gui/schizofox/src/assets/flowerprint.png b/modules/gui/schizofox/src/assets/flowerprint.png
new file mode 100644
index 0000000..75a1667
Binary files /dev/null and b/modules/gui/schizofox/src/assets/flowerprint.png differ
diff --git a/modules/gui/schizofox/src/assets/flowers.png b/modules/gui/schizofox/src/assets/flowers.png
new file mode 100644
index 0000000..c359229
Binary files /dev/null and b/modules/gui/schizofox/src/assets/flowers.png differ
diff --git a/modules/gui/schizofox/src/assets/logs.png b/modules/gui/schizofox/src/assets/logs.png
new file mode 100644
index 0000000..ba0251b
Binary files /dev/null and b/modules/gui/schizofox/src/assets/logs.png differ
diff --git a/modules/gui/schizofox/src/assets/malachite.png b/modules/gui/schizofox/src/assets/malachite.png
new file mode 100644
index 0000000..f1c20f3
Binary files /dev/null and b/modules/gui/schizofox/src/assets/malachite.png differ
diff --git a/modules/gui/schizofox/src/assets/planet.png b/modules/gui/schizofox/src/assets/planet.png
new file mode 100644
index 0000000..deb03ce
Binary files /dev/null and b/modules/gui/schizofox/src/assets/planet.png differ
diff --git a/modules/gui/schizofox/src/assets/sway.png b/modules/gui/schizofox/src/assets/sway.png
new file mode 100644
index 0000000..a7f1d50
Binary files /dev/null and b/modules/gui/schizofox/src/assets/sway.png differ
diff --git a/modules/gui/schizofox/src/index.html b/modules/gui/schizofox/src/index.html
new file mode 100644
index 0000000..78591e5
--- /dev/null
+++ b/modules/gui/schizofox/src/index.html
@@ -0,0 +1,88 @@
+
+
+
+
+ Startpage
+
+
+
+
notashelf@nyx ~ $ > ls
+
+
+
+
+
+
+
+
diff --git a/modules/gui/schizofox/src/search.js b/modules/gui/schizofox/src/search.js
new file mode 100644
index 0000000..f89dfac
--- /dev/null
+++ b/modules/gui/schizofox/src/search.js
@@ -0,0 +1,78 @@
+String.prototype.replaceChars = function (character, replacement) {
+ return this.split(character).join(replacement);
+};
+
+function search(query) {
+ const searchPrefix = query.substring(0, 2);
+ query = query.substring(3);
+
+ switch (searchPrefix) {
+ case "-a":
+ window.location = `http://www.amazon.com/s/ref=nb_sb_noss_1?url=search-alias%3Daps&field-keywords=${query.replaceChars(
+ " ",
+ "+",
+ )}`;
+ break;
+
+ case "-y":
+ window.location = `https://www.youtube.com/results?search_query=${query.replaceChars(
+ " ",
+ "+",
+ )}`;
+ break;
+
+ case "-w":
+ window.location = `https://en.wikipedia.org/w/index.php?search=${query.replaceChars(
+ " ",
+ "%20",
+ )}`;
+ break;
+
+ case "-m":
+ window.location = `http://www.wolframalpha.com/input/?i=${query.replaceChars(
+ "+",
+ "%2B",
+ )}`;
+ break;
+
+ case "-h":
+ window.location = `http://alpha.wallhaven.cc/search?q=${query}&categories=111&purity=100&resolutions=1920x1080&sorting=relevance&order=desc`;
+ break;
+
+ default:
+ window.location = `https://search.notashelf.dev/search?q=${query.replaceChars(
+ " ",
+ "+",
+ )}&categories=general`;
+ }
+}
+
+window.onload = function () {
+ const searchInput = document.getElementById("searchbox");
+ if (searchInput) {
+ searchInput.addEventListener("keypress", function (event) {
+ if (event.keyCode === 13) {
+ search(this.value);
+ }
+ });
+ }
+};
+
+//
+// To add a new search provider, paste the following between the last "break;" and "default:" (Line 39 & 40)
+//
+// case "-a":
+// query = query.substr(3);
+// window.location =
+// "https://en.website.com/" +
+// query.replaceChars(" ", "%20");
+// break;
+//
+// -a on ln68 should be replaced with a "-letter" of your choice. You can also change it to !a, .a, /a etc.
+// https://en.website.com/ on ln70 should be replaced with the search page of the website. To find this, make a few searches on your website.
+//Try to identify where your search is in the URL. If you're not sure, post in the thread and someone should help you out
+//
+// You can use the above two to modify an existing rule
+//
+// If you wish to change the number of characters in a "case", you need to change the line below, changing query.substr() to n+1, n being the number of characters.
+// This ensures that when you search for something, the whole of your idenfier and the space between the identifier and query are removed.
diff --git a/modules/gui/schizofox/src/style.css b/modules/gui/schizofox/src/style.css
new file mode 100644
index 0000000..77e344d
--- /dev/null
+++ b/modules/gui/schizofox/src/style.css
@@ -0,0 +1,130 @@
+body {
+ background-color: #11111b;
+ color: #cdd6f4;
+}
+
+#Title {
+ font-family: "Malgun Gothic";
+ text-align: center;
+ color: #cdd6f4;
+ margin-top: 75px;
+}
+
+#searchbox {
+ width: 500;
+ height: 4%;
+ border: none;
+ border-radius: 2px;
+ outline: none;
+ padding-left: 15px;
+ text-align: left;
+ background-color: #1e1e2e;
+ color: #cdd6f4;
+ font-size: 15px;
+ font-family: "Malgun Gothic", sans-serif;
+ display: block;
+ margin: auto;
+ margin-top: 50px;
+}
+
+#stripe {
+ width: 100%;
+ vertical-align: middle;
+}
+
+#mainframe {
+ text-align: center;
+ position: absolute;
+ top: 25%;
+ left: 16%;
+ right: 11%;
+}
+
+#footer {
+ position: absolute;
+ bottom: 0;
+ right: 0;
+ text-align: right;
+ padding: 10px;
+ font-size: 30%;
+}
+
+#linkblock {
+ width: 20%;
+ height: 140px;
+ margin-left: 25px;
+ margin-right: 30px;
+ margin-top: 30px;
+ margin-bottom: 40px;
+ padding-left: 67px;
+ padding-right: 1px;
+ padding-top: 0px;
+ padding-bottom: 5px;
+ color: #cdd6f4;
+ text-align: left;
+ background-position: top 0px left 0px;
+ background-repeat: no-repeat;
+ font-family: "Malgun Gothic";
+ font-size: 100%;
+ display: inline-block;
+ vertical-align: top;
+ border-left: 3px solid #181825;
+ transition: 0.5s;
+}
+
+ul {
+ list-style-type: none;
+ padding-left: 0;
+}
+
+a:link {
+ text-decoration: none;
+ font-weight: normal;
+ color: #89b4fa;
+}
+a:visited {
+ text-decoration: none;
+ font-weight: normal;
+ color: #89b4fa;
+}
+a:hover {
+ text-decoration: none;
+ font-weight: normal;
+ color: #b4befe;
+}
+a:active {
+ text-decoration: none;
+ font-weight: normal;
+ color: #89b4fa;
+}
+a:focus {
+ text-decoration: none;
+ font-weight: normal;
+ color: #89b4fa;
+}
+
+#footer a:link {
+ text-decoration: none;
+ font-weight: normal;
+ color: #101010;
+}
+#footer a:visited {
+ text-decoration: none;
+ font-weight: normal;
+ color: #101010;
+}
+#footer a:hover {
+ text-decoration: none;
+ font-weight: normal;
+ color: #101010;
+}
+#footer a:active {
+ text-decoration: none;
+ font-weight: normal;
+ color: #101010;
+}
+#footer a:focus {
+ text-decoration: none;
+ font-weight: normal;
+ color: #101010;
+}
diff --git a/modules/services/mpd.nix b/modules/services/mpd.nix
index 31c461a..b4955c9 100644
--- a/modules/services/mpd.nix
+++ b/modules/services/mpd.nix
@@ -28,10 +28,10 @@ in {
user = username;
extraConfig = ''
user "${username}"
+ playlist_directory "${cfg.musicDirectory}/.playlists"
restore_paused "yes"
- follow_outside_symlinks "yes"
- follow_inside_symlinks "yes"
+ volume_normalization "yes"
audio_output {
type "pipewire"
diff --git a/modules/services/pipewire.nix b/modules/services/pipewire.nix
index 918de1c..0219222 100644
--- a/modules/services/pipewire.nix
+++ b/modules/services/pipewire.nix
@@ -12,7 +12,7 @@ in {
hardware.pulseaudio.enable = false;
services.pipewire = {
enable = true;
- alsa.enable = true;
+ alsa.enable = true; # TODO Do I need this?
pulse.enable = true;
};
security.rtkit.enable = true;
diff --git a/modules/tui/ncmpcpp.nix b/modules/tui/ncmpcpp.nix
index ad89f41..38ec9e0 100644
--- a/modules/tui/ncmpcpp.nix
+++ b/modules/tui/ncmpcpp.nix
@@ -13,12 +13,91 @@ in {
config = mkIf cfg.enable {
home-manager.users.${username} = {
- #xdg.configFile."ncmpcpp/config".source = ./config;
programs.ncmpcpp = {
enable = true;
package = pkgs.ncmpcpp.override {visualizerSupport = true;};
mpdMusicDir = "${musicDirectory}";
+
+ bindings = [
+ {
+ key = "j";
+ command = "scroll_down";
+ }
+ {
+ key = "k";
+ command = "scroll_up";
+ }
+ {
+ key = "J";
+ command = ["select_item" "scroll_down"];
+ }
+ {
+ key = "K";
+ command = ["select_item" "scroll_up"];
+ }
+ ];
settings = {
+ # Miscelaneous
+ ignore_leading_the = true;
+ external_editor = "nvim";
+ message_delay_time = 1;
+ playlist_disable_highlight_delay = 2;
+ autocenter_mode = "yes";
+ centered_cursor = "yes";
+ allow_for_physical_item_deletion = "no";
+ lines_scrolled = "0";
+ follow_now_playing_lyrics = "yes";
+ lyrics_fetchers = "musixmatch";
+ connected_message_on_startup = "no";
+ mouse_support = "yes";
+
+ # visualizer
+ visualizer_data_source = "/tmp/mpd.fifo";
+ visualizer_output_name = "mpd_visualizer";
+ visualizer_type = "ellipse";
+ visualizer_look = "●● ";
+ visualizer_color = "blue, green";
+
+ # appearance
+ colors_enabled = "yes";
+ browser_playlist_prefix = "$2 ♥ $5 ";
+ playlist_display_mode = "classic";
+ user_interface = "classic";
+ volume_color = "white";
+
+ # window
+ song_window_title_format = "Music";
+ statusbar_visibility = "no";
+ header_visibility = "no";
+ titles_visibility = "no";
+
+ # progress bar
+ progressbar_look = "━━━";
+ progressbar_color = "black";
+ progressbar_elapsed_color = "blue";
+
+ # song list
+ song_status_format = "$7%t";
+ song_list_format = "$(008)%t$R $(247)%a$R$5 %l$8";
+ song_columns_list_format = "(53)[blue]{tr} (45)[blue]{a}";
+
+ current_item_prefix = "$b$2| ";
+ current_item_suffix = "$/b$5";
+
+ now_playing_prefix = "$b$5| ";
+ now_playing_suffix = "$/b$5";
+
+ song_library_format = "{{%a - %t} (%b)}|{%f}";
+
+ # colors
+ main_window_color = "blue";
+
+ current_item_inactive_column_prefix = "$b$5";
+ current_item_inactive_column_suffix = "$/b$5";
+
+ color1 = "white";
+ color2 = "blue";
+ /*
alternative_header_first_line_format = "$5{$b%t$/b}$9";
alternative_header_second_line_format = "$3by $7{$b%a$/b}$9 $3from $7{$b%b$/b}$9 $5{(%y)}";
song_list_format = "♫ $2%n$(end) $9 $3%a$(end) $(245)-$9 $(246)%t$9 $R{ $5%y$9}$(end) $(246)%lq$(end)";
@@ -77,6 +156,7 @@ in {
visualizer_data_source = "/tmp/mpd.fifo";
visualizer_type = "wave_filled";
visualizer_look = "▉▋";
+ */
};
};
};
diff --git a/modules/tui/yazi.nix b/modules/tui/yazi.nix
index 4faaa65..ca35d84 100644
--- a/modules/tui/yazi.nix
+++ b/modules/tui/yazi.nix
@@ -5,7 +5,7 @@
}:
with lib; let
cfg = config.modules.programs.yazi;
- username = config.modules.other.system.username;
+ inherit (config.modules.other.system) username;
in {
options.modules.programs.yazi = {enable = mkEnableOption "yazi";};