Compare commits

..
173 Commits
Author SHA1 Message Date
Carmine PaolinoandGitHub 9cf1852525 Use dua for disk usage (#6052) 2026-06-08 16:36:05 +02:00
Jason ZimdarsandGitHub 8075b8b0dc Update Basecamp logo asset for version 5 release (#5769)
* Update Basecamp logo asset for version 5 release

* Final Basecamp 5 logo asset
2026-05-25 23:36:54 +02:00
961d4241f0 Install mpv MPRIS support (#5937)
* Install mpv MPRIS support

* omarchy-pkg-add already checks if installed

---------

Co-authored-by: David Heinemeier Hansson <david@hey.com>
2026-05-23 20:49:00 +02:00
Pavel KaderaandGitHub b911a6f8ba Only bind F9 to Voxtype if installed (#5882) (#5897) 2026-05-21 06:48:20 +02:00
ed93a047ee Fix power profile race on plug/unplug events (#5898)
The udev power_supply rule fires before sysfs `online` is updated on
some laptops (notably Lenovo Yoga Pro 7 14IAH10 with USB-C charging).
The autodetect branch reads the stale value and sets the wrong profile,
so the system stays on `performance` after unplug (or vice versa).

A single plug/unplug typically fires 3-4 udev events within ~1s (ACAD +
each USB-C port). With `systemd-run --unit=omarchy-power-profile
--collect`, duplicate invocations against the same unit name can be
dropped while the first is still running, so the surviving event isn't
guaranteed to be the latest one.

This adds a 0.3s settle delay at the top of the autodetect branch only.
Explicit `ac` and `battery` invocations remain instant.

Tested on Lenovo Yoga Pro 7 14IAH10 (Intel Core Ultra 9 285H, Omarchy
3.8.1).

Co-authored-by: Iqbal Attila <iqbal@kcmon.id>
2026-05-19 09:42:13 +02:00
Axel FontaineandGitHub df82125953 Enable Docker multi-arch builds by default (#5901)
* Enable Docker multi-arch image building

* Added migration for Docker multi-arch image building
2026-05-19 09:40:54 +02:00
David Heinemeier Hansson c0c480b24f npm 2026-05-17 09:42:02 +02:00
David Heinemeier Hansson 54abdbaadc It's npm, not npx 2026-05-17 09:41:25 +02:00
ManuelandGitHub 8c506b30a9 Fix gradient border syntax in last-horizon and solitude themes (#5869) 2026-05-16 14:31:43 +02:00
David Heinemeier Hansson 8610312db3 Quiet the rule adding 2026-05-16 13:00:30 +02:00
David Heinemeier Hansson e4d9d0d297 Explain to the agents how to remove a package 2026-05-16 13:00:03 +02:00
David Heinemeier Hansson fcde1057ee Make sure foot responds to all the conventional copy/paste keybindings 2026-05-16 12:59:43 +02:00
AbdullohandGitHub adeba8aa95 Convert last-horizon and solitude themes from hyprlang to Lua (#5867) 2026-05-16 09:37:15 +02:00
David Heinemeier Hansson 3d3c77f53d Fix the gum coloring 2026-05-15 18:03:21 +02:00
David Heinemeier Hansson 05fee802fc Don't remove wtype 2026-05-15 17:58:31 +02:00
David Heinemeier Hansson 0bfb545033 Ensure the service is fully removed
Closes #5788
2026-05-15 17:57:44 +02:00
David Heinemeier HanssonandGitHub c0275ea9f2 Foot as the default terminal (#5831)
* Bind maps too

* Make foot the default terminal
2026-05-15 17:44:09 +02:00
David Heinemeier Hansson e72b8a6dbd Skip the certificate errors 2026-05-15 17:39:32 +02:00
David Heinemeier Hansson 612dead716 Make sure we setup autostart as well 2026-05-15 17:03:39 +02:00
David Heinemeier Hansson 2d5e3cefe0 Install Sunshine Admin app as well 2026-05-15 16:59:52 +02:00
David Heinemeier Hansson b486a43985 Add sunshine service installation 2026-05-15 16:24:21 +02:00
David Heinemeier Hansson e2938ae952 Performance improvements 2026-05-15 16:24:21 +02:00
David Heinemeier Hansson 43134875b5 Ensure that $BROWSER runs omarchy-launch-browser and doesn't hand ownership to parent process
This prevents gh auth login from working without an existing open
browser
2026-05-15 16:07:35 +02:00
David Heinemeier Hansson daf301c416 Don't ask to restart multiple times 2026-05-15 15:21:03 +02:00
David Heinemeier Hansson a4635f7657 Make o available without error 2026-05-15 14:44:50 +02:00
David Heinemeier Hansson 4146600f5c Refresh the theme 2026-05-15 14:18:57 +02:00
David Heinemeier Hansson 51d998bee0 Need exclusive placement 2026-05-15 14:14:16 +02:00
David Heinemeier Hansson 95b0bfed4d Ensure that the old style is always run 2026-05-15 14:12:12 +02:00
David Heinemeier Hansson 7e99e3eff0 Ensure toggles are refreshed when doing omarcy-refresh-hyprland 2026-05-15 14:02:12 +02:00
David Heinemeier Hansson 47cd93143a Explain reasoning 2026-05-15 13:57:01 +02:00
David Heinemeier Hansson 8d107ed04c Drop outdated migrations 2026-05-15 13:56:15 +02:00
David Heinemeier Hansson 719b7df91a No longer has its own flags 2026-05-15 13:55:45 +02:00
David Heinemeier Hansson 870fe16b0a Add Alt+esc to close a pane too 2026-05-15 13:39:17 +02:00
David Heinemeier Hansson 2f56b525c6 Simpler additional tmux splits 2026-05-15 13:37:53 +02:00
David Heinemeier Hansson 883c6a6267 Bind maps too 2026-05-15 11:13:20 +02:00
Brosseau ValentinandGitHub 39eb3df863 Remove suspend-then-hibernate cleanup steps (#5829)
Those files are not present anymore (removed here e4b7372666)

Removed suspend-then-hibernate configuration cleanup steps from the script.
2026-05-15 11:03:21 +02:00
Ryan Hughes 9b4a411e5b Pin omarchy-reinstall-git to master branch
GitHub's default branch on basecamp/omarchy is no longer master, so
a plain clone pulls the development branch. Pass --branch master so
reinstalls always land on stable regardless of repo default.
2026-05-14 13:52:46 -04:00
David Heinemeier Hansson e916491c9f More helpers to cleanup configs 2026-05-14 13:15:03 +02:00
David Heinemeier Hansson a4e4b4b1ed Extract launch_sole 2026-05-14 12:58:39 +02:00
David Heinemeier Hansson 8f237f1858 Slim 2026-05-14 12:55:34 +02:00
David Heinemeier Hansson 596638aa73 Don't need the drop shadow 2026-05-14 12:52:45 +02:00
David Heinemeier Hansson 84de3d3a2e Extract more helpers 2026-05-14 12:51:03 +02:00
David Heinemeier Hansson 6840242c44 Fix indention 2026-05-14 12:37:53 +02:00
9d7474095f Keep brightness OSD popup width uniform across all percentages (#5806)
Pad the percent text to 3 chars with printf so "  5%", " 50%", and
"100%" render at identical width in the JetBrainsMono monospace label.
Previously the popup container resized between events because the
label string varied between 2 and 4 characters, which caused the
popup to visibly jump in width on consecutive brightness key presses.

Builds on #5525, which made the percent values themselves step
uniformly; this completes the loop by making the rendered popup match.

Co-authored-by: Mateus Pegorim <14262063+Pegorim@users.noreply.github.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-14 12:35:36 +02:00
David Heinemeier Hansson 7f85ee7d9d Make the selected image bigger 2026-05-14 12:33:51 +02:00
David Heinemeier Hansson 4a11ca7ae9 Loop around 2026-05-14 12:32:19 +02:00
David Heinemeier Hansson 6891c996b5 Add migration for new tmux keybinding 2026-05-14 12:04:09 +02:00
David Heinemeier Hansson 4c48d83952 More helpers 2026-05-14 12:02:53 +02:00
David Heinemeier Hansson 41988fda2a Cleanup 2026-05-14 12:02:53 +02:00
David Heinemeier Hansson 35cf232bcb Extract built-in notifications 2026-05-14 12:02:53 +02:00
Vitor MeloandGitHub e766f0ac28 Add bind M-Enter to open new pane em tmux (#5785) 2026-05-14 11:40:20 +02:00
David Heinemeier Hansson 3e098f6dd5 Next up is 4.0 2026-05-14 11:34:55 +02:00
David Heinemeier Hansson b72eb206cb Extract launch_on_start helper 2026-05-14 11:34:26 +02:00
David Heinemeier Hansson 83c2e2f84c Extract Omarchy's own bootstrap 2026-05-14 11:32:22 +02:00
David Heinemeier Hansson 9e1310106a Too defensive 2026-05-14 11:32:13 +02:00
David Heinemeier Hansson cfc7bc0cda Better naming 2026-05-14 11:21:45 +02:00
David Heinemeier Hansson dca3bfd951 Cleaner selection without exposed filtering 2026-05-14 11:17:33 +02:00
David Heinemeier Hansson 72bd02ca89 Start extracting omarchy helpers for cumbersome lua calls 2026-05-14 11:13:37 +02:00
David Heinemeier Hansson b26cd62334 Extract the nautilus cwd launcher 2026-05-14 11:12:25 +02:00
David Heinemeier Hansson 6ae8dc555e Extract launching the tmux terminal 2026-05-14 10:57:44 +02:00
David Heinemeier Hansson 9e20c4899d Extract terminal launcher with cwd 2026-05-14 10:56:10 +02:00
Ryan HughesandGitHub 6b074c7a17 Merge pull request #5804 from bjarneo/tab-themes-and-backgrounds
Enable tab and shift+tab to navigate back and forth the wallpaper/theme selector
2026-05-14 02:02:56 -04:00
Bjarne Øverli d27c1e8346 Enable tab and shift+tab to navigate back and forth 2026-05-13 17:22:15 +02:00
Ryan Hughes 087909714e Add tmux keybindings viewer 2026-05-13 00:20:38 -04:00
Ryan Hughes be55e8048c Prevent modifier keys being stuck on Super + C / V / X 2026-05-12 22:41:27 -04:00
Ryan Hughes d932f47eaf Prevent bg-next from taking non-images 2026-05-12 21:57:57 -04:00
David Heinemeier Hansson 8d5e9e794e Move to pnpm dlx with a 5-day lag to skip the latest zero-day npm package exploits 2026-05-12 23:58:27 +02:00
Ryan Hughes c0e099fed5 Prevent wiping waybar configs to reposition 2026-05-11 20:07:18 -04:00
Ryan Hughes aada2a4c9c Preserve waybar position on refresh 2026-05-11 20:01:18 -04:00
Ryan HughesandGitHub 0601dea910 Merge pull request #5759 from basecamp/skwd-wall
Add QuickShell-based backgrounds selector
2026-05-11 18:38:39 -04:00
Ryan Hughes d54e8b5429 Use theme colors in image selector 2026-05-11 18:10:58 -04:00
Ryan Hughes f14d82b2f3 Start image selector on demand 2026-05-11 18:02:45 -04:00
Ryan Hughes cb87adfc99 Toggle image selector closed when already open 2026-05-11 17:53:40 -04:00
Ryan Hughes 3d8c061a39 Lazy load theme switcher thumbnails 2026-05-11 17:41:30 -04:00
Ryan Hughes 427783c41f Stub theme switcher benchmark 2026-05-11 17:20:46 -04:00
Ryan Hughes f24dd82181 Add filter typing to theme switcher 2026-05-11 17:10:45 -04:00
Ryan Hughes 903f27fdd1 Tighten image selector request handling 2026-05-11 16:50:26 -04:00
Ryan Hughes 0801209090 Keep selector labels readable 2026-05-11 16:07:37 -04:00
Ryan Hughes 314a7f75c0 Keep image selector preview centered 2026-05-11 16:03:31 -04:00
Ryan Hughes 3aaedd88b1 Remove selector width animation jitter 2026-05-11 15:57:59 -04:00
Ryan Hughes ca0ea7af57 Clamp image selector navigation 2026-05-11 15:52:38 -04:00
Ryan Hughes 693a23c58c Open image selector at selected item immediately 2026-05-11 15:47:01 -04:00
Ryan Hughes b89079ae5c Show theme names in theme switcher 2026-05-11 15:40:19 -04:00
David Heinemeier HanssonandRyan Hughes f6bd69bc0f Fix color sync 2026-05-11 15:29:31 -04:00
David Heinemeier HanssonandRyan Hughes ef129b9dab Consistency 2026-05-11 15:29:31 -04:00
David Heinemeier HanssonandRyan Hughes 0426f9b206 Cache warming 2026-05-11 15:29:31 -04:00
David Heinemeier HanssonandRyan Hughes b48f67058b Use consistent terms 2026-05-11 15:29:31 -04:00
David Heinemeier HanssonandRyan Hughes 000b7c79af Improve performance 2026-05-11 15:29:11 -04:00
David Heinemeier HanssonandRyan Hughes 0b2332e45d Permanent process for speed 2026-05-11 15:29:11 -04:00
David Heinemeier HanssonandRyan Hughes 5487c17d19 Single namespace is fine 2026-05-11 15:28:52 -04:00
David Heinemeier HanssonandRyan Hughes 008f0cf7dd Extract generic switcher 2026-05-11 15:28:52 -04:00
David Heinemeier HanssonandRyan Hughes 1e646be7ee We need quickshell available 2026-05-11 15:28:33 -04:00
David Heinemeier HanssonandRyan Hughes aba11e716f Tweaks 2026-05-11 15:28:33 -04:00
David Heinemeier HanssonandRyan Hughes 333ec367df Let's build our own wall 2026-05-11 15:28:33 -04:00
David Heinemeier HanssonandRyan Hughes 7a988d8909 Switch to using the switcher on all the normal keybindings 2026-05-11 15:27:56 -04:00
David Heinemeier HanssonandRyan Hughes 67751a45b5 Correct indention 2026-05-11 15:27:43 -04:00
David Heinemeier HanssonandRyan Hughes da822f6ffb Change from swaybg to skwd-wall
Nicer picker and support for movie bgs
2026-05-11 15:27:43 -04:00
Ryan HughesandGitHub 15658cc622 Merge pull request #5723 from basecamp/hyprland-lua-conversion
Hyprland lua conversion
2026-05-11 15:02:02 -04:00
David Heinemeier Hansson 43ec46f699 Add tds 4-way 2026-05-11 18:21:45 +02:00
Ryan Hughes 350b9a33b3 Fix keybinds display 2026-05-11 10:40:26 -04:00
Ryan Hughes e39206f24d Simplify montor scaling 2026-05-11 10:40:26 -04:00
Ryan Hughes 804571d8e2 Update all hyprland references to new lua ones 2026-05-11 10:40:26 -04:00
Ryan Hughes 82a1a91509 Add conf -> lua migration for Hyprland and update old migrations 2026-05-11 10:39:22 -04:00
Ryan Hughes 59a2619426 Update theme specifics to lua 2026-05-11 10:39:22 -04:00
Ryan Hughes f1bec15325 Update theme and SDDM to lua 2026-05-11 10:39:22 -04:00
Ryan Hughes c7b6a7f8c4 Swap defaults to lua 2026-05-11 10:39:22 -04:00
Ryan Hughes b93650991f Swap configs to lua 2026-05-11 10:39:22 -04:00
Ryan Hughes 7e6403133c Prevent lsp complaining 2026-05-11 10:39:22 -04:00
Mateusz KowalczykandGitHub 1acaa7ba4d Fix brightness indicator glitches caused by hardware-side key auto-repeat (#5760)
* Avoid overlapping brightness change key events.

* Clarify the fix comment
2026-05-11 16:33:58 +02:00
David Heinemeier Hansson dc4e6a6a50 One more weather icon tweak for light drizzle 2026-05-11 16:32:51 +02:00
David Heinemeier Hansson 147cc721f0 Better rain mapping of icons 2026-05-11 16:21:54 +02:00
David Heinemeier Hansson 95531a39c0 How to evolve features that require input and interaction 2026-05-11 15:45:36 +02:00
c6ecdd1000 Add dispatch shortcuts to help menu (#5756)
* feat: dispatch shortcuts from help menu

* Retain uwsm launch wrapping

---------

Co-authored-by: David Heinemeier Hansson <david@hey.com>
2026-05-11 15:40:04 +02:00
David Heinemeier HanssonandGitHub 5738583319 RetroArch game launcher installer (#5753)
* Agents should use the notification helper

* Turn a single RetroArch game into its own application launcher

* Tweak installer

* Extract selection logic into cli

* Use consistent glyph

* One more
2026-05-11 13:01:45 +02:00
David Heinemeier Hansson fc787cd040 Agents should use the notification helper 2026-05-11 12:13:33 +02:00
David Heinemeier Hansson b2f89061c7 Add hunk for diffing as a lazy-install npx 2026-05-11 11:31:42 +02:00
92f93cb0e5 Persist Bluetooth power state across reboots (#5683)
* Persist Bluetooth power state across reboots

BlueZ defaults to AutoEnable=true, which forces controllers on at boot
regardless of the last user-set state. Setting AutoEnable=false makes
bluetoothd respect the persisted Powered state, so toggling off in
bluetui (or any DBus client) survives a reboot.

Adds the change to the install path and a migration for existing setups.

* Set reboot-required in Bluetooth persistence migration

Per review feedback, the AutoEnable=false change only takes effect on
bluetoothd startup. Without setting reboot-required, omarchy-update-restart
won't prompt the user to reboot, so the fix would only kick in at their
next organic reboot — by which time the bug may appear unfixed.

Matches the convention in migrations/1776346552.sh and similar.

* No need to ask for a reboot when this is available on the next one

---------

Co-authored-by: David Heinemeier Hansson <david@hey.com>
2026-05-11 10:21:16 +02:00
c4dbf12920 Add pre-refresh-pacman.d hooks for custom repository support (#5681)
Fires after the channel template is copied to /etc/pacman.conf and before
`pacman -Syyuu` runs, letting users layer custom Pacman repositories or
IgnorePkg directives onto the freshly-written config so they're respected
by the upgrade. Useful for users running on overlay distros (CachyOS,
Chaotic-AUR, internal company repos) where a wipe-and-reinstall would
otherwise pull vanilla Arch versions.

Ships with `pre-refresh-pacman.d/add-custom-repo.sample` showing the
pattern.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-11 10:19:12 +02:00
RenéandGitHub 324c9a4054 Fix fontconfig monospace binding overriding app-specific fonts (#5700)
Change monospace match from mode="assign" binding="strong" to
mode="append" binding="same" so the system font acts as a fallback
instead of overriding explicit app font configs like Ghostty's font-family.

Add migration to fix existing user configs.

Fixes #5675
2026-05-11 10:15:37 +02:00
David Heinemeier Hansson 378ba984ca Checkout the full git so branch switching is still possible
Closes #5701
2026-05-11 10:11:53 +02:00
David Heinemeier Hansson 705e26eb8a Migrate the existing imv configs 2026-05-11 10:00:28 +02:00
Jon KinneyandGitHub cea144bc51 Trash imv deletes; add Ctrl+E to edit in Satty (#5721)
* Trash imv deletes; add Ctrl+E to edit in Satty

Ctrl+X / Ctrl+Shift+X now move the image to the freedesktop trash via
`gio trash` instead of unconditional `rm`, so accidental presses are
recoverable from the file manager's Trash.

Adds Ctrl+E to open the current image in Satty (already in
omarchy-base.packages) and quit imv, mirroring the typical
screenshot → annotate workflow.

* Add -- separator to gio trash invocations

Prevents filenames starting with - from being parsed as options.
2026-05-11 10:00:20 +02:00
46365b7d4d Scope branding image pickers to ~/Pictures, fix About transcode mode (#5733)
* Scope branding image pickers to ~/Pictures, fix About transcode mode

The "Set From Image" path in both Style → About and Style → Screensaver
was scanning all of $HOME for *.svg / *.png and feeding the result into
Walker dmenu. On a populated home directory this can be tens of thousands
of entries, leaving the picker effectively unusable.

Scope the picker to ${XDG_PICTURES_DIR:-$HOME/Pictures}, matching the
pattern already used in omarchy-capture-screenshot.

While here, drop the hardcoded --mode block from omarchy-branding-about
so the About transcode falls back to the default braille mode, matching
what omarchy-branding-screensaver does and what stock about.txt ships
with. The reduced --width 54 stays so the result fits the fastfetch
logo column.

* Explain the scope of the picker

---------

Co-authored-by: Gavin Nugent <245706154+28allday@users.noreply.github.com>
Co-authored-by: David Heinemeier Hansson <david@hey.com>
2026-05-11 09:53:07 +02:00
David Heinemeier Hansson 6afb51298c Hide the unused bits 2026-05-10 21:29:58 +02:00
David Heinemeier Hansson cd461059d0 Just a little wider 2026-05-10 20:33:34 +02:00
David Heinemeier Hansson f09743b2e9 libretro-vice is now an explosion of minor pkgs 2026-05-10 16:47:21 +02:00
David Heinemeier Hansson 8788dd2eb2 Fix arg order 2026-05-10 16:44:09 +02:00
David Heinemeier Hansson 0af7cc4a76 Fix overlap 2026-05-10 16:39:01 +02:00
David Heinemeier Hansson f426ae0de8 Lookup code symbols for better keybindings list 2026-05-10 16:31:08 +02:00
642d87d443 Add fine and coarse window resize steps (#5717)
* add additional window resize shortcuts

* add additional window resize shortcuts

* Use bigger difference between the steps

---------

Co-authored-by: David Heinemeier Hansson <david@hey.com>
2026-05-10 16:26:02 +02:00
afcfaf6b1e Control Waybar position (#5730)
* Waybar positioning and shape

* Reveal weather again on left/right

* Fix indicators moving bar left/right

* Clean it up

* Cleanup

* One step forward, one step backwards

* Fix styles

* More style massage

* More tweaks

* Just position for now

* Fix keys

* No longer needed

* No need to reset

* Simplify

* Reset but protect waybar configs

* Not needed

* Fix glyph

* Not needed

* Cleanup

* Better wording

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-05-10 15:42:26 +02:00
David Heinemeier Hansson f26cc8f157 Send a notification when we switch 2026-05-10 15:22:41 +02:00
David Heinemeier Hansson 566c106ec1 Better wording 2026-05-10 15:11:47 +02:00
David Heinemeier Hansson 5346bc6db1 Only return state when we are toggling
Otherwise we know it!
2026-05-10 15:08:33 +02:00
David Heinemeier Hansson 0075645f0e Set hyprlock corners too 2026-05-10 15:05:34 +02:00
David Heinemeier Hansson f10c945e00 Add Receive as an option to sharing 2026-05-10 14:50:48 +02:00
David Heinemeier Hansson 8a94891e77 Better glyph 2026-05-10 14:34:44 +02:00
David Heinemeier Hansson 2e29714eee Add integrated Style > Corner controls across hyprland, mako, walker 2026-05-10 14:29:51 +02:00
David Heinemeier Hansson 40a20e2a5c Fix glyph for Zen 2026-05-10 14:28:18 +02:00
David Heinemeier Hansson 8a38615f19 Fix for new notification send 2026-05-10 11:50:30 +02:00
David Heinemeier Hansson 887c7e3751 Set mako corners round or sharp 2026-05-10 11:50:19 +02:00
David Heinemeier Hansson e099f47d53 Add toggling of hyprland window rounded corners 2026-05-10 11:31:02 +02:00
David Heinemeier Hansson 26c1f9c546 Refactor toggles and notifications 2026-05-10 11:26:59 +02:00
David Heinemeier Hansson d3a082ef11 Fix upcoming reminders listing
It was comparing NextElapseUSecMonotonic against /proc/uptime, but those
values aren’t in the same monotonic timeline for user timers, so valid
upcoming reminders were being skipped.
2026-05-10 10:52:20 +02:00
David Heinemeier Hansson 2ab639ac0a Latest version from HANCORE 2026-05-10 10:41:34 +02:00
David Heinemeier Hansson 3d42142b88 Fix group coloring 2026-05-09 22:48:23 +02:00
David Heinemeier Hansson aa6b7f2975 Make the border highlight clearer 2026-05-09 22:35:18 +02:00
David Heinemeier Hansson 47a53a18ba Add Solitude theme by HANCORE 2026-05-09 22:33:10 +02:00
David Heinemeier Hansson b2fb238453 Add Last Horizon theme by HANCORE 2026-05-09 22:05:54 +02:00
David Heinemeier Hansson 676a278653 Slim down now that we are auto-detecting GDK_SCALE 2026-05-09 20:13:04 +02:00
David Heinemeier Hansson 890e3fc8c5 Set the initial GDK_SCALE to match the monitor scale 2026-05-09 19:55:15 +02:00
David Heinemeier Hansson 3eca9573ea Make GDK_SCALE change alongside the general monitor scaling 2026-05-09 19:29:22 +02:00
David Heinemeier Hansson 2e0e9af0a9 Use save for screenshot 2026-05-09 12:04:53 +02:00
David Heinemeier Hansson 9a2c53d571 Add save as an option for agents 2026-05-09 12:04:34 +02:00
David Heinemeier Hansson 10c42afcf2 Echo result so agents can use them and keep working with them 2026-05-09 11:40:31 +02:00
David Heinemeier Hansson cd9d6bb54b Screenshot on visual changes 2026-05-09 11:20:36 +02:00
David Heinemeier Hansson b9830069b1 Remove duplicate cliamp .desktop and icon 2026-05-09 08:28:53 +02:00
David Heinemeier Hansson cf9c274ee5 Cliamp now ships with the icon and desktop entry on its own 2026-05-09 08:25:05 +02:00
David Heinemeier Hansson ad2ae30f1e Remove VAAPI GL video feature flags from Chromium-based browser configs to prevent crashing on some machines 2026-05-08 22:31:01 +02:00
David Heinemeier Hansson 1fb412b5df Fix guidance 2026-05-08 22:07:49 +02:00
David Heinemeier Hansson ce60cb81c1 Don't do that 2026-05-08 22:06:18 +02:00
David Heinemeier Hansson fb174bfa70 Fix perms 2026-05-08 22:04:41 +02:00
David Heinemeier Hansson 25e6fe2ef9 Hide cursor like on decryption screen 2026-05-08 22:04:01 +02:00
David Heinemeier Hansson 7b860f4291 Be more forceful about killing waybar
Sometimes it can still get stuck
2026-05-08 21:52:42 +02:00
David Heinemeier Hansson dad2870f58 Check for weather once a minute instead of once every ten
More accurate and deals with the first-boot issue on network too
2026-05-08 21:44:21 +02:00
David Heinemeier Hansson 2594a80cba Use latest package name 2026-05-08 21:34:46 +02:00
David Heinemeier Hansson 4c482769b8 Ensure quotes 2026-05-08 21:28:09 +02:00
a4778a01c0 Delay weather waybar startup to handle network initialization on boot (#5677)
Co-authored-by: jzwnl <jzwnl@users.noreply.github.com>
2026-05-08 21:14:29 +02:00
1537547f91 Use packaged Dell XPS touchpad haptics (#5534)
* Configure Dell XPS haptics directly

* Use packaged Dell XPS touchpad haptics service

* fix: keep one Dell haptics migration

* We already have a dedicated Trigger > Hardware menu

* Name for action

* Moved

* Need to make the package available for offline

* Simplify

---------

Co-authored-by: David Heinemeier Hansson <david@hey.com>
2026-05-08 21:07:51 +02:00
David Heinemeier Hansson 30f9a8da54 Not worth the extraction 2026-05-08 20:52:29 +02:00
David Heinemeier Hansson df4ffe991f Balance in output 2026-05-08 20:48:36 +02:00
David Heinemeier Hansson 1b5dcdafd2 Ensure this is a full reset 2026-05-08 20:44:07 +02:00
David Heinemeier Hansson e11d20cfba Quiet the warning on reinstall of keyring 2026-05-08 20:41:33 +02:00
344 changed files with 4777 additions and 1990 deletions
+11
View File
@@ -0,0 +1,11 @@
{
"workspace": {
"library": [
"/usr/share/hypr/stubs"
],
"checkThirdParty": false
},
"diagnostics": {
"globals": ["hl"]
}
}
+10
View File
@@ -82,6 +82,8 @@ Use these instead of raw shell commands:
- `omarchy-cmd-missing` / `omarchy-cmd-present` - check for commands
- `omarchy-pkg-missing` / `omarchy-pkg-present` - check for packages
- `omarchy-pkg-add` - install packages (handles both pacman and AUR)
- `omarchy-pkg-drop` - remove packages; use this instead of raw `pacman -R*`
- `omarchy-notification-send` - send desktop notifications; do not call `notify-send` directly
- `omarchy-hw-asus-rog` - detect ASUS ROG hardware (and similar `hw-*` commands)
Exceptions are allowed for bootstrap, preflight, migration, and package-helper scripts where the helper may not be available yet, where the helper itself is being implemented, or where direct package-manager behavior is required.
@@ -92,6 +94,14 @@ Exceptions are allowed for bootstrap, preflight, migration, and package-helper s
- `default/themed/*.tpl` - templates with `{{ variable }}` placeholders for theme colors
- `themes/*/colors.toml` - theme color definitions (accent, background, foreground, color0-15)
# Visual Changes
When making visual changes, such as Waybar styles or desktop appearance, always take and analyze a screenshot after applying the change to verify the result. Use `omarchy capture screenshot fullscreen save` for fullscreen screenshots.
For interactive UI work, use `wtype` to simulate keyboard input when available. Example: start the UI in the background, wait briefly for focus, then run `wtype -k Right -k Return` to exercise keyboard selection and confirm the resulting command output or state change. Prefer this over manual-only verification when a UI returns a selected value or changes a symlink/config.
When testing layer-shell UI, capture the reference and candidate states as separate screenshots, then compare them visually before further edits. If a launched UI would otherwise remain open, keep track of its PID and stop it after the screenshot; avoid broad process kills unless checking with `ps` first.
# Refresh Pattern
To copy a default config to user config with automatic backup:
@@ -0,0 +1,2 @@
[Desktop Entry]
Hidden=true
@@ -0,0 +1,2 @@
[Desktop Entry]
Hidden=true
@@ -0,0 +1,2 @@
[Desktop Entry]
Hidden=true
@@ -0,0 +1,2 @@
[Desktop Entry]
Hidden=true
@@ -0,0 +1,2 @@
[Desktop Entry]
Hidden=true
Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 147 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 63 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

+4 -2
View File
@@ -40,20 +40,21 @@ GROUP_DESCRIPTIONS[default]="Default application selection"
GROUP_DESCRIPTIONS[dev]="Omarchy development tools"
GROUP_DESCRIPTIONS[drive]="Drive selection and encryption"
GROUP_DESCRIPTIONS[font]="Font management"
GROUP_DESCRIPTIONS[games]="Game launchers and helpers"
GROUP_DESCRIPTIONS[hibernation]="Hibernation setup and removal"
GROUP_DESCRIPTIONS[hook]="User hook runner"
GROUP_DESCRIPTIONS[hw]="Hardware detection and controls"
GROUP_DESCRIPTIONS[hyprland]="Hyprland window, monitor, and toggle controls"
GROUP_DESCRIPTIONS[install]="Optional software installers"
GROUP_DESCRIPTIONS[launch]="Application launchers"
GROUP_DESCRIPTIONS[mako]="Mako notification controls"
GROUP_DESCRIPTIONS[menu]="Omarchy menu commands"
GROUP_DESCRIPTIONS[migrate]="Migration runner"
GROUP_DESCRIPTIONS[notification]="Notification helpers"
GROUP_DESCRIPTIONS[npx]="NPX package wrappers"
GROUP_DESCRIPTIONS[npm]="NPM package wrappers"
GROUP_DESCRIPTIONS[pkg]="Package management helpers"
GROUP_DESCRIPTIONS[plymouth]="Plymouth boot theme management"
GROUP_DESCRIPTIONS[powerprofiles]="Power profile management"
GROUP_DESCRIPTIONS[echo]="Colored terminal output helpers"
GROUP_DESCRIPTIONS[refresh]="Reset config to defaults"
GROUP_DESCRIPTIONS[reinstall]="Reinstall and reset workflows"
GROUP_DESCRIPTIONS[reminder]="Desktop notification reminders"
@@ -62,6 +63,7 @@ GROUP_DESCRIPTIONS[restart]="Restart Omarchy components"
GROUP_DESCRIPTIONS[setup]="Interactive setup wizards"
GROUP_DESCRIPTIONS[screensaver]="Screensaver branding and animation"
GROUP_DESCRIPTIONS[snapshot]="System snapshots"
GROUP_DESCRIPTIONS[style]="Global UI style controls"
GROUP_DESCRIPTIONS[sudo]="Sudo configuration helpers"
GROUP_DESCRIPTIONS[swayosd]="SwayOSD status display helpers"
GROUP_DESCRIPTIONS[system]="Reboot, shutdown, logout, and lock"
+2 -2
View File
@@ -21,7 +21,7 @@ time_remaining=$(omarchy-battery-remaining-time)
capacity=$(omarchy-battery-capacity)
if [[ $state == "charging" ]]; then
echo "󰁹 Battery ${percentage}% · ${time_remaining} to full ·  ${power_rate}W / ${capacity}Wh"
echo "Battery ${percentage}% · ${time_remaining} to full ·  ${power_rate}W / ${capacity}Wh"
else
echo "󰁹 Battery ${percentage}% · ${time_remaining} left ·  ${power_rate}W / ${capacity}Wh"
echo "Battery ${percentage}% · ${time_remaining} left ·  ${power_rate}W / ${capacity}Wh"
fi
+4 -2
View File
@@ -8,10 +8,12 @@
set -euo pipefail
SOURCE_DIR="${XDG_PICTURES_DIR:-$HOME/Pictures}"
case "${1:-}" in
image)
image=$(omarchy-menu-file "Logo image" "$HOME" "svg png")
if [[ -n $image ]] && omarchy-transcode-ascii "$image" ~/.config/omarchy/branding/about.txt --width 54 --height 26 --mode block; then
image=$(omarchy-menu-file "Pick png/svg from $SOURCE_DIR" "${SOURCE_DIR}" "svg png")
if [[ -n $image ]] && omarchy-transcode-ascii "$image" ~/.config/omarchy/branding/about.txt --width 54 --height 26; then
omarchy-launch-about >/dev/null 2>&1
fi
;;
+3 -1
View File
@@ -8,9 +8,11 @@
set -euo pipefail
SOURCE_DIR="${XDG_PICTURES_DIR:-$HOME/Pictures}"
case "${1:-}" in
image)
image=$(omarchy-menu-file "Logo image" "$HOME" "svg png")
image=$(omarchy-menu-file "Pick png/svg from $SOURCE_DIR" "${SOURCE_DIR}" "svg png")
if [[ -n $image ]] && omarchy-transcode-ascii "$image" ~/.config/omarchy/branding/screensaver.txt; then
omarchy-launch-screensaver force >/dev/null 2>&1
fi
+15 -7
View File
@@ -6,6 +6,21 @@
step="${1:-+5%}"
if [[ $step == "off" ]]; then
hyprctl dispatch 'hl.dsp.dpms({ action = "disable" })' >/dev/null 2>&1 || hyprctl dispatch dpms off >/dev/null 2>&1
exit 0
elif [[ $step == "on" ]]; then
hyprctl dispatch 'hl.dsp.dpms({ action = "enable" })' >/dev/null 2>&1 || hyprctl dispatch dpms on >/dev/null 2>&1
exit 0
fi
runtime_dir="${XDG_RUNTIME_DIR:-/tmp}"
# Drop overlapping brightness key events so concurrent invocations do not race.
# Hardware key repeat present on some devices can otherwise glitch SwayOSD rendering.
exec 9>"$runtime_dir/omarchy-brightness-display.lock"
flock -n 9 || exit 0
# Start with the first possible output, then refine to the most likely given an order heuristic.
device="$(ls -1 /sys/class/backlight 2>/dev/null | head -n1)"
for candidate in amdgpu_bl* intel_backlight acpi_video*; do
@@ -15,13 +30,6 @@ for candidate in amdgpu_bl* intel_backlight acpi_video*; do
fi
done
if [[ $step == "off" ]]; then
hyprctl dispatch dpms off >/dev/null 2>&1
exit 0
elif [[ $step == "on" ]]; then
hyprctl dispatch dpms on >/dev/null 2>&1
exit 0
fi
if omarchy-hyprland-monitor-focused-apple; then
omarchy-brightness-display-apple "$step"
+1
View File
@@ -233,6 +233,7 @@ stop_screenrecording() {
else
finalize_recording
local filename=$(cat "$RECORDING_FILE" 2>/dev/null)
echo "$filename"
local preview="${filename%.mp4}-preview.png"
# Generate a preview thumbnail from the first frame
+19 -11
View File
@@ -2,7 +2,7 @@
# omarchy:summary=Take a screenshot
# omarchy:group=capture
# omarchy:args=[smart|region|windows|fullscreen] [slurp|copy] [--editor=<name>]
# omarchy:args=[smart|region|windows|fullscreen] [slurp|copy|save] [--editor=<name>]
# omarchy:examples=omarchy screenshot | omarchy capture screenshot region
# omarchy:aliases=omarchy screenshot
@@ -126,14 +126,22 @@ esac
FILENAME="screenshot-$(date +'%Y-%m-%d_%H-%M-%S').png"
FILEPATH="$OUTPUT_DIR/$FILENAME"
if [[ $PROCESSING == "slurp" ]]; then
grim -g "$SELECTION" "$FILEPATH" || exit 1
wl-copy <"$FILEPATH"
case "$PROCESSING" in
slurp)
grim -g "$SELECTION" "$FILEPATH" || exit 1
echo "$FILEPATH"
wl-copy <"$FILEPATH"
(
ACTION=$(notify-send "Screenshot saved to clipboard and file" "Edit with Super + Alt + , (or click this)" -t 10000 -i "$FILEPATH" -A "default=edit")
[[ $ACTION == "default" ]] && open_editor "$FILEPATH"
) &
else
grim -g "$SELECTION" - | wl-copy
fi
(
ACTION=$(notify-send "Screenshot saved to clipboard and file" "Edit with Super + Alt + , (or click this)" -t 10000 -i "$FILEPATH" -A "default=edit")
[[ $ACTION == "default" ]] && open_editor "$FILEPATH"
) >/dev/null 2>&1 &
;;
copy)
grim -g "$SELECTION" - | wl-copy
;;
save)
grim -g "$SELECTION" "$FILEPATH" || exit 1
echo "$FILEPATH"
;;
esac
+1 -1
View File
@@ -25,7 +25,7 @@ brave) desktop_id="brave-browser.desktop"; name="Brave"; glyph="󰖟" ;;
brave-origin) desktop_id="brave-origin-beta.desktop"; name="Brave Origin"; glyph="󰖟" ;;
edge) desktop_id="microsoft-edge.desktop"; name="Edge"; glyph="󰇩" ;;
firefox) desktop_id="firefox.desktop"; name="Firefox"; glyph="󰈹" ;;
zen) desktop_id="zen.desktop"; name="Zen"; glyph="󰰷" ;;
zen) desktop_id="zen.desktop"; name="Zen"; glyph="󰖟" ;;
*)
echo "Usage: omarchy-default-browser <chromium|chrome|brave|brave-origin|edge|firefox|zen>"
exit 1
+163
View File
@@ -0,0 +1,163 @@
#!/bin/bash
# omarchy:summary=Measure theme switcher cache and selector prep times
# omarchy:args=[--repeat=<count>] [--keep-cache]
# omarchy:examples=omarchy dev benchmark theme switcher | omarchy dev benchmark theme-switcher --repeat=10
# omarchy:aliases=omarchy dev benchmark theme-switcher
set -euo pipefail
OMARCHY_BIN_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)
OMARCHY_PATH=${OMARCHY_PATH:-$(cd -- "$OMARCHY_BIN_DIR/.." && pwd)}
REPEAT=5
KEEP_CACHE=false
show_help() {
cat <<'EOF'
Usage:
omarchy dev benchmark theme switcher [--repeat=<count>] [--keep-cache]
Measure the non-interactive parts of the theme switcher:
- theme preview index build (omarchy-theme-switcher before UI handoff)
- lazy selector row prep used by the interactive theme switcher
- full thumbnail cache warmup cost (omarchy-menu-images --cache-only)
Options:
--repeat=<count> Number of warm runs to measure for each case (default: 5)
--keep-cache Keep the temporary benchmark cache and print its path
EOF
}
now_us() {
local now="${EPOCHREALTIME/./}"
printf '%s' "$now"
}
format_ms() {
local us="$1"
printf '%d.%03d' "$(( us / 1000 ))" "$(( us % 1000 ))"
}
measure_once() {
local start_us end_us
start_us=$(now_us)
"$@" >/dev/null
end_us=$(now_us)
printf '%s' "$(( end_us - start_us ))"
}
run_case() {
local label="$1"
shift
local total_us=0
local min_us=0
local max_us=0
local elapsed_us=0
for (( i = 1; i <= REPEAT; i++ )); do
elapsed_us=$(measure_once "$@")
total_us=$(( total_us + elapsed_us ))
if (( i == 1 || elapsed_us < min_us )); then
min_us=$elapsed_us
fi
if (( elapsed_us > max_us )); then
max_us=$elapsed_us
fi
done
printf '%-34s avg %8s ms min %8s ms max %8s ms\n' \
"$label" \
"$(format_ms "$(( total_us / REPEAT ))")" \
"$(format_ms "$min_us")" \
"$(format_ms "$max_us")"
}
while (( $# > 0 )); do
case "$1" in
--repeat=*)
REPEAT="${1#*=}"
;;
--keep-cache)
KEEP_CACHE=true
;;
--help | -h)
show_help
exit 0
;;
*)
echo "Unknown option: $1" >&2
show_help >&2
exit 2
;;
esac
shift
done
if [[ ! $REPEAT =~ ^[0-9]+$ ]] || (( REPEAT < 1 )); then
echo "--repeat must be a positive integer" >&2
exit 2
fi
benchmark_cache=$(mktemp -d)
thumbnail_cache=$(mktemp -d)
stub_bin=$(mktemp -d)
cleanup() {
rm -rf "$stub_bin"
if [[ $KEEP_CACHE == "true" ]]; then
printf 'Benchmark cache: %s\n' "$benchmark_cache"
printf 'Thumbnail cache: %s\n' "$thumbnail_cache"
else
rm -rf "$benchmark_cache" "$thumbnail_cache"
fi
}
trap cleanup EXIT
cat >"$stub_bin/omarchy-menu-images" <<'EOF'
#!/bin/bash
exit 0
EOF
chmod +x "$stub_bin/omarchy-menu-images"
benchmark_env=(
env
"OMARCHY_PATH=$OMARCHY_PATH"
"XDG_CACHE_HOME=$benchmark_cache"
"PATH=$stub_bin:$OMARCHY_BIN_DIR:$PATH"
)
thumbnail_env=(
env
"OMARCHY_PATH=$OMARCHY_PATH"
"XDG_CACHE_HOME=$thumbnail_cache"
"PATH=$stub_bin:$OMARCHY_BIN_DIR:$PATH"
)
preview_dir="$benchmark_cache/omarchy/theme-selector/previews"
thumbnail_preview_dir="$thumbnail_cache/omarchy/theme-selector/previews"
build_theme_index() {
"${benchmark_env[@]}" "$OMARCHY_BIN_DIR/omarchy-theme-switcher"
}
prepare_selector_lazy() {
"${benchmark_env[@]}" "$OMARCHY_BIN_DIR/omarchy-menu-images" --prepare-only --lazy-thumbnails --show-labels --filterable "$preview_dir"
}
prepare_image_cache() {
"${thumbnail_env[@]}" "$OMARCHY_BIN_DIR/omarchy-menu-images" --cache-only "$thumbnail_preview_dir"
}
printf 'Theme switcher benchmark (%d warm runs each)\n\n' "$REPEAT"
printf '%-34s %s ms\n' "theme index cold" "$(format_ms "$(measure_once build_theme_index)")"
run_case "theme index warm" build_theme_index
printf '%-34s %s ms\n' "selector prep cold (lazy)" "$(format_ms "$(measure_once prepare_selector_lazy)")"
run_case "selector prep warm (lazy)" prepare_selector_lazy
"${thumbnail_env[@]}" "$OMARCHY_BIN_DIR/omarchy-theme-switcher" >/dev/null
printf '%-34s %s ms\n' "thumbnail cache cold" "$(format_ms "$(measure_once prepare_image_cache)")"
run_case "thumbnail cache warm" prepare_image_cache
printf '\nTheme previews: %d\n' "$(find -L "$preview_dir" -maxdepth 1 -type f 2>/dev/null | wc -l)"
-9
View File
@@ -1,9 +0,0 @@
#!/bin/bash
# omarchy:summary=Print a failure message in red
# omarchy:args=<message>
RED='\033[0;31m'
NC='\033[0m'
echo -e "${RED}$*${NC}"
-9
View File
@@ -1,9 +0,0 @@
#!/bin/bash
# omarchy:summary=Print an informational message in yellow
# omarchy:args=<message>
YELLOW='\033[1;33m'
NC='\033[0m'
echo -e "${YELLOW}$*${NC}"
-9
View File
@@ -1,9 +0,0 @@
#!/bin/bash
# omarchy:summary=Print a success message in green
# omarchy:args=<message>
GREEN='\033[0;32m'
NC='\033[0m'
echo -e "${GREEN}$*${NC}"
+1
View File
@@ -16,6 +16,7 @@ if [[ -f $FIRST_RUN_MODE ]]; then
bash "$OMARCHY_PATH/install/first-run/firewall.sh"
bash "$OMARCHY_PATH/install/first-run/dns-resolver.sh"
bash "$OMARCHY_PATH/install/first-run/gnome-theme.sh"
bash "$OMARCHY_PATH/install/first-run/gdk-scale.sh"
bash "$OMARCHY_PATH/install/first-run/swayosd.sh"
bash "$OMARCHY_PATH/install/first-run/gtk-primary-paste.sh"
bash "$OMARCHY_PATH/install/first-run/elephant.sh"
+39
View File
@@ -0,0 +1,39 @@
#!/bin/bash
# omarchy:summary=List installed RetroArch core names
set -e
core_dir="/usr/lib/libretro"
preferred_cores=(
"Amstrad CPC|cap32"
"Arcade FBNeo|fbneo"
"Arcade MAME|mame"
"Commodore Amiga|puae"
"Commodore C128|vice_x128"
"Commodore C64|vice_x64"
"Commodore VIC-20|vice_xvic"
"Nintendo DS|desmume"
"Nintendo Game Boy / Color|gambatte"
"Nintendo Game Boy Advance|mgba"
"Nintendo GameCube / Wii|dolphin"
"Nintendo NES / Famicom|mesen"
"Nintendo 64|parallel_n64"
"Nintendo SNES / SFC|snes9x"
"NEC PC Engine / TurboGrafx-16|mednafen_pce_fast"
"NEC PC Engine CD / TurboGrafx-CD|mednafen_pce"
"NEC PC Engine SuperGrafx|mednafen_supergrafx"
"Sega Dreamcast|flycast"
"Sega Mega Drive / Master System / Game Gear|genesis_plus_gx"
"Sega Saturn|kronos"
"Sony PlayStation|mednafen_psx_hw"
"Sony PlayStation Portable|ppsspp"
)
[[ -d $core_dir ]] || exit 0
for preferred_core in "${preferred_cores[@]}"; do
label="${preferred_core%%|*}"
core="${preferred_core#*|}"
[[ -f $core_dir/${core}_libretro.so ]] && printf '%s (%s)\n' "$label" "$core"
done
+76
View File
@@ -0,0 +1,76 @@
#!/bin/bash
# omarchy:summary=Create a desktop launcher for a RetroArch game
# omarchy:args=[core path-to-game]
# omarchy:examples=omarchy games retro install snes9x ~/Games/roms/snes/game.sfc | omarchy-games-retro-install /usr/lib/libretro/mgba_libretro.so ~/Games/roms/gba/game.gba
set -e
if (( $# == 0 )); then
mapfile -t cores < <(omarchy-games-retro-cores)
if (( ${#cores[@]} == 0 )); then
omarchy-notification-send -g "󰯉" "No RetroArch cores found" "/usr/lib/libretro"
exit 1
fi
core=$(omarchy-menu-select "RetroArch core" "${cores[@]}") || exit 0
[[ -n $core ]] || exit 0
core="${core##*(}"
core="${core%)}"
game_path=$(omarchy-menu-file "Retro game" "$HOME/Games/roms" "7z bin ccd chd cue dmg elf fds gb gba gbc iso lha m3u md n64 nds nes pbp sfc smc swc zip z64") || exit 0
[[ -n $game_path ]] || exit 0
elif (( $# == 2 )); then
core="$1"
game_path="$2"
else
echo "Usage: omarchy-games-retro-install [core path-to-game]"
echo "Example: omarchy-games-retro-install snes9x ~/Games/roms/snes/game.sfc"
exit 1
fi
if [[ ! -f $game_path ]]; then
echo "Game not found: $game_path"
exit 1
fi
if [[ $core == */* ]]; then
core_path="$core"
else
core_path="/usr/lib/libretro/${core}_libretro.so"
fi
if [[ ! -f $core_path ]]; then
echo "Core not found: $core_path"
exit 1
fi
game_name=$(printf '%s' "${game_path##*/}" | sed 's/\.[^.]*$//; s/[[:space:]]*([^)]*)//g; s/[[:space:]]\+/ /g; s/^ //; s/ $//' | perl -Mopen=locale -pe 's/(^|[[:space:]])([^[:space:]])/$1\U$2/g')
desktop_name="$game_name"
desktop_id=$(printf '%s' "$desktop_name" | tr '[:upper:]' '[:lower:]' | tr -cs '[:alnum:]' '-' | sed 's/^-//; s/-$//')
desktop_dir="$HOME/.local/share/applications"
desktop_file="$desktop_dir/$desktop_id.desktop"
icon_dir="$desktop_dir/icons"
icon_path="$icon_dir/Retro Gaming.png"
mkdir -p "$desktop_dir" "$icon_dir"
[[ -f $icon_path ]] || cp "$HOME/.local/share/omarchy/applications/icons/Retro Gaming.png" "$icon_path"
cat >"$desktop_file" <<EOF
[Desktop Entry]
Version=1.0
Name=$desktop_name
Comment=Play $game_name with RetroArch
Exec=retroarch -L "$core_path" "$game_path"
Terminal=false
Type=Application
Icon=$icon_path
StartupNotify=true
Categories=Game;Emulator;
EOF
chmod +x "$desktop_file"
update-desktop-database "$desktop_dir" &>/dev/null || true
omarchy-notification-send -g "󰯉" "$game_name installed" "Start it with Super + Space"
-96
View File
@@ -1,96 +0,0 @@
#!/usr/bin/env python3
# omarchy:summary=Run the Synaptics touchpad haptic feedback daemon
"""Haptic feedback daemon for Synaptics touchpads with Manual Trigger.
Monitors touchpad button press events and sends haptic pulses via HID
feature reports. Required because the kernel's HID haptic subsystem only
supports Auto Trigger with waveform enumeration, not the simpler Manual
Trigger protocol used by these Synaptics touchpads.
"""
import fcntl, glob, os, struct, sys
VENDOR = "06CB"
REPORT_ID = 0x37
INTENSITY = 40 # 0-100
# input_event: struct timeval (16 bytes on 64-bit) + type(H) + code(H) + value(i)
EVENT_FORMAT = "llHHi"
EVENT_SIZE = struct.calcsize(EVENT_FORMAT)
EV_KEY = 0x01
BTN_LEFT = 272
BTN_RIGHT = 273
BTN_MIDDLE = 274
# ioctl: HIDIOCSFEATURE(len) = _IOC(_IOC_WRITE|_IOC_READ, 'H', 0x06, len)
def HIDIOCSFEATURE(length):
return 0xC0000000 | (length << 16) | (ord("H") << 8) | 0x06
def find_hidraw():
for path in sorted(glob.glob("/sys/class/hidraw/hidraw*")):
uevent = os.path.join(path, "device", "uevent")
try:
with open(uevent) as f:
content = f.read().upper()
if f"0000{VENDOR}" in content:
return os.path.join("/dev", os.path.basename(path))
except OSError:
continue
return None
def find_touchpad_event():
for path in sorted(glob.glob("/sys/class/input/event*/device/name")):
try:
with open(path) as f:
name = f.read().strip().upper()
if VENDOR in name and "TOUCHPAD" in name:
event = path.split("/")[-3]
return os.path.join("/dev/input", event)
except OSError:
continue
return None
def main():
hidraw = find_hidraw()
if not hidraw:
print("No Synaptics haptic touchpad hidraw device found", file=sys.stderr)
sys.exit(1)
event = find_touchpad_event()
if not event:
print("No Synaptics haptic touchpad input device found", file=sys.stderr)
sys.exit(1)
print(f"Haptic touchpad: hidraw={hidraw} input={event} intensity={INTENSITY}", flush=True)
haptic_report = struct.pack("BB", REPORT_ID, INTENSITY)
ioctl_req = HIDIOCSFEATURE(len(haptic_report))
hidraw_fd = os.open(hidraw, os.O_RDWR)
event_fd = os.open(event, os.O_RDONLY)
try:
while True:
data = os.read(event_fd, EVENT_SIZE)
if len(data) < EVENT_SIZE:
continue
_, _, ev_type, code, value = struct.unpack(EVENT_FORMAT, data)
if ev_type == EV_KEY and code in (BTN_LEFT, BTN_RIGHT, BTN_MIDDLE) and value == 1:
try:
fcntl.ioctl(hidraw_fd, ioctl_req, haptic_report)
except OSError:
pass
except KeyboardInterrupt:
pass
finally:
os.close(event_fd)
os.close(hidraw_fd)
if __name__ == "__main__":
main()
-5
View File
@@ -44,11 +44,6 @@ if grep -Fq "$SWAP_FILE" /etc/fstab; then
sudo sed -i '/^# Btrfs swapfile for system hibernation$/d' /etc/fstab
fi
# Remove suspend-then-hibernate configuration
echo "Removing suspend-then-hibernate configuration"
sudo rm -f /etc/systemd/logind.conf.d/lid.conf
sudo rm -f /etc/systemd/sleep.conf.d/hibernate.conf
# Remove mkinitcpio resume hook
echo "Removing resume hook"
sudo rm "$MKINITCPIO_CONF"
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Match Dell XPS systems with the Synaptics haptic touchpad.
omarchy-hw-match "XPS" && [[ -e /sys/bus/i2c/devices/i2c-VEN_06CB:00 ]]
+1 -1
View File
@@ -2,7 +2,7 @@
# omarchy:summary=Clear the internal-monitor-disable toggle if no external display is connected.
TOGGLE="$HOME/.local/state/omarchy/toggles/hypr/internal-monitor-disable.conf"
TOGGLE="$HOME/.local/state/omarchy/toggles/hypr/internal-monitor-disable.lua"
if [[ -f $TOGGLE ]] && ! omarchy-hw-external-monitors; then
rm -f "$TOGGLE"
+24 -14
View File
@@ -4,40 +4,50 @@
# omarchy:args=<on|off|toggle|recover>
TOGGLE="internal-monitor-disable"
TOGGLE_FLAG="$HOME/.local/state/omarchy/toggles/hypr/$TOGGLE.conf"
TOGGLE_FLAG="$HOME/.local/state/omarchy/toggles/hypr/$TOGGLE.lua"
MIRROR_TOGGLE="internal-monitor-mirror"
# Get internal monitor name dynamically
INTERNAL=$(hyprctl monitors -j | jq -r '.[] | select(.name | contains("eDP")).name' | head -n 1)
enable() {
if omarchy-hyprland-toggle-enabled "$TOGGLE"; then
omarchy-hyprland-toggle --disabled-notification "󰍹 Laptop display enabled" "$TOGGLE"
on() {
if omarchy-hyprland-toggle-enabled $TOGGLE; then
omarchy-hyprland-toggle $TOGGLE off
omarchy-notification-send -g 󰍹 "Laptop display enabled"
fi
}
disable() {
off() {
if ! omarchy-hw-external-monitors; then
notify-send -u low "󰍹 Can't disable the only active display"
omarchy-notification-send -g 󰍹 "Can't disable the only active display"
exit 1
fi
if omarchy-hyprland-toggle-disabled "$TOGGLE" && omarchy-hyprland-toggle-disabled "$MIRROR_TOGGLE"; then
echo "monitor=$INTERNAL,disable" >"$TOGGLE_FLAG"
notify-send -u low "󰍹 Laptop display disabled"
if omarchy-hyprland-toggle-disabled $TOGGLE && omarchy-hyprland-toggle-disabled $MIRROR_TOGGLE; then
printf 'hl.monitor({ output = "%s", disabled = true })\n' "$INTERNAL" >"$TOGGLE_FLAG"
omarchy-notification-send -g 󰍹 "Laptop display disabled"
hyprctl reload
fi
}
recover() {
if ! omarchy-hw-external-monitors && omarchy-hyprland-toggle-enabled "$TOGGLE"; then
omarchy-hyprland-toggle "$TOGGLE"
if ! omarchy-hw-external-monitors && omarchy-hyprland-toggle-enabled $TOGGLE; then
omarchy-hyprland-toggle $TOGGLE off
fi
}
toggle() {
if omarchy-hyprland-toggle-enabled $TOGGLE; then
on
else
off
fi
}
case "$1" in
on) enable ;;
off) disable ;;
toggle) if omarchy-hyprland-toggle-enabled "$TOGGLE"; then enable; else disable; fi ;;
on) on ;;
off) off ;;
toggle) toggle ;;
recover) recover ;;
*)
echo "Usage: $(basename "$0") {on|off|toggle|recover}" >&2
+27 -20
View File
@@ -4,7 +4,7 @@
# omarchy:args=<on|off|toggle|recover>
TOGGLE="internal-monitor-mirror"
TOGGLE_FLAG="$HOME/.local/state/omarchy/toggles/hypr/$TOGGLE.conf"
TOGGLE_FLAG="$HOME/.local/state/omarchy/toggles/hypr/$TOGGLE.lua"
DISABLE_TOGGLE="internal-monitor-disable"
# Get names dynamically
@@ -12,44 +12,51 @@ INTERNAL=$(hyprctl monitors -j | jq -r '.[] | select(.name | contains("eDP")).na
# Get the first available external monitor
EXTERNAL=$(hyprctl monitors -j | jq -r '.[] | select(.name | contains("eDP") | not).name' | head -n 1)
enable() {
if [[ -z "$EXTERNAL" ]]; then
notify-send -u low "󰍹 No external monitors found for mirror"
on() {
if [[ -z $EXTERNAL ]]; then
omarchy-notification-send -g 󰍹 "No external monitors found for mirror"
exit 1
fi
if [[ -z "$INTERNAL" ]]; then
notify-send -u low "󰍹 No laptop monitor found to mirror"
if [[ -z $INTERNAL ]]; then
omarchy-notification-send -g 󰍹 "No laptop monitor found to mirror"
exit 1
fi
if omarchy-hyprland-toggle-enabled "$DISABLE_TOGGLE"; then
omarchy-hyprland-toggle "$DISABLE_TOGGLE"
fi
omarchy-hyprland-toggle $DISABLE_TOGGLE off
if omarchy-hyprland-toggle-disabled "$TOGGLE"; then
echo "monitor=$EXTERNAL, preferred, auto, 1, mirror, $INTERNAL" > "$TOGGLE_FLAG"
notify-send -u low "󰍹 Mirroring enabled ($EXTERNAL)"
if omarchy-hyprland-toggle-disabled $TOGGLE; then
printf 'hl.monitor({ output = "%s", mode = "preferred", position = "auto", scale = 1, mirror = "%s" })\n' "$EXTERNAL" "$INTERNAL" >"$TOGGLE_FLAG"
omarchy-notification-send -g 󰍹 "Mirroring enabled ($EXTERNAL)"
hyprctl reload
fi
}
disable() {
if omarchy-hyprland-toggle-enabled "$TOGGLE"; then
omarchy-hyprland-toggle --disabled-notification "󰍹 Extended mode restored" "$TOGGLE"
off() {
if omarchy-hyprland-toggle-enabled $TOGGLE; then
omarchy-hyprland-toggle $TOGGLE off
omarchy-notification-send -g 󰍹 "Extended mode restored"
fi
}
toggle() {
if omarchy-hyprland-toggle-enabled $TOGGLE; then
off
else
on
fi
}
recover() {
if ! omarchy-hw-external-monitors && omarchy-hyprland-toggle-enabled "$TOGGLE"; then
omarchy-hyprland-toggle "$TOGGLE"
if ! omarchy-hw-external-monitors && omarchy-hyprland-toggle-enabled $TOGGLE; then
omarchy-hyprland-toggle $TOGGLE off
fi
}
case "$1" in
on) enable ;;
off) disable ;;
toggle) if omarchy-hyprland-toggle-enabled "$TOGGLE"; then disable; else enable; fi ;;
on) on ;;
off) off ;;
toggle) toggle ;;
recover) recover ;;
*)
echo "Usage: $(basename "$0") {on|off|toggle|recover}" >&2
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Print the monitor scale of the internal monitor or first other monitor
hyprctl monitors -j | jq -r '([.[] | select(.name | contains("eDP"))][0] // .[0]).scale // empty | tonumber | if . == floor then floor else . end'
+18 -11
View File
@@ -9,8 +9,9 @@ WIDTH=$(echo "$MONITOR_INFO" | jq -r '.width')
HEIGHT=$(echo "$MONITOR_INFO" | jq -r '.height')
REFRESH_RATE=$(echo "$MONITOR_INFO" | jq -r '.refreshRate')
# Cycle through scales: 1 → 1.25 → 1.6 → 2 → 3 → 4 → 1 (or reverse with --reverse)
# Cycle through monitor/GDK scale pairs: 1 → 1.25 → 1.6 → 2 → 3 → 4 → 1 (or reverse with --reverse)
SCALES=(1 1.25 1.6 2 3 4)
GDK_SCALES=(1 1.25 1.75 2 3 4)
# Find the index of the scale closest to the current one (Hyprland may
# snap fractional scales to nearby values, so we can't match exactly)
@@ -24,24 +25,30 @@ CURRENT_IDX=$(awk -v s="$CURRENT_SCALE" -v list="${SCALES[*]}" 'BEGIN {
print best
}')
if [[ "$1" == "--reverse" ]]; then
if [[ $1 == "--reverse" ]]; then
NEW_IDX=$(( (CURRENT_IDX - 1 + ${#SCALES[@]}) % ${#SCALES[@]} ))
else
NEW_IDX=$(( (CURRENT_IDX + 1) % ${#SCALES[@]} ))
fi
NEW_SCALE=${SCALES[$NEW_IDX]}
NEW_GDK_SCALE=${GDK_SCALES[$NEW_IDX]}
hyprctl keyword monitor "$ACTIVE_MONITOR,${WIDTH}x${HEIGHT}@${REFRESH_RATE},auto,$NEW_SCALE"
hyprctl eval "hl.monitor({ output = \"$ACTIVE_MONITOR\", mode = \"${WIDTH}x${HEIGHT}@${REFRESH_RATE}\", position = \"auto\", scale = $NEW_SCALE })" >/dev/null
# Persist to monitors.conf if the user has a single generic catch-all line
# (ignoring disabled monitors), so the scale survives reboots.
MONITOR_CONF="$HOME/.config/hypr/monitors.conf"
if [[ -f $MONITOR_CONF ]]; then
mapfile -t ACTIVE_LINES < <(grep -E '^[[:space:]]*monitor=' "$MONITOR_CONF" | grep -vE 'disable[[:space:]]*$')
if [[ ${#ACTIVE_LINES[@]} -eq 1 ]] && [[ "${ACTIVE_LINES[0]}" =~ ^monitor=,preferred,auto, ]]; then
sed -i -E "s|^(monitor=,preferred,auto,).*|\\1${NEW_SCALE}|" "$MONITOR_CONF"
fi
# Persist to monitors.lua if the user still has Omarchy's generic catch-all
# defaults, so the scale survives reboots.
MONITOR_LUA="$HOME/.config/hypr/monitors.lua"
if [[ -f $MONITOR_LUA ]] && grep -q '^local omarchy_monitor_scale = ' "$MONITOR_LUA"; then
sed -i -E \
-e "s|^local omarchy_monitor_scale = .*|local omarchy_monitor_scale = ${NEW_SCALE}|" \
-e "s|^local omarchy_gdk_scale = .*|local omarchy_gdk_scale = ${NEW_GDK_SCALE}|" \
"$MONITOR_LUA"
elif [[ -f $MONITOR_LUA ]] && grep -Eq '^hl\.monitor\(\{ output = "", mode = "preferred", position = "auto", scale = ("auto"|[0-9.]+) \}\)' "$MONITOR_LUA"; then
sed -i -E \
-e "s|^(hl\.monitor\(\{ output = \"\", mode = \"preferred\", position = \"auto\", scale = )([^ ]+)( \}\))|\\1${NEW_SCALE}\\3|" \
-e 's|^hl\.env\("GDK_SCALE", ".*"\)|hl.env("GDK_SCALE", "'"$NEW_GDK_SCALE"'")|' \
"$MONITOR_LUA"
fi
notify-send -u low "󰍹 Display scaling set to ${NEW_SCALE}x"
+62 -17
View File
@@ -1,32 +1,77 @@
#!/bin/bash
# omarchy:summary=Toggle permanent Hyprland flags by copying them into a directory that's sourced entirely.
# omarchy:args=[--enabled-notification <text>] [--disabled-notification <text>] <flag-name>
# omarchy:args=[--enabled-notification <text>] [--disabled-notification <text>] <flag-name> [on|off|toggle]
ENABLED_NOTIFICATION=""
DISABLED_NOTIFICATION=""
while [[ $# -gt 1 ]]; do
while (($# > 0)); do
case $1 in
--enabled-notification) ENABLED_NOTIFICATION="$2"; shift 2 ;;
--disabled-notification) DISABLED_NOTIFICATION="$2"; shift 2 ;;
--enabled-notification)
if (($# < 2)); then
echo "Missing value for $1" >&2
exit 1
fi
ENABLED_NOTIFICATION="$2"
shift 2
;;
--disabled-notification)
if (($# < 2)); then
echo "Missing value for $1" >&2
exit 1
fi
DISABLED_NOTIFICATION="$2"
shift 2
;;
*) break ;;
esac
done
FLAG_NAME="$1"
FLAG="$HOME/.local/state/omarchy/toggles/hypr/$FLAG_NAME.conf"
FLAG_SOURCE="$OMARCHY_PATH/default/hypr/toggles/$FLAG_NAME.conf"
if [[ -f $FLAG ]]; then
rm $FLAG
[[ -n $DISABLED_NOTIFICATION ]] && notify-send -u low "$DISABLED_NOTIFICATION"
elif [[ -f $FLAG_SOURCE ]]; then
cp $FLAG_SOURCE $FLAG
[[ -n $ENABLED_NOTIFICATION ]] && notify-send -u low "$ENABLED_NOTIFICATION"
else
echo "Flag not found: $FLAG_NAME"
if (($# < 1)); then
echo "Usage: omarchy-hyprland-toggle [--enabled-notification <text>] [--disabled-notification <text>] <flag-name> [on|off|toggle]" >&2
exit 1
fi
hyprctl reload
FLAG_NAME="$1"
ACTION="${2:-toggle}"
FLAG_FILE="$HOME/.local/state/omarchy/toggles/hypr/$FLAG_NAME.lua"
FLAG_SOURCE="$OMARCHY_PATH/default/hypr/toggles/$FLAG_NAME.lua"
on() {
if [[ -f $FLAG_SOURCE ]]; then
mkdir -p "$(dirname "$FLAG_FILE")"
cp "$FLAG_SOURCE" "$FLAG_FILE"
[[ -n $ENABLED_NOTIFICATION ]] && notify-send -u low "$ENABLED_NOTIFICATION"
else
echo "Flag not found: $FLAG_NAME" >&2
exit 1
fi
}
off() {
rm -f "$FLAG_FILE"
[[ -n $DISABLED_NOTIFICATION ]] && notify-send -u low "$DISABLED_NOTIFICATION"
}
toggle() {
if [[ -f $FLAG_FILE ]]; then
off
echo "off"
else
on
echo "on"
fi
}
case $ACTION in
on) on ;;
off) off ;;
toggle) toggle ;;
*)
echo "Usage: omarchy-hyprland-toggle [--enabled-notification <text>] [--disabled-notification <text>] <flag-name> [on|off|toggle]" >&2
exit 1
;;
esac
hyprctl reload >/dev/null
+1 -1
View File
@@ -3,4 +3,4 @@
# omarchy:summary=Check if a Hyprland toggle is currently disabled (missing).
# omarchy:args=<flag-name>
[[ ! -f "$HOME/.local/state/omarchy/toggles/hypr/$1.conf" ]]
[[ ! -f "$HOME/.local/state/omarchy/toggles/hypr/$1.lua" ]]
+1 -1
View File
@@ -3,4 +3,4 @@
# omarchy:summary=Check if a Hyprland toggle is currently enabled.
# omarchy:args=<flag-name>
[[ -f "$HOME/.local/state/omarchy/toggles/hypr/$1.conf" ]]
[[ -f "$HOME/.local/state/omarchy/toggles/hypr/$1.lua" ]]
+4 -2
View File
@@ -4,7 +4,9 @@
hyprctl clients -j | \
jq -r ".[].address" | \
xargs -I{} hyprctl dispatch closewindow address:{}
while read -r addr; do
hyprctl dispatch "hl.dsp.window.close(\"address:$addr\")" >/dev/null 2>&1 || hyprctl dispatch closewindow "address:$addr"
done
# Move to first workspace
hyprctl dispatch workspace 1
hyprctl dispatch 'hl.dsp.focus({ workspace = "1" })' >/dev/null 2>&1 || hyprctl dispatch workspace 1
+18 -12
View File
@@ -11,24 +11,30 @@ y=${4:-}
active=$(hyprctl activewindow -j)
pinned=$(echo "$active" | jq ".pinned")
addr=$(echo "$active" | jq -r ".address")
window="address:$addr"
hypr_dispatch() {
local lua="$1"
shift
hyprctl dispatch "$lua" >/dev/null 2>&1 || hyprctl dispatch "$@" >/dev/null
}
if [[ $pinned == "true" ]]; then
hyprctl -q --batch \
"dispatch pin address:$addr;" \
"dispatch togglefloating address:$addr;" \
"dispatch tagwindow -pop address:$addr;"
hypr_dispatch "hl.dsp.window.pin({ window = \"$window\" })" pin "$window"
hypr_dispatch "hl.dsp.window.float({ window = \"$window\", action = \"toggle\" })" togglefloating "$window"
hypr_dispatch "hl.dsp.window.tag({ window = \"$window\", tag = \"-pop\" })" tagwindow -pop "$window"
elif [[ -n $addr ]]; then
hyprctl dispatch togglefloating address:$addr
hyprctl dispatch resizeactive exact $width $height address:$addr
hypr_dispatch "hl.dsp.window.float({ window = \"$window\", action = \"toggle\" })" togglefloating "$window"
hypr_dispatch "hl.dsp.window.resize({ window = \"$window\", x = $width, y = $height })" resizeactive exact "$width" "$height" "$window"
if [[ -n $x && -n $y ]]; then
hyprctl dispatch moveactive $x $y address:$addr
hypr_dispatch "hl.dsp.window.move({ window = \"$window\", x = $x, y = $y })" moveactive "$x" "$y" "$window"
else
hyprctl dispatch centerwindow address:$addr
hypr_dispatch "hl.dsp.window.center({ window = \"$window\" })" centerwindow "$window"
fi
hyprctl -q --batch \
"dispatch pin address:$addr;" \
"dispatch alterzorder top address:$addr;" \
"dispatch tagwindow +pop address:$addr;"
hypr_dispatch "hl.dsp.window.pin({ window = \"$window\" })" pin "$window"
hypr_dispatch "hl.dsp.window.alter_zorder({ window = \"$window\", mode = \"top\" })" alterzorder top "$window"
hypr_dispatch "hl.dsp.window.tag({ window = \"$window\", tag = \"+pop\" })" tagwindow +pop "$window"
fi
@@ -2,7 +2,7 @@
# omarchy:summary=Toggle single-window square aspect ratio.
omarchy-hyprland-toggle \
--enabled-notification "Enable single-window square aspect ratio" \
--disabled-notification "Disable single-window square aspect ratio" \
single-window-aspect-ratio
case $(omarchy-hyprland-toggle single-window-aspect-ratio) in
on) omarchy-notification-send -g  "Enable single-window square aspect ratio" ;;
off) omarchy-notification-send -g  "Disable single-window square aspect ratio" ;;
esac
@@ -2,4 +2,6 @@
# omarchy:summary=Toggles transparency for the currently focused window.
hyprctl dispatch setprop "address:$(hyprctl activewindow -j | jq -r '.address')" opaque toggle
addr=$(hyprctl activewindow -j | jq -r '.address')
hyprctl dispatch "hl.dsp.window.set_prop({ window = \"address:$addr\", prop = \"opaque\", value = \"toggle\" })" >/dev/null 2>&1 || \
hyprctl dispatch setprop "address:$addr" opaque toggle
+2 -1
View File
@@ -10,5 +10,6 @@ case "$CURRENT_LAYOUT" in
*) NEW_LAYOUT=dwindle ;;
esac
hyprctl keyword workspace $ACTIVE_WORKSPACE, layout:$NEW_LAYOUT
hyprctl eval "hl.workspace_rule({ workspace = \"$ACTIVE_WORKSPACE\", layout = \"$NEW_LAYOUT\" })" >/dev/null 2>&1 || \
hyprctl keyword workspace $ACTIVE_WORKSPACE, layout:$NEW_LAYOUT
notify-send -u low "󱂬 Workspace layout set to $NEW_LAYOUT"
+4 -1
View File
@@ -21,7 +21,10 @@ omarchy-pkg-add \
libretro-parallel-n64 libretro-picodrive libretro-play libretro-ppsspp \
libretro-sameboy libretro-scummvm libretro-shaders-slang libretro-snes9x \
libretro-yabause \
libretro-cap32-git libretro-fbneo-git libretro-uae-git libretro-vice-git \
libretro-cap32-git libretro-fbneo-git libretro-uae-git \
libretro-vice-x128-git libretro-vice-x64-git libretro-vice-x64dtv-git libretro-vice-x64sc-git \
libretro-vice-xcbm2-git libretro-vice-xcbm5x0-git libretro-vice-xpet-git \
libretro-vice-xplus4-git libretro-vice-xscpu64-git libretro-vice-xvic-git \
libretro-database-git \
retroarch-joypad-autoconfig-git
+92
View File
@@ -0,0 +1,92 @@
#!/bin/bash
# omarchy:summary=Install Sunshine and open Moonlight streaming ports for LAN and Tailscale.
# omarchy:requires-sudo=true
set -e
TCP_PORTS=(47984 47989 48010)
UDP_PORTS=(5353 47998 47999 48000 48002 48010)
PRIVATE_CIDRS=(10.0.0.0/8 172.16.0.0/12 192.168.0.0/16)
UFW_COMMENT="omarchy-sunshine"
SUNSHINE_ADMIN_APP="Sunshine Admin"
SUNSHINE_ADMIN_URL="https://localhost:47990"
SUNSHINE_ADMIN_EXEC="omarchy-launch-webapp $SUNSHINE_ADMIN_URL --ignore-certificate-errors"
SUNSHINE_ICON_SOURCE="/usr/share/sunshine/web/images/logo-sunshine-45.png"
SUNSHINE_ICON_NAME="Sunshine Admin.png"
WEBAPP_ICON_DIR="$HOME/.local/share/applications/icons"
HYPR_AUTOSTART_FILE="$HOME/.config/hypr/autostart.lua"
HYPR_AUTOSTART_ENTRY='o.launch_on_start("sunshine")'
open_ufw_port_for_private_lans() {
local proto="$1"
local port="$2"
local cidr
for cidr in "${PRIVATE_CIDRS[@]}"; do
sudo ufw allow in proto "$proto" from "$cidr" to any port "$port" comment "$UFW_COMMENT" >/dev/null
done
}
open_ufw_port_for_tailscale() {
local proto="$1"
local port="$2"
if ip link show tailscale0 >/dev/null 2>&1; then
sudo ufw allow in on tailscale0 to any port "$port" proto "$proto" comment "$UFW_COMMENT" >/dev/null
fi
}
open_ufw_ports() {
local port
if omarchy-cmd-missing ufw; then
echo "UFW is not installed; skipping Sunshine firewall rules."
return
fi
for port in "${TCP_PORTS[@]}"; do
open_ufw_port_for_private_lans tcp "$port"
open_ufw_port_for_tailscale tcp "$port"
done
for port in "${UDP_PORTS[@]}"; do
open_ufw_port_for_private_lans udp "$port"
open_ufw_port_for_tailscale udp "$port"
done
sudo ufw reload
}
install_admin_webapp() {
mkdir -p "$WEBAPP_ICON_DIR"
cp "$SUNSHINE_ICON_SOURCE" "$WEBAPP_ICON_DIR/$SUNSHINE_ICON_NAME"
omarchy-webapp-install "$SUNSHINE_ADMIN_APP" "$SUNSHINE_ADMIN_URL" "$SUNSHINE_ICON_NAME" "$SUNSHINE_ADMIN_EXEC"
omarchy-restart-walker
}
enable_hyprland_autostart() {
mkdir -p "$(dirname "$HYPR_AUTOSTART_FILE")"
touch "$HYPR_AUTOSTART_FILE"
if ! grep -Fxq "$HYPR_AUTOSTART_ENTRY" "$HYPR_AUTOSTART_FILE"; then
printf '\n%s\n' "$HYPR_AUTOSTART_ENTRY" >>"$HYPR_AUTOSTART_FILE"
fi
}
echo "Installing Sunshine..."
omarchy-pkg-add sunshine
systemctl --user enable --now sunshine
echo "Opening Sunshine firewall ports..."
open_ufw_ports
echo "Installing Sunshine admin web app..."
install_admin_webapp
$SUNSHINE_ADMIN_EXEC >/dev/null 2>&1 &
echo "Enabling Sunshine autostart..."
enable_hyprland_autostart
echo ""
echo "Sunshine has been installed and its Moonlight streaming ports are open for private LANs and Tailscale."
+2 -2
View File
@@ -30,10 +30,10 @@ if omarchy-pkg-add $package; then
# Copy custom desktop entries with X-TerminalArg* keys
if [[ $package == "alacritty" ]]; then
mkdir -p ~/.local/share/applications
cp "$OMARCHY_PATH/applications/$desktop_id" ~/.local/share/applications/
cp "$OMARCHY_PATH/default/alacritty/$desktop_id" ~/.local/share/applications/
elif [[ $package == "foot" ]]; then
mkdir -p ~/.local/share/applications
cp "$OMARCHY_PATH/default/foot/$desktop_id" ~/.local/share/applications/
cp "$OMARCHY_PATH/applications/$desktop_id" ~/.local/share/applications/
fi
# Copy default config for optional terminals when missing
+4 -2
View File
@@ -6,7 +6,7 @@
default_browser=$(xdg-settings get default-web-browser)
browser_exec=$(sed -n 's/^Exec=\([^ ]*\).*/\1/p' {~/.local,~/.nix-profile,/usr}/share/applications/$default_browser 2>/dev/null | head -1)
if $browser_exec --help | grep -q MOZ_LOG; then
if $browser_exec --help 2>/dev/null | grep -q MOZ_LOG; then
private_flag="--private-window"
elif [[ $browser_exec =~ edge ]]; then
private_flag="--inprivate"
@@ -14,4 +14,6 @@ else
private_flag="--incognito"
fi
exec setsid uwsm-app -- "$browser_exec" "${@/--private/$private_flag}"
systemd-run --user --quiet --collect --unit="omarchy-browser-$(date +%s%N)" \
--property=StandardOutput=null --property=StandardError=null \
uwsm-app -- "$browser_exec" "${@/--private/$private_flag}"
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Launch Files
exec setsid uwsm-app -- nautilus --new-window
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Launch Files in the active terminal's current directory
exec setsid uwsm-app -- nautilus --new-window "$(omarchy-cmd-terminal-cwd)"
+1 -1
View File
@@ -13,7 +13,7 @@ LAUNCH_COMMAND="${2:-"uwsm-app -- $WINDOW_PATTERN"}"
WINDOW_ADDRESS=$(hyprctl clients -j | jq -r --arg p "$WINDOW_PATTERN" '.[]|select((.class|test("\\b" + $p + "\\b";"i")) or (.title|test("\\b" + $p + "\\b";"i")))|.address' | head -n1)
if [[ -n $WINDOW_ADDRESS ]]; then
hyprctl dispatch focuswindow "address:$WINDOW_ADDRESS"
hyprctl dispatch "hl.dsp.focus({ window = \"address:$WINDOW_ADDRESS\" })" >/dev/null 2>&1 || hyprctl dispatch focuswindow "address:$WINDOW_ADDRESS"
else
eval exec setsid $LAUNCH_COMMAND
fi
+16 -20
View File
@@ -20,35 +20,31 @@ walker -q
focused=$(omarchy-hyprland-monitor-focused)
terminal=$(xdg-terminal-exec --print-id)
hypr_focus_monitor() {
hyprctl dispatch "hl.dsp.focus({ monitor = \"$1\" })" >/dev/null 2>&1 || hyprctl dispatch focusmonitor "$1" >/dev/null
}
hypr_exec() {
local command="$1"
hyprctl dispatch "hl.dsp.exec_cmd([[$command]])" >/dev/null 2>&1 || hyprctl dispatch exec -- bash -lc "$command" >/dev/null
}
for m in $(hyprctl monitors -j | jq -r '.[] | .name'); do
hyprctl dispatch focusmonitor $m
hypr_focus_monitor "$m"
case $terminal in
*Alacritty*)
hyprctl dispatch exec -- \
alacritty --class=org.omarchy.screensaver \
--config-file ~/.local/share/omarchy/default/alacritty/screensaver.toml \
-e omarchy-screensaver
hypr_exec "alacritty --class=org.omarchy.screensaver --config-file ~/.local/share/omarchy/default/alacritty/screensaver.toml -e omarchy-screensaver"
;;
*ghostty*)
hyprctl dispatch exec -- \
ghostty --class=org.omarchy.screensaver \
--config-file=~/.local/share/omarchy/default/ghostty/screensaver \
--font-size=18 \
-e omarchy-screensaver
hypr_exec "ghostty --class=org.omarchy.screensaver --config-file=~/.local/share/omarchy/default/ghostty/screensaver --font-size=18 -e omarchy-screensaver"
;;
*foot*)
hyprctl dispatch exec -- \
foot --app-id=org.omarchy.screensaver \
--config="$OMARCHY_PATH/default/foot/screensaver.ini" \
-e omarchy-screensaver
hypr_exec "foot --app-id=org.omarchy.screensaver --config=\"$OMARCHY_PATH/default/foot/screensaver.ini\" -e omarchy-screensaver"
;;
*kitty*)
hyprctl dispatch exec -- \
kitty --class=org.omarchy.screensaver \
--override font_size=18 \
--override window_padding_width=0 \
-e omarchy-screensaver
hypr_exec "kitty --class=org.omarchy.screensaver --override font_size=18 --override window_padding_width=0 -e omarchy-screensaver"
;;
*)
notify-send -u low "✋ Screensaver only runs in Alacritty, Foot, Ghostty, or Kitty"
@@ -56,4 +52,4 @@ for m in $(hyprctl monitors -j | jq -r '.[] | .name'); do
esac
done
hyprctl dispatch focusmonitor $focused
hypr_focus_monitor "$focused"
+6
View File
@@ -0,0 +1,6 @@
#!/bin/bash
# omarchy:summary=Launch a terminal in the active terminal's current directory
# omarchy:args=[command...]
exec setsid uwsm-app -- xdg-terminal-exec --dir="$(omarchy-cmd-terminal-cwd)" "$@"
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Launch or attach to the Work tmux session in a terminal
exec omarchy-launch-terminal bash -c "tmux attach || tmux new -s Work"
+64 -16
View File
@@ -56,6 +56,11 @@ open_in_editor() {
omarchy-launch-editor "$1"
}
hypr_config_file() {
local name="$1"
printf '%s/.config/hypr/%s.lua' "$HOME" "$name"
}
install() {
present_terminal "echo 'Installing $1...'; omarchy-pkg-add $2"
}
@@ -81,7 +86,8 @@ aur_install_and_launch() {
}
show_learn_menu() {
case $(menu "Learn" " Keybindings\n Omarchy\n Hyprland\n󰣇 Arch\n Neovim\n󱆃 Bash") in
case $(menu "Learn" " Keybindings\n Tmux keybindings\n Omarchy\n Hyprland\n󰣇 Arch\n Neovim\n󱆃 Bash") in
*Tmux*) omarchy-menu-tmux-keybindings ;;
*Keybindings*) omarchy-menu-keybindings ;;
*Omarchy*) omarchy-launch-webapp "https://learn.omacom.io/2/the-omarchy-manual" ;;
*Hyprland*) omarchy-launch-webapp "https://wiki.hypr.land/" ;;
@@ -120,7 +126,7 @@ show_custom_reminder_input() {
if [[ $minutes =~ ^[0-9]+$ ]] && ((minutes > 0)); then
show_reminder_message_input "$minutes"
elif [[ -n $minutes ]]; then
omarchy-notification-send "󰔛" "Invalid reminder" "Enter the number of minutes" -u critical
omarchy-notification-send -g 󰔛 "Invalid reminder" "Enter the number of minutes" -u critical
show_custom_reminder_input
else
back_to show_reminder_menu
@@ -195,7 +201,8 @@ show_screenrecord_menu() {
}
show_share_menu() {
case $(menu "Share" " Clipboard\n File \n Folder") in
case $(menu "Share" " Clipboard\n File \n Folder\n󰥦 Receive") in
*Receive*) uwsm-app -- localsend ;;
*Clipboard*) omarchy-menu-share clipboard ;;
*File*) terminal bash -c "omarchy-menu-share file" ;;
*Folder*) terminal bash -c "omarchy-menu-share folder" ;;
@@ -233,13 +240,18 @@ show_hardware_menu() {
options="$options\n󰟸 Touchpad"
fi
if omarchy-hw-dell-xps-haptic-touchpad && omarchy-cmd-present dell-xps-touchpad-haptics; then
options="$options\n󰌌 Touchpad Haptics"
fi
if omarchy-hw-touchscreen; then
options="$options\n󰆽 Touchscreen"
fi
case $(menu "Toggle" "$options") in
*Laptop*) omarchy-hyprland-monitor-internal toggle ;;
*Mirror*) omarchy-hyprland-monitor-internal-mirror toggle;;
*Mirror*) omarchy-hyprland-monitor-internal-mirror toggle ;;
*Haptics*) show_hardware_touchpad_haptics_menu ;;
*Touchpad*) omarchy-toggle-touchpad ;;
*Touchscreen*) omarchy-toggle-touchscreen ;;
*"Hybrid GPU"*) present_terminal omarchy-toggle-hybrid-gpu ;;
@@ -247,19 +259,51 @@ show_hardware_menu() {
esac
}
show_hardware_touchpad_haptics_menu() {
local current=$(dell-xps-touchpad-haptics get)
local selected=$(menu "Touchpad Haptics" "low\nmid\nhigh" "" "$current")
if [[ -n $selected ]]; then
dell-xps-touchpad-haptics set "$selected"
else
back_to show_hardware_menu
fi
}
show_style_menu() {
case $(menu "Style" "󰸌 Theme\n󰟵 Unlock\n Font\n Background\n Hyprland\n󱄄 Screensaver\n About") in
case $(menu "Style" "󰸌 Theme\n󰟵 Unlock\n Font\n Background\n󰍜 Waybar\n󰘇 Corners\n Hyprland\n󱄄 Screensaver\n About") in
*Theme*) show_theme_menu ;;
*Unlock*) omarchy-launch-walker -m menus:omarchyunlocks --width 800 --minheight 400 ;;
*Font*) show_font_menu ;;
*Background*) show_background_menu ;;
*Hyprland*) open_in_editor ~/.config/hypr/looknfeel.conf ;;
*Corners*) show_style_corners_menu ;;
*Hyprland*) open_in_editor "$(hypr_config_file looknfeel)" ;;
*Waybar*) show_waybar_position_menu ;;
*Screensaver*) show_screensaver_menu ;;
*About*) show_about_menu ;;
*) show_main_menu ;;
esac
}
show_style_corners_menu() {
case $(omarchy-menu-select "Corners" "󰝣 Sharp" "󰘇 Round") in
*Sharp*) omarchy-style-corners sharp ;;
*Round*) omarchy-style-corners round ;;
*) show_style_menu ;;
esac
}
show_waybar_position_menu() {
case $(menu "Waybar Position" "󰁝 Top\n󰁅 Bottom\n󰁍 Left\n󰁔 Right") in
*Top*) omarchy-style-waybar-position top ;;
*Bottom*) omarchy-style-waybar-position bottom ;;
*Left*) omarchy-style-waybar-position left ;;
*Right*) omarchy-style-waybar-position right ;;
*) show_style_menu ;;
esac
}
show_about_menu() {
case $(menu "About" " Edit Text\n Set From Image\n Restore Default") in
*Text*) omarchy-branding-about text ;;
@@ -279,11 +323,13 @@ show_screensaver_menu() {
}
show_theme_menu() {
omarchy-launch-walker -m menus:omarchythemes --width 800 --minheight 400
theme=$(omarchy-theme-switcher)
[[ -n $theme ]] && omarchy-theme-set "$theme"
}
show_background_menu() {
omarchy-launch-walker -m menus:omarchyBackgroundSelector --width 800 --minheight 400
background=$(omarchy-theme-bg-switcher)
[[ -n $background ]] && omarchy-theme-bg-set "$background"
}
show_font_menu() {
@@ -297,8 +343,8 @@ show_font_menu() {
show_setup_menu() {
local options=" Audio\n Wifi\n󰂯 Bluetooth\n󱐋 Power Profile\n System Sleep\n󰍹 Monitors"
[[ -f ~/.config/hypr/bindings.conf ]] && options="$options\n Keybindings"
[[ -f ~/.config/hypr/input.conf ]] && options="$options\n Input"
[[ -f ~/.config/hypr/bindings.lua ]] && options="$options\n Keybindings"
[[ -f ~/.config/hypr/input.lua ]] && options="$options\n Input"
options="$options\n Defaults\n󰱔 DNS\n Security\n Config"
case $(menu "Setup" "$options") in
@@ -307,9 +353,9 @@ show_setup_menu() {
*Bluetooth*) omarchy-launch-bluetooth ;;
*Power*) show_setup_power_menu ;;
*System*) show_setup_system_menu ;;
*Monitors*) open_in_editor ~/.config/hypr/monitors.conf ;;
*Keybindings*) open_in_editor ~/.config/hypr/bindings.conf ;;
*Input*) open_in_editor ~/.config/hypr/input.conf ;;
*Monitors*) open_in_editor "$(hypr_config_file monitors)" ;;
*Keybindings*) open_in_editor "$(hypr_config_file bindings)" ;;
*Input*) open_in_editor "$(hypr_config_file input)" ;;
*Defaults*) show_setup_default_menu ;;
*DNS*) present_terminal omarchy-setup-dns ;;
*Security*) show_setup_security_menu ;;
@@ -444,7 +490,7 @@ show_setup_default_editor_menu() {
show_setup_config_menu() {
case $(menu "Setup" " Hyprland\n Hypridle\n Hyprlock\n Hyprsunset\n Swayosd\n󰌧 Walker\n󰍜 Waybar\n󰞅 XCompose") in
*Hyprland*) open_in_editor ~/.config/hypr/hyprland.conf ;;
*Hyprland*) open_in_editor "$(hypr_config_file hyprland)" ;;
*Hypridle*) open_in_editor ~/.config/hypr/hypridle.conf && omarchy-restart-hypridle ;;
*Hyprlock*) open_in_editor ~/.config/hypr/hyprlock.conf ;;
*Hyprsunset*) open_in_editor ~/.config/hypr/hyprsunset.conf && omarchy-restart-hyprsunset ;;
@@ -511,11 +557,12 @@ show_install_browser_menu() {
}
show_install_service_menu() {
case $(menu "Install" " Dropbox\n Tailscale\n󱇱 NordVPN [AUR]\n󰏖 ONCE\n󰟵 Bitwarden\n Chromium Account") in
case $(menu "Install" " Dropbox\n Tailscale\n󱇱 NordVPN [AUR]\n󰏖 ONCE\n☀ Sunshine\n󰟵 Bitwarden\n Chromium Account") in
*Dropbox*) present_terminal omarchy-install-dropbox ;;
*Tailscale*) present_terminal omarchy-install-tailscale ;;
*NordVPN*) present_terminal omarchy-install-nordvpn ;;
*ONCE*) present_terminal omarchy-install-once ;;
*Sunshine*) present_terminal omarchy-install-service-sunshine ;;
*Bitwarden*) install_and_launch "Bitwarden" "bitwarden bitwarden-cli" "bitwarden" ;;
*Chromium*) present_terminal omarchy-install-chromium-google-account ;;
*) show_install_menu ;;
@@ -562,8 +609,9 @@ show_install_ai_menu() {
}
show_install_gaming_menu() {
case $(menu "Install" " Steam\n RetroArch\n󰍳 Minecraft\n󰢹 NVIDIA GeForce NOW\n Xbox Cloud Gaming\n󰂯 Xbox Controller\n󰍹 Moonlight (GameStream)\n Lutris (Battle.net)\n󱓟 Heroic (Epic Games)") in
case $(menu "Install" " Steam\n󰯉 RetroArch\n󰍳 Minecraft\n󰢹 NVIDIA GeForce NOW\n Xbox Cloud Gaming\n󰂯 Xbox Controller\n󰍹 Moonlight (GameStream)\n Lutris (Battle.net)\n󱓟 Heroic (Epic Games)\n󰯉 RetroArch Game Launcher") in
*Steam*) present_terminal omarchy-install-gaming-steam ;;
*"RetroArch Game Launcher"*) omarchy-games-retro-install ;;
*RetroArch*) present_terminal omarchy-install-gaming-retroarch ;;
*Minecraft*) install_and_launch "Minecraft" "minecraft-launcher" "minecraft-launcher" ;;
*GeForce*) present_terminal omarchy-install-gaming-geforce-now ;;
+285
View File
@@ -0,0 +1,285 @@
#!/bin/bash
# omarchy:summary=Open a generic image selector menu
# omarchy:args=[--selected <image>] [--colors-file <path>] [--print-name] [--show-labels] [--filterable] [--lazy-thumbnails] [--cache-only] <image-dir>...
OMARCHY_PATH=${OMARCHY_PATH:-$HOME/.local/share/omarchy}
selected_image=""
colors_file=""
print_name=false
show_labels=false
filterable=false
lazy_thumbnails=false
prepare_only=false
cache_only=false
image_dirs=()
usage() {
echo "Usage: omarchy-menu-images [--selected <image>] [--colors-file <path>] [--print-name] [--show-labels] [--filterable] [--lazy-thumbnails] [--cache-only] <image-dir>..."
}
while [[ $# -gt 0 ]]; do
case "$1" in
--selected)
if (( $# < 2 )); then
usage >&2
exit 1
fi
selected_image="$2"
shift 2
;;
--colors-file)
if (( $# < 2 )); then
usage >&2
exit 1
fi
colors_file="$2"
shift 2
;;
--print-name)
print_name=true
shift
;;
--show-labels)
show_labels=true
shift
;;
--filterable)
filterable=true
shift
;;
--lazy-thumbnails)
lazy_thumbnails=true
shift
;;
--prepare-only)
prepare_only=true
shift
;;
--cache-only)
cache_only=true
shift
;;
--help|-h)
usage
exit 0
;;
*)
image_dirs+=("$1")
shift
;;
esac
done
if (( ${#image_dirs[@]} == 0 )); then
usage >&2
exit 1
fi
selection_file=$(mktemp)
done_file=$(mktemp)
rm -f "$done_file"
trap 'rm -f "$selection_file" "$done_file"' EXIT
socket_path="${XDG_RUNTIME_DIR:-/run/user/$UID}/omarchy-image-selector.sock"
selector_qml="$OMARCHY_PATH/default/quickshell/select-by-image.qml"
image_dirs_env=""
for dir in "${image_dirs[@]}"; do
if [[ -z $image_dirs_env ]]; then
image_dirs_env="$dir"
else
image_dirs_env+=$'\n'"$dir"
fi
done
current_image=$(readlink -f "$selected_image" 2>/dev/null)
selected_list_image=""
if [[ -n $current_image ]]; then
for dir in "${image_dirs[@]}"; do
if [[ -d $dir && -f $selected_image && ${selected_image%/*} == "$dir" ]]; then
selected_list_image="$selected_image"
break
elif [[ -d $dir ]]; then
selected_list_image=$(find -L "$dir" -maxdepth 1 -type f -samefile "$current_image" -print -quit 2>/dev/null)
[[ -n $selected_list_image ]] && break
fi
done
fi
cache_dir=${XDG_CACHE_HOME:-$HOME/.cache}/omarchy/image-selector
index_file="$cache_dir/index.tsv"
rows=""
mkdir -p "$cache_dir"
cache_key=$(printf '%s' "$image_dirs_env" | md5sum | cut -d ' ' -f 1)
rows_cache_file="$cache_dir/$cache_key.rows"
rows_signature_file="$cache_dir/$cache_key.signature"
rows_signature="v2"$'\n'
rows_cacheable=true
image_files=()
for dir in "${image_dirs[@]}"; do
if [[ -d $dir ]]; then
rows_signature+="$dir:$(stat -Lc '%Y' "$dir")"$'\n'
while IFS= read -r -d '' image; do
image_files+=("$image")
image_signature=$(stat -Lc '%s:%Y' "$image") || continue
rows_signature+="$image:$image_signature"$'\n'
done < <(find -L "$dir" -maxdepth 1 -type f \( -iname '*.jpg' -o -iname '*.jpeg' -o -iname '*.png' -o -iname '*.gif' -o -iname '*.bmp' -o -iname '*.webp' \) -print0 2>/dev/null | sort -z)
fi
done
generate_thumbnail() {
local image="$1"
local thumbnail="$2"
local lock="$thumbnail.lock"
local tmp="$thumbnail.$$.jpg"
if mkdir "$lock" 2>/dev/null; then
if magick "${image}[0]" -auto-orient -resize '1536x864^' -gravity center -extent '1536x864' -strip -quality 82 "$tmp"; then
mv -f "$tmp" "$thumbnail"
else
rm -f "$tmp" "$thumbnail"
fi
rmdir "$lock" 2>/dev/null || true
else
for ((i = 0; i < 3000; i++)); do
[[ -f $thumbnail ]] && return
[[ -d $lock ]] || break
sleep 0.01
done
fi
}
thumbnail_for() {
local image="$1"
local signature hash thumbnail
signature=$(stat -Lc '%s:%Y' "$image") || return
hash=$(awk -F '\t' -v path="$image" -v sig="$signature" '$1 == path && $2 == sig { print $3; exit }' "$index_file" 2>/dev/null)
if [[ -z $hash ]]; then
hash=$(printf '%s\t%s' "$image" "$signature" | md5sum | cut -d ' ' -f 1)
printf '%s\t%s\t%s\n' "$image" "$signature" "$hash" >>"$index_file"
fi
thumbnail="$cache_dir/$hash.jpg"
if [[ ! -f $thumbnail ]]; then
if [[ $lazy_thumbnails == true && $cache_only != true ]]; then
rows_cacheable=false
if [[ $prepare_only != true ]]; then
generate_thumbnail "$image" "$thumbnail" >/dev/null 2>&1 &
fi
printf '%s' "$image"
return
fi
generate_thumbnail "$image" "$thumbnail"
fi
[[ -f $thumbnail ]] && printf '%s' "$thumbnail"
}
if [[ -f $rows_cache_file && -f $rows_signature_file ]] && cmp -s "$rows_signature_file" <(printf '%s' "$rows_signature"); then
rows=$(<"$rows_cache_file")
else
for image in "${image_files[@]}"; do
thumbnail=$(thumbnail_for "$image")
[[ -n $thumbnail ]] || continue
if [[ $lazy_thumbnails == true && $cache_only != true && $thumbnail == "$image" ]]; then
rows_cacheable=false
fi
if [[ -z $rows ]]; then
rows="$image"$'\t'"$thumbnail"
else
rows+=$'\n'"$image"$'\t'"$thumbnail"
fi
done
if [[ $rows_cacheable == true ]]; then
printf '%s' "$rows" >"$rows_cache_file"
printf '%s' "$rows_signature" >"$rows_signature_file"
else
rm -f "$rows_cache_file" "$rows_signature_file"
fi
fi
rows_payload=${rows//$'\t'/$'\f'}
rows_payload=${rows_payload//$'\n'/$'\v'}
colors_file=${colors_file:-$HOME/.config/omarchy/current/theme/quickshell.json}
colors_payload=""
if [[ -f $colors_file ]]; then
colors_payload=$(<"$colors_file")
colors_payload=${colors_payload//$'\t'/$'\f'}
colors_payload=${colors_payload//$'\n'/$'\v'}
fi
if [[ $cache_only == true || $prepare_only == true ]]; then
exit 0
fi
ensure_selector() {
if [[ -S $socket_path && $selector_qml -nt $socket_path ]]; then
quickshell kill -p "$selector_qml" >/dev/null 2>&1 || true
rm -f "$socket_path"
fi
if [[ ! -S $socket_path ]]; then
quickshell kill -p "$selector_qml" >/dev/null 2>&1 || true
quickshell -d -p "$selector_qml" >/dev/null
for ((i = 0; i < 100; i++)); do
if [[ -S $socket_path ]]; then
break
fi
sleep 0.01
done
fi
[[ -S $socket_path ]]
}
send_request() {
printf '%s\t%s\t%s\t%s\t%s\t%s\t%s\n' "$rows_payload" "$selected_list_image" "$selection_file" "$done_file" "$colors_payload" "$show_labels" "$filterable" |
socat -u - "UNIX-CONNECT:$socket_path"
}
if ! ensure_selector; then
echo "Image selector failed to start" >&2
exit 1
fi
if ! send_request; then
rm -f "$socket_path"
if ! ensure_selector || ! send_request; then
echo "Image selector failed to accept request" >&2
exit 1
fi
fi
while [[ ! -e $done_file ]]; do
sleep 0.01
done
if [[ -s $selection_file ]]; then
if [[ $print_name == true ]]; then
selection=$(<"$selection_file")
selection=${selection##*/}
printf '%s\n' "${selection%.*}"
else
cat "$selection_file"
fi
fi
+219 -39
View File
@@ -3,6 +3,28 @@
# omarchy:summary=Display Hyprland keybindings defined in your configuration using walker for an interactive search menu.
declare -A KEYCODE_SYM_MAP
# Hyprland reports XKB keycodes for code: bindings. Keep a small fallback for
# common keys so the menu remains readable if xkbcli cannot resolve a symbol.
declare -A FALLBACK_KEYCODE_SYM_MAP=(
[10]="1"
[11]="2"
[12]="3"
[13]="4"
[14]="5"
[15]="6"
[16]="7"
[17]="8"
[18]="9"
[19]="0"
[20]="MINUS"
[21]="EQUAL"
[61]="SLASH"
)
# Hyprland's Lua config provider currently reports code:... binds from hl.bind()
# as key="" and keycode=0 in `hyprctl -j binds`. Keep a lightweight
# source-derived key cache so the menu can still show those bindings.
declare -A LUA_BIND_KEY_MAP
build_keymap_cache() {
local keymap
@@ -37,7 +59,18 @@ build_keymap_cache() {
}
lookup_keycode_cached() {
printf '%s\n' "${KEYCODE_SYM_MAP[$1]}"
local symbol
symbol="${KEYCODE_SYM_MAP[$1]}"
if [[ -z $symbol ]]; then
symbol="${FALLBACK_KEYCODE_SYM_MAP[$1]}"
fi
if [[ -z $symbol ]]; then
symbol="code:$1"
fi
printf '%s\n' "${symbol^^}"
}
parse_keycodes() {
@@ -80,44 +113,151 @@ parse_keycodes() {
fi
}
# Fetch dynamic keybindings from Hyprland
# Supplement `hyprctl -j binds` for Lua-only binds that Hyprland currently
# reports without their original key, such as hl.bind("SUPER + code:10", ...).
build_lua_bind_key_cache() {
local modmask description key
omarchy-cmd-present lua || return 0
while IFS=$'\t' read -r modmask description key; do
[[ -z $modmask || -z $description || -z $key ]] && continue
LUA_BIND_KEY_MAP["$modmask,$description"]="$key"
done < <(
lua <<'LUA'
local modifiers = { SHIFT = 1, CTRL = 4, CONTROL = 4, ALT = 8, SUPER = 64 }
local function split_keys(keys)
local modmask = 0
local key = ""
for part in string.gmatch(keys, "[^+]+") do
local value = part:gsub("^%s+", ""):gsub("%s+$", "")
local modifier = modifiers[string.upper(value)]
if modifier then
modmask = modmask + modifier
else
key = value
end
end
return modmask, key
end
local function proxy()
local p = {}
return setmetatable(p, {
__index = function()
return p
end,
__call = function()
return p
end,
})
end
local p = proxy()
hl = setmetatable({
dsp = p,
bind = function(keys, _, opts)
opts = opts or {}
if opts.description and opts.description ~= "" then
local modmask, key = split_keys(keys)
print(modmask .. "\t" .. opts.description .. "\t" .. key)
end
return p
end,
unbind = function() end,
config = function() end,
env = function() end,
monitor = function() end,
window_rule = function() end,
gesture = function() end,
animation = function() end,
curve = function() end,
exec_cmd = function() end,
}, {
__index = function()
return function()
return p
end
end,
})
local config = os.getenv("HOME") .. "/.config/hypr/hyprland.lua"
local file = io.open(config, "r")
if file then
file:close()
local ok, err = pcall(dofile, config)
if not ok and os.getenv("DEBUG") == "1" then
io.stderr:write("[DEBUG] lua bind scan failed: " .. tostring(err) .. "\n")
end
end
LUA
)
}
modmask_to_text() {
case "$1" in
0) printf '' ;;
1) printf 'SHIFT' ;;
4) printf 'CTRL' ;;
5) printf 'SHIFT CTRL' ;;
8) printf 'ALT' ;;
9) printf 'SHIFT ALT' ;;
12) printf 'CTRL ALT' ;;
13) printf 'SHIFT CTRL ALT' ;;
64) printf 'SUPER' ;;
65) printf 'SUPER SHIFT' ;;
68) printf 'SUPER CTRL' ;;
69) printf 'SUPER SHIFT CTRL' ;;
72) printf 'SUPER ALT' ;;
73) printf 'SUPER SHIFT ALT' ;;
76) printf 'SUPER CTRL ALT' ;;
77) printf 'SUPER SHIFT CTRL ALT' ;;
*) printf '%s' "$1" ;;
esac
}
# Fetch dynamic keybindings from Hyprland.
#
# Also do some pre-processing:
# - Fill missing Lua code:... keys from the Lua source cache
# - Remove standard Omarchy bin path prefix
# - Remove uwsm prefix
# - Map numeric modifier key mask to a textual rendition
# - Output comma-separated values that the parser can understand
dynamic_bindings() {
local modmask key keycode description dispatcher arg modifiers
hyprctl -j binds |
jq -r '.[] | {modmask, key, keycode, description, dispatcher, arg} | "\(.modmask),\(.key)@\(.keycode),\(.description),\(.dispatcher),\(.arg)"' |
sed -r \
-e 's/null//' \
-e 's,~/.local/share/omarchy/bin/,,' \
-e 's,uwsm app -- ,,' \
-e 's,uwsm-app -- ,,' \
-e 's/@0//' \
-e 's/,@/,code:/' \
-e 's/^0,/,/' \
-e 's/^1,/SHIFT,/' \
-e 's/^4,/CTRL,/' \
-e 's/^5,/SHIFT CTRL,/' \
-e 's/^8,/ALT,/' \
-e 's/^9,/SHIFT ALT,/' \
-e 's/^12,/CTRL ALT,/' \
-e 's/^13,/SHIFT CTRL ALT,/' \
-e 's/^64,/SUPER,/' \
-e 's/^65,/SUPER SHIFT,/' \
-e 's/^68,/SUPER CTRL,/' \
-e 's/^69,/SUPER SHIFT CTRL,/' \
-e 's/^72,/SUPER ALT,/' \
-e 's/^73,/SUPER SHIFT ALT,/' \
-e 's/^76,/SUPER CTRL ALT,/' \
-e 's/^77,/SUPER SHIFT CTRL ALT,/'
jq -r '.[] | [.modmask, (.key // ""), (.keycode // 0), (.description // ""), (.dispatcher // ""), (.arg // "") | tostring] | join("\u001f")' |
while IFS=$'\x1f' read -r modmask key keycode description dispatcher arg; do
if [[ -z $key && $keycode != "0" ]]; then
key="code:$keycode"
fi
if [[ -z $key && -n $description ]]; then
key="${LUA_BIND_KEY_MAP["$modmask,$description"]}"
fi
[[ -z $description && $dispatcher == "__lua" ]] && continue
modifiers=$(modmask_to_text "$modmask")
arg="${arg//~\/.local\/share\/omarchy\/bin\//}"
arg="${arg//uwsm app -- /}"
arg="${arg//uwsm-app -- /}"
printf '%s,%s,%s,%s,%s\n' "$modifiers" "$key" "$description" "$dispatcher" "$arg"
done
}
# Hardcoded bindings, like the copy-url extension and such
static_bindings() {
echo "SHIFT ALT,L,Copy URL from Web App,extension,copy-url"
echo "SHIFT ALT,L,Copy URL from Web App,sendshortcut,SHIFT ALT,L,"
}
# Parse and format keybindings
@@ -126,8 +266,8 @@ static_bindings() {
# - Set the field separator to a comma ','.
# - Joins the key combination (e.g., "SUPER + Q").
# - Joins the command that the key executes.
# - Prints everything in a nicely aligned format.
parse_bindings() {
# - Prints display text and dispatch metadata as tab-separated fields.
parse_binding_records() {
awk -F, '
{
# Combine the modifier and key (first two fields)
@@ -139,6 +279,13 @@ parse_bindings() {
# Use description, if set
action = $3;
dispatcher = $4;
# Reconstruct the dispatcher arg from the remaining fields
arg = "";
for (i = 5; i <= NF; i++) {
arg = arg $i (i < NF ? "," : "");
}
if (action == "") {
# Reconstruct the command from the remaining fields
@@ -149,6 +296,7 @@ parse_bindings() {
# Clean up trailing commas, remove leading "exec, ", and trim
sub(/,$/, "", action);
gsub(/(^|,)[[:space:]]*exec[[:space:]]*,?/, "", action);
gsub(/(^|[[:space:]])uwsm(-app| app)[[:space:]]+--[[:space:]]+/, "", action);
gsub(/^[ \t]+|[ \t]+$/, "", action);
gsub(/[ \t]+/, " ", key_combo); # Collapse multiple spaces to one
@@ -161,15 +309,15 @@ parse_bindings() {
}
if (action != "") {
printf "%-35s → %s\n", key_combo, action;
printf "%-35s → %s\t%s\t%s\n", key_combo, action, dispatcher, arg;
}
}'
}
prioritize_entries() {
awk '
awk -F '\t' '
{
line = $0
line = $1
prio = 50
if (match(line, /Terminal/)) prio = 0
if (match(line, /Tmux/)) prio = 1
@@ -220,15 +368,16 @@ prioritize_entries() {
if (match(line, /Apple Display/)) prio = 98
if (match(line, /XF86/)) prio = 99
# print "priority<TAB>line"
printf "%d\t%s\n", prio, line
# print "priority<TAB>record"
printf "%d\t%s\n", prio, $0
}' |
sort -k1,1n -k2,2 |
cut -f2-
}
output_keybindings() {
output_binding_records() {
build_keymap_cache
build_lua_bind_key_cache
{
dynamic_bindings
@@ -236,16 +385,47 @@ output_keybindings() {
} |
sort -u |
parse_keycodes |
parse_bindings |
parse_binding_records |
prioritize_entries
}
output_keybindings() {
output_binding_records | cut -f1
}
dispatch_binding() {
local dispatcher="$1"
local arg="$2"
case "$dispatcher" in
exec)
[[ -n $arg ]] && hyprctl dispatch exec "$arg"
;;
"") return 1 ;;
*)
if [[ -n $arg ]]; then
hyprctl dispatch "$dispatcher" "$arg"
else
hyprctl dispatch "$dispatcher"
fi
;;
esac
}
if [[ $1 == "--print" || $1 == "-p" ]]; then
output_keybindings
else
records=$(output_binding_records)
monitor_height=$(hyprctl monitors -j | jq -r '.[] | select(.focused == true) | .height')
menu_height=$((monitor_height * 40 / 100))
selection=$(cut -f1 <<<"$records" |
walker --dmenu -p 'Keybindings' --width 800 --height "$menu_height")
output_keybindings |
walker --dmenu -p 'Keybindings' --width 800 --height "$menu_height"
if [[ -n $selection ]]; then
record=$(awk -F '\t' -v selection="$selection" '$1 == selection { print; exit }' <<<"$records")
dispatcher=$(cut -f2 <<<"$record")
arg=$(cut -f3- <<<"$record")
dispatch_binding "$dispatcher" "$arg"
fi
fi
+248
View File
@@ -0,0 +1,248 @@
#!/bin/bash
# omarchy:summary=Display Tmux keybindings defined in your configuration using walker for an interactive search menu.
# omarchy:args=[--print|-p] [--config <path>]
print_only=false
config_file="${TMUX_CONF:-$HOME/.config/tmux/tmux.conf}"
while (($#)); do
case "$1" in
--print|-p)
print_only=true
;;
--config)
shift
config_file="$1"
;;
*)
config_file="$1"
;;
esac
shift
done
if [[ ! -f $config_file ]]; then
default_config="${OMARCHY_PATH:-$HOME/.local/share/omarchy}/config/tmux/tmux.conf"
if [[ -f $default_config ]]; then
config_file="$default_config"
else
echo "Tmux config not found: $config_file" >&2
exit 1
fi
fi
output_keybindings() {
awk '
function trim(value) {
gsub(/^[ \t]+|[ \t]+$/, "", value)
return value
}
function key_part_text(part, is_modifier, part_count) {
gsub(/^\\/, "", part)
if (is_modifier && part == "C") return "CTRL"
if (is_modifier && part == "M") return "ALT"
if (is_modifier && part == "S") return "SHIFT"
if (part == "Space") return "SPACE"
if (part == "BSpace") return "BACKSPACE"
if (part == "BTab") return "SHIFT + TAB"
if (part == "PPage") return "PAGE UP"
if (part == "NPage") return "PAGE DOWN"
if (part == "DC") return "DELETE"
if (part == "IC") return "INSERT"
if (part_count == 1 && part ~ /^[a-z]$/) return part
return toupper(part)
}
function key_text(key, parts, count, i, part, text) {
gsub(/\\/, "", key)
count = split(key, parts, "-")
text = ""
for (i = 1; i <= count; i++) {
part = key_part_text(parts[i], i < count, count)
text = text (text == "" ? "" : " + ") part
}
return text
}
function table_text(table) {
if (table == "copy-mode-vi") return "COPY MODE"
if (table == "copy-mode") return "COPY MODE"
if (table == "prefix") return "PREFIX"
gsub(/-/, " ", table)
return toupper(table)
}
function pretty_command(command) {
gsub(/\\;/, ";", command)
gsub(/[{}]/, "", command)
gsub(/^[ \t]+|[ \t]+$/, "", command)
gsub(/[ \t]+/, " ", command)
return command
}
function command_action(command, normalized, target) {
normalized = pretty_command(command)
if (normalized ~ /omarchy-menu-tmux-keybindings/) return "Show Tmux keybindings"
if (normalized ~ /^send(-keys)? -X begin-selection/) return "Begin selection"
if (normalized ~ /^send(-keys)? -X copy-selection-and-cancel/) return "Copy selection"
if (normalized ~ /^send-prefix/) return "Send prefix"
if (normalized ~ /^source-file/) return "Reload config"
if (normalized ~ /^split-window -v/) return "Split pane vertically"
if (normalized ~ /^split-window -h/) return "Split pane horizontally"
if (normalized ~ /^kill-pane/) return "Kill pane"
if (normalized ~ /^select-pane -L/) return "Focus pane left"
if (normalized ~ /^select-pane -R/) return "Focus pane right"
if (normalized ~ /^select-pane -U/) return "Focus pane up"
if (normalized ~ /^select-pane -D/) return "Focus pane down"
if (normalized ~ /^resize-pane -L/) return "Resize pane left"
if (normalized ~ /^resize-pane -R/) return "Resize pane right"
if (normalized ~ /^resize-pane -U/) return "Resize pane up"
if (normalized ~ /^resize-pane -D/) return "Resize pane down"
if (normalized ~ /^swap-pane -t "?left-of"?/) return "Move pane left"
if (normalized ~ /^swap-pane -t "?right-of"?/) return "Move pane right"
if (normalized ~ /^swap-pane -t "?up-of"?/) return "Move pane up"
if (normalized ~ /^swap-pane -t "?down-of"?/) return "Move pane down"
if (normalized ~ /^swap-pane -U/) return "Move pane left"
if (normalized ~ /^swap-pane -D/) return "Move pane right"
if (normalized ~ /rename-window/) return "Rename window"
if (normalized ~ /^new-window/) return "New window"
if (normalized ~ /^kill-window/) return "Kill window"
if (match(normalized, /^select-window -t ([^ ;]+)/, target)) {
gsub(/^:=?/, "", target[1])
if (target[1] == "-1") return "Previous window"
if (target[1] == "+1") return "Next window"
return "Switch to window " target[1]
}
if (normalized ~ /^swap-window -t -1/) return "Move window left"
if (normalized ~ /^swap-window -t \+1/) return "Move window right"
if (normalized ~ /rename-session/) return "Rename session"
if (normalized ~ /^new-session/) return "New session"
if (normalized ~ /^kill-session/) return "Kill session"
if (normalized ~ /^switch-client -p/) return "Previous session"
if (normalized ~ /^switch-client -n/) return "Next session"
return normalized
}
function add_record(combo, action) {
records[++record_count] = sprintf("%-32s → %s", combo, action)
}
function parse_bind(line, words, count, i, table, global, key, command, combo, action) {
count = split(line, words, /[ \t]+/)
i = 2
table = "prefix"
global = 0
while (i <= count && words[i] ~ /^-/) {
if (words[i] == "-n") {
global = 1
i++
} else if (words[i] == "-T") {
table = words[i + 1]
i += 2
} else if (words[i] == "-r") {
i++
} else {
i++
}
}
key = words[i]
i++
command = ""
for (; i <= count; i++) {
command = command (command == "" ? "" : " ") words[i]
}
if (key == "" || command == "") return
if (global) {
combo = key_text(key)
} else if (table == "prefix") {
combo = "PREFIX + " key_text(key)
} else {
combo = table_text(table) " + " key_text(key)
}
action = command_action(command)
add_record(combo, action)
}
BEGIN {
prefix = "C-b"
prefix2 = ""
}
{
line = trim($0)
if (line == "") next
if (line ~ /^#/) next
if (line ~ /^(set|set-option|setw|set-window-option)[ \t]/) {
word_count = split(line, words, /[ \t]+/)
for (i = 2; i <= word_count; i++) {
if (words[i] == "prefix") prefix = words[i + 1]
if (words[i] == "prefix2") prefix2 = words[i + 1]
}
next
}
if (line ~ /^(bind|bind-key)[ \t]/) parse_bind(line)
}
END {
prefix_description = key_text(prefix)
if (prefix2 != "" && prefix2 != "None") {
prefix_description = prefix_description " / " key_text(prefix2)
}
printf "%-32s → %s\n", "PREFIX", prefix_description
add_record("PREFIX + {", "Move pane left")
add_record("PREFIX + }", "Move pane right")
for (i = 1; i <= record_count; i++) print records[i]
}
' "$config_file"
}
if [[ $print_only == "true" ]]; then
output_keybindings
exit 0
fi
records=$(output_keybindings)
if [[ -z $WAYLAND_DISPLAY ]] || omarchy-cmd-missing walker; then
printf '%s\n' "$records"
exit 0
fi
monitor_height=$(hyprctl monitors -j 2>/dev/null | jq -r '.[] | select(.focused == true) | .height' 2>/dev/null)
if [[ ! $monitor_height =~ ^[0-9]+$ ]] || ((monitor_height <= 0)); then
monitor_height=900
fi
menu_height=$((monitor_height * 40 / 100))
printf '%s\n' "$records" | walker --dmenu -p 'Tmux keybindings' --width 800 --height "$menu_height" >/dev/null
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Show the current battery status notification
omarchy-notification-send -g 󰁹 -u low "$(omarchy-battery-status)"
+57 -13
View File
@@ -1,32 +1,76 @@
#!/bin/bash
# omarchy:summary=Send a desktop notification with Omarchy glyph and body spacing
# omarchy:args=<glyph> <headline> [description] [notify-send options]
# omarchy:examples=omarchy notification send "󰔛" "Reminder" "5 minutes are up" -u critical
# omarchy:args=<headline> [description] [-g <glyph>] [-u <low|normal|critical>] [notify-send options]
# omarchy:examples=omarchy notification send "Reminder" "5 minutes are up" -g 󰔛 -u critical
set -euo pipefail
if (($# < 2)); then
echo "Usage: omarchy-notification-send <glyph> <headline> [description] [notify-send options]"
headline=""
description=""
glyph=""
urgency="low"
args=()
parse_omarchy_option() {
case $1 in
-g | --glyph)
if (($# < 2)); then
echo "Missing value for $1" >&2
exit 1
fi
glyph="$2"
return 0
;;
-u | --urgency)
if (($# < 2)); then
echo "Missing value for $1" >&2
exit 1
fi
urgency="$2"
return 0
;;
esac
return 1
}
while (($# > 0)); do
if parse_omarchy_option "$@"; then
shift 2
else
break
fi
done
if (($# < 1)); then
echo "Usage: omarchy-notification-send [-g <glyph>] [-u <low|normal|critical>] <headline> [description] [notify-send options]"
exit 1
fi
glyph=$1
headline=$2
description=${3:-}
shift 2
headline=$1
shift
if (($# > 0)) && [[ $1 != -* ]]; then
description=$1
shift
else
description=""
fi
while (($# > 0)); do
if parse_omarchy_option "$@"; then
shift 2
else
args+=("$1")
shift
fi
done
summary="$glyph $headline"
args+=("-u" "$urgency")
if [[ -n $description ]]; then
description=$(sed 's/^/ /' <<<"$description")
notify-send "$@" "$summary" "$description"
description=$(printf '%b' "$description" | sed 's/^/ /')
notify-send "${args[@]}" "$summary" "$description"
else
notify-send "$@" "$summary"
notify-send "${args[@]}" "$summary"
fi
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Show the current time and date notification
omarchy-notification-send -g  -u low "$(date +"%A %H:%M · %d %B %Y · Week %V")"
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash
# omarchy:summary=Show the current weather notification
omarchy-notification-send -g $(omarchy-weather-icon) -u low "$(omarchy-weather-status)"
@@ -1,10 +1,10 @@
#!/bin/bash
# omarchy:summary=Install an npx wrapper for a given npm package.
# omarchy:summary=Install a pnpm dlx wrapper for a given npm package.
# omarchy:args=<package> [command-name]
if [[ -z $1 ]]; then
echo "Usage: omarchy-npx-install <package> [command-name]"
echo "Usage: omarchy-npm-install <package> [command-name]"
exit 1
fi
@@ -23,8 +23,13 @@ if ! node_root="\$(mise where node@latest 2>/dev/null)"; then
node_root="\$(mise where node@latest)"
fi
node_bin="\$node_root/bin/node"
npx_bin="\$node_root/bin/npx"
if omarchy-cmd-missing pnpm; then
echo "Installing pnpm for \$package..."
omarchy-pkg-add pnpm
hash -r
fi
export PNPM_CONFIG_MINIMUM_RELEASE_AGE=7200
ensure_bin_runtime() {
local bin_path=\$1
@@ -51,15 +56,15 @@ exec_package_bin() {
fi
}
# Resolve the package bin inside npx, then run it with node@latest available for node shebangs.
# Resolve the package bin inside pnpm dlx, then run it with node@latest available for node shebangs.
# Some wrappers are aliases, e.g. playwright-cli wraps the playwright bin.
"\$node_bin" "\$npx_bin" --yes --prefer-online --package "\$package" -- true
PATH="\$node_root/bin:\$PATH" pnpm dlx --package "\$package" true
package_bin_path=\$("\$node_bin" "\$npx_bin" --yes --package "\$package" -- which "\$package" 2>/dev/null)
package_bin_path=\$(PATH="\$node_root/bin:\$PATH" pnpm dlx --package "\$package" which "\$package" 2>/dev/null)
exec_package_bin "\$package_bin_path" "\$@"
# Scoped packages like @openai/codex expose an unscoped bin like codex.
package_bin_path=\$("\$node_bin" "\$npx_bin" --yes --package "\$package" -- which "\$command" 2>/dev/null)
package_bin_path=\$(PATH="\$node_root/bin:\$PATH" pnpm dlx --package "\$package" which "\$command" 2>/dev/null)
exec_package_bin "\$package_bin_path" "\$@"
echo "Could not resolve npm bin for \$package / \$command" >&2
+5
View File
@@ -11,6 +11,11 @@ action="${1-}"
# events, and also avoids false negatives from per-port USB-C devices
# that are present-but-empty (online=0) while another port supplies power.
if [[ -z $action || $action == "autodetect" ]]; then
# On plug/unplug, udev fires the rule before sysfs `online` is updated
# on some laptops (notably Lenovo Yoga Pro 7 with USB-C charging). A
# short settle delay lets the kernel update before we read state.
sleep 0.3
action=battery
for ps in /sys/class/power_supply/*; do
[[ -r $ps/online && -r $ps/type ]] || continue
+5 -5
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# omarchy:summary=Ensure all default .desktop, web apps, TUIs, and npx wrappers are installed.
# omarchy:summary=Ensure all default .desktop, web apps, TUIs, and npm wrappers are installed.
mkdir -p ~/.local/share/icons/hicolor/48x48/apps/
cp ~/.local/share/omarchy/applications/icons/*.png ~/.local/share/icons/hicolor/48x48/apps/
@@ -11,14 +11,14 @@ mkdir -p ~/.local/share/applications
cp ~/.local/share/omarchy/applications/*.desktop ~/.local/share/applications/
cp ~/.local/share/omarchy/applications/hidden/*.desktop ~/.local/share/applications/
if omarchy-cmd-present foot; then
cp ~/.local/share/omarchy/default/foot/foot.desktop ~/.local/share/applications/
if omarchy-cmd-present alacritty; then
cp ~/.local/share/omarchy/default/alacritty/alacritty.desktop ~/.local/share/applications/
fi
# Refresh the webapps, TUIs, and npx wrappers
# Refresh the webapps, TUIs, and npm wrappers
bash $OMARCHY_PATH/install/packaging/icons.sh
bash $OMARCHY_PATH/install/packaging/webapps.sh
bash $OMARCHY_PATH/install/packaging/tuis.sh
bash $OMARCHY_PATH/install/packaging/npx.sh
bash $OMARCHY_PATH/install/packaging/npm.sh
update-desktop-database ~/.local/share/applications
+9 -7
View File
@@ -1,11 +1,13 @@
#!/bin/bash
# omarchy:summary=Overwrite all the user configs in ~/.config/hypr with the Omarchy defaults.
# omarchy:summary=Overwrite all the user Hyprland Lua configs in ~/.config/hypr with the Omarchy defaults.
omarchy-refresh-config hypr/autostart.conf
omarchy-refresh-config hypr/bindings.conf
omarchy-refresh-config hypr/input.conf
omarchy-refresh-config hypr/looknfeel.conf
omarchy-refresh-config hypr/hyprland.conf
omarchy-refresh-config hypr/monitors.conf
omarchy-refresh-config hypr/.luarc.json
omarchy-refresh-config hypr/autostart.lua
omarchy-refresh-config hypr/bindings.lua
omarchy-refresh-config hypr/input.lua
omarchy-refresh-config hypr/looknfeel.lua
omarchy-refresh-config hypr/hyprland.lua
omarchy-refresh-config hypr/monitors.lua
bash "$OMARCHY_PATH/install/config/omarchy-toggles.sh"
bash "$OMARCHY_PATH/install/config/detect-keyboard-layout.sh"
+3
View File
@@ -19,5 +19,8 @@ echo
sudo cp -f "$OMARCHY_PATH/default/pacman/pacman-$channel.conf" /etc/pacman.conf
sudo cp -f "$OMARCHY_PATH/default/pacman/mirrorlist-$channel" /etc/pacman.d/mirrorlist
# Allow user customization of /etc/pacman.conf before the upgrade runs
omarchy-hook pre-refresh-pacman
# Reset all package DBs and then update
sudo pacman -Syyuu --noconfirm
+11
View File
@@ -3,6 +3,17 @@
# omarchy:summary=Reset Waybar config to Omarchy defaults
# omarchy:examples=omarchy refresh waybar
WAYBAR_CONFIG="$HOME/.config/waybar/config.jsonc"
position=$(sed -nE 's/.*"position"[[:space:]]*:[[:space:]]*"(top|bottom|left|right)".*/\1/p' "$WAYBAR_CONFIG" 2>/dev/null | head -n 1)
height=$(sed -nE 's/.*"height"[[:space:]]*:[[:space:]]*([0-9]+).*/\1/p' "$WAYBAR_CONFIG" 2>/dev/null | head -n 1)
width=$(sed -nE 's/.*"width"[[:space:]]*:[[:space:]]*([0-9]+).*/\1/p' "$WAYBAR_CONFIG" 2>/dev/null | head -n 1)
omarchy-refresh-config waybar/config.jsonc
omarchy-refresh-config waybar/style.css
[[ -n $position ]] && sed -i -E "s/(\"position\"[[:space:]]*:[[:space:]]*\")[a-z]+(\")/\\1${position}\\2/" "$WAYBAR_CONFIG"
[[ -n $height ]] && sed -i -E "s/(\"height\"[[:space:]]*:[[:space:]]*)[0-9]+/\\1${height}/" "$WAYBAR_CONFIG"
[[ -n $width ]] && sed -i -E "s/(\"width\"[[:space:]]*:[[:space:]]*)[0-9]+/\\1${width}/" "$WAYBAR_CONFIG"
omarchy-restart-waybar
+2 -2
View File
@@ -1,11 +1,11 @@
#!/bin/bash
# omarchy:summary=Reinstall the Omarchy source directory from git
# omarchy:summary=Reinstall the stable Omarchy source directory from git
set -e
# Reinstall the Omarchy configuration directory from the git source.
git clone --depth=1 "https://github.com/basecamp/omarchy.git" ~/.local/share/omarchy-new >/dev/null
git clone --depth=1 --branch master "https://github.com/basecamp/omarchy.git" ~/.local/share/omarchy-new >/dev/null
mv $OMARCHY_PATH ~/.local/share/omarchy-old
mv ~/.local/share/omarchy-new $OMARCHY_PATH
+15 -18
View File
@@ -41,21 +41,18 @@ parse_systemd_timespan() {
}
show_reminders() {
local timers timer next next_seconds uptime remaining body=""
local timer next remaining body=""
local reminder_dir="${XDG_RUNTIME_DIR:-/tmp}/omarchy-reminders"
local reminder_message=""
local now=$(date +%s)
timers=$(systemctl --user list-timers --all --no-legend --no-pager "omarchy-reminder-*.timer" 2>/dev/null | awk '{ print $(NF - 1) }')
uptime=${SECONDS_SINCE_BOOT:-$(awk '{ print int($1) }' /proc/uptime)}
while IFS=$'\t' read -r timer next; do
[[ -z $timer || -z $next ]] && continue
for timer in $timers; do
next=$(systemctl --user show -P NextElapseUSecMonotonic "$timer" 2>/dev/null || true)
[[ -z $next ]] && continue
next=$((next / 1000000))
((next <= now)) && continue
next_seconds=$(parse_systemd_timespan "$next")
((next_seconds <= uptime)) && continue
remaining=$((next_seconds - uptime))
remaining=$((next - now))
reminder=${timer%.timer}
reminder=${reminder#omarchy-reminder-}
set_at=${reminder##*-}
@@ -64,16 +61,16 @@ show_reminders() {
[[ -f $reminder_dir/${timer%.timer}.message ]] && reminder_message=$(<"$reminder_dir/${timer%.timer}.message")
if [[ -n $reminder_message ]]; then
body+="$reminder_message in $(format_remaining $remaining) ($(date -d "@$((set_at + reminder_minutes * 60))" +%-H:%M))"$'\n'
body+="$reminder_message in $(format_remaining $remaining) ($(date -d "@$next" +%-H:%M))"$'\n'
else
body+="${reminder_minutes}-min reminder in $(format_remaining $remaining) ($(date -d "@$((set_at + reminder_minutes * 60))" +%-H:%M))"$'\n'
body+="${reminder_minutes}-min reminder in $(format_remaining $remaining) ($(date -d "@$next" +%-H:%M))"$'\n'
fi
done
done < <(systemctl --user list-timers --all --output=json "omarchy-reminder-*.timer" 2>/dev/null | jq -r '.[] | [.unit, .next] | @tsv')
if [[ -z $body ]]; then
omarchy-notification-send "󰔛" "Upcoming reminders" "No outstanding reminders" -u low
omarchy-notification-send -g 󰔛 "Upcoming reminders" "No outstanding reminders"
else
omarchy-notification-send "󰔛" "Upcoming reminders" "${body%$'\n'}" -u low
omarchy-notification-send -g 󰔛 "Upcoming reminders" "${body%$'\n'}"
fi
}
@@ -88,7 +85,7 @@ clear_reminders() {
fi
rm -f "$reminder_dir"/omarchy-reminder-*.message 2>/dev/null || true
omarchy-notification-send "󰔛" "All reminders have been cleared" -u low
omarchy-notification-send -g 󰔛 "All reminders have been cleared"
}
case ${1:-} in
@@ -134,6 +131,6 @@ if [[ -n $custom_message ]]; then
fi
systemd-run --user --quiet --collect --on-active="${minutes}m" --unit="$unit" \
bash -c 'omarchy-notification-send "󰔛" "Reminder" "$1" -u critical; rm -f "$2"' bash "$message" "$message_file"
bash -c 'omarchy-notification-send -g 󰔛 "Reminder" "$1" -u critical; rm -f "$2"' bash "$message" "$message_file"
omarchy-notification-send "󰔛" "$confirmation_title" "$confirmation" -u low
omarchy-notification-send -g 󰔛 "$confirmation_title" "$confirmation"
+4 -1
View File
@@ -21,7 +21,10 @@ omarchy-pkg-drop \
libretro-parallel-n64 libretro-picodrive libretro-play libretro-ppsspp \
libretro-sameboy libretro-scummvm libretro-shaders-slang libretro-snes9x \
libretro-yabause \
libretro-cap32-git libretro-fbneo-git libretro-uae-git libretro-vice-git \
libretro-cap32-git libretro-fbneo-git libretro-uae-git \
libretro-vice-x128-git libretro-vice-x64-git libretro-vice-x64dtv-git libretro-vice-x64sc-git \
libretro-vice-xcbm2-git libretro-vice-xcbm5x0-git libretro-vice-xpet-git \
libretro-vice-xplus4-git libretro-vice-xscpu64-git libretro-vice-xvic-git \
retroarch-joypad-autoconfig-git
rm -rf \
+3 -3
View File
@@ -8,11 +8,11 @@ if gum confirm "Are you sure you want to remove all preinstalled web apps, TUI w
omarchy-webapp-remove-all
omarchy-tui-remove-all
cp ~/.config/hypr/bindings.conf ~/.config/hypr/bindings.conf.bak
cp "$OMARCHY_PATH/default/hypr/plain-bindings.conf" ~/.config/hypr/bindings.conf
[[ -f ~/.config/hypr/bindings.lua ]] && cp ~/.config/hypr/bindings.lua ~/.config/hypr/bindings.lua.bak
cp "$OMARCHY_PATH/default/hypr/plain-bindings.lua" ~/.config/hypr/bindings.lua
hyprctl reload
# Remove npx stubs
# Remove npm stubs
rm -f ~/.local/bin/codex ~/.local/bin/gemini ~/.local/bin/copilot \
~/.local/bin/opencode ~/.local/bin/playwright-cli ~/.local/bin/pi
+6 -6
View File
@@ -9,27 +9,27 @@ set -e
remove_pam_config() {
# Remove from sudo
if grep -q pam_u2f.so /etc/pam.d/sudo; then
omarchy-echo-info "Removing FIDO2 authentication from sudo..."
echo "Removing FIDO2 authentication from sudo..."
sudo sed -i '/pam_u2f\.so/d' /etc/pam.d/sudo
fi
# Remove from polkit
if [[ -f /etc/pam.d/polkit-1 ]] && grep -Fq 'pam_u2f.so' /etc/pam.d/polkit-1; then
omarchy-echo-info "Removing FIDO2 authentication from polkit..."
echo "Removing FIDO2 authentication from polkit..."
sudo sed -i '/pam_u2f\.so/d' /etc/pam.d/polkit-1
fi
}
omarchy-echo-success "Removing FIDO2 device from authentication.\n"
echo -e "\e[32mRemoving FIDO2 device from authentication.\n\e[0m"
remove_pam_config
if [[ -d /etc/fido2 ]]; then
omarchy-echo-info "Removing FIDO2 configuration..."
echo "Removing FIDO2 configuration..."
sudo rm -rf /etc/fido2
fi
omarchy-echo-info "Removing FIDO2 packages..."
echo "Removing FIDO2 packages..."
omarchy-pkg-drop libfido2 pam-u2f
omarchy-echo-success "FIDO2 authentication has been completely removed."
echo -e "\e[32mFIDO2 authentication has been completely removed.\e[0m"
+6 -6
View File
@@ -9,29 +9,29 @@ set -e
remove_pam_config() {
# Remove from sudo
if grep -q pam_fprintd.so /etc/pam.d/sudo; then
omarchy-echo-info "Removing fingerprint authentication from sudo..."
echo "Removing fingerprint authentication from sudo..."
sudo sed -i '/pam_fprintd\.so/d' /etc/pam.d/sudo
fi
# Remove from polkit
if [[ -f /etc/pam.d/polkit-1 ]] && grep -Fq 'pam_fprintd.so' /etc/pam.d/polkit-1; then
omarchy-echo-info "Removing fingerprint authentication from polkit..."
echo "Removing fingerprint authentication from polkit..."
sudo sed -i '/pam_fprintd\.so/d' /etc/pam.d/polkit-1
fi
}
remove_hyprlock_fingerprint_icon() {
omarchy-echo-info "Removing fingerprint icon from hyprlock placeholder text..."
echo "Removing fingerprint icon from hyprlock placeholder text..."
sed -i 's/placeholder_text = .*/placeholder_text = Enter Password/' ~/.config/hypr/hyprlock.conf
sed -i 's/fingerprint:enabled = .*/fingerprint:enabled = false/' ~/.config/hypr/hyprlock.conf
}
omarchy-echo-success "Removing fingerprint scanner from authentication.\n"
echo -e "\e[32mRemoving fingerprint scanner from authentication.\n\e[0m"
remove_pam_config
remove_hyprlock_fingerprint_icon
omarchy-echo-info "Removing fingerprint packages..."
echo "Removing fingerprint packages..."
omarchy-pkg-drop fprintd libfprint-git
omarchy-echo-success "Fingerprint authentication has been completely removed."
echo -e "\e[32mFingerprint authentication has been completely removed.\e[0m"
+69
View File
@@ -0,0 +1,69 @@
#!/bin/bash
# omarchy:summary=Remove Sunshine and close Omarchy-managed Moonlight streaming ports.
# omarchy:requires-sudo=true
set -e
TCP_PORTS=(47984 47989 48010)
UDP_PORTS=(5353 47998 47999 48000 48002 48010)
PRIVATE_CIDRS=(10.0.0.0/8 172.16.0.0/12 192.168.0.0/16)
SUNSHINE_ADMIN_APP="Sunshine Admin"
HYPR_AUTOSTART_FILE="$HOME/.config/hypr/autostart.lua"
HYPR_AUTOSTART_ENTRY='o.launch_on_start("sunshine")'
delete_ufw_rule() {
sudo ufw --force delete "$@" >/dev/null 2>&1 || true
}
close_ufw_port_for_private_lans() {
local proto="$1"
local port="$2"
local cidr
for cidr in "${PRIVATE_CIDRS[@]}"; do
delete_ufw_rule allow in proto "$proto" from "$cidr" to any port "$port"
done
}
close_ufw_port_for_tailscale() {
local proto="$1"
local port="$2"
delete_ufw_rule allow in on tailscale0 to any port "$port" proto "$proto"
}
close_ufw_ports() {
local port
if omarchy-cmd-missing ufw; then
return
fi
for port in "${TCP_PORTS[@]}"; do
close_ufw_port_for_private_lans tcp "$port"
close_ufw_port_for_tailscale tcp "$port"
done
for port in "${UDP_PORTS[@]}"; do
close_ufw_port_for_private_lans udp "$port"
close_ufw_port_for_tailscale udp "$port"
done
sudo ufw reload
}
disable_hyprland_autostart() {
if [[ -f $HYPR_AUTOSTART_FILE ]]; then
sed -i "\|^$HYPR_AUTOSTART_ENTRY$|d" "$HYPR_AUTOSTART_FILE"
fi
}
systemctl --user disable --now sunshine 2>/dev/null || true
omarchy-pkg-drop sunshine
omarchy-webapp-remove "$SUNSHINE_ADMIN_APP" 2>/dev/null || true
disable_hyprland_autostart
close_ufw_ports
echo ""
echo "Sunshine has been removed and its Omarchy-managed Moonlight streaming ports have been closed."
+5 -5
View File
@@ -2,8 +2,8 @@
# omarchy:summary=Restart the SwayOSD server
if systemctl --user is-enabled --quiet swayosd-server.service; then
systemctl --user restart swayosd-server.service
else
omarchy-restart-app swayosd-server
fi
systemctl --user daemon-reload
systemctl --user stop swayosd-server.service || true
pkill -x swayosd-server || true
systemctl --user reset-failed swayosd-server.service || true
systemctl --user enable --now swayosd-server.service
+2 -1
View File
@@ -3,4 +3,5 @@
# omarchy:summary=Restart Waybar
# omarchy:examples=omarchy restart waybar
omarchy-restart-app waybar
pkill -9 -x waybar
setsid uwsm-app -- waybar >/dev/null 2>&1 &
+2 -2
View File
@@ -7,7 +7,7 @@ screensaver_in_focus() {
}
exit_screensaver() {
hyprctl keyword cursor:invisible false &>/dev/null || true
hyprctl eval 'hl.config({ cursor = { invisible = false } })' &>/dev/null || hyprctl keyword cursor:invisible false &>/dev/null || true
pkill -x tte 2>/dev/null
pkill -f org.omarchy.screensaver 2>/dev/null
exit 0
@@ -18,7 +18,7 @@ trap exit_screensaver SIGINT SIGTERM SIGHUP SIGQUIT
printf '\033]11;rgb:00/00/00\007' # Set background color to black
hyprctl keyword cursor:invisible true &>/dev/null
hyprctl eval 'hl.config({ cursor = { invisible = true } })' &>/dev/null || hyprctl keyword cursor:invisible true &>/dev/null
tty=$(tty 2>/dev/null)
+16 -16
View File
@@ -9,7 +9,7 @@ set -e
check_fido2_hardware() {
tokens=$(fido2-token -L 2>/dev/null)
if [[ -z $tokens ]]; then
omarchy-echo-failure "\nNo FIDO2 device detected. Please plug it in (you may need to unlock it as well)."
echo -e "\e[31m\nNo FIDO2 device detected. Please plug it in (you may need to unlock it as well).\e[0m"
return 1
fi
return 0
@@ -18,16 +18,16 @@ check_fido2_hardware() {
setup_pam_config() {
# Configure sudo
if ! grep -q pam_u2f.so /etc/pam.d/sudo; then
omarchy-echo-info "Configuring sudo for FIDO2 authentication..."
echo "Configuring sudo for FIDO2 authentication..."
sudo sed -i '1i auth sufficient pam_u2f.so cue authfile=/etc/fido2/fido2' /etc/pam.d/sudo
fi
# Configure polkit
if [[ -f /etc/pam.d/polkit-1 ]] && ! grep -q 'pam_u2f.so' /etc/pam.d/polkit-1; then
omarchy-echo-info "Configuring polkit for FIDO2 authentication..."
echo "Configuring polkit for FIDO2 authentication..."
sudo sed -i '1i auth sufficient pam_u2f.so cue authfile=/etc/fido2/fido2' /etc/pam.d/polkit-1
elif [[ ! -f /etc/pam.d/polkit-1 ]]; then
omarchy-echo-info "Creating polkit configuration with FIDO2 authentication..."
echo "Creating polkit configuration with FIDO2 authentication..."
sudo tee /etc/pam.d/polkit-1 >/dev/null <<'EOF'
auth sufficient pam_u2f.so cue authfile=/etc/fido2/fido2
auth required pam_unix.so
@@ -39,10 +39,10 @@ EOF
fi
}
omarchy-echo-success "Setting up FIDO2 device for authentication.\n"
echo -e "\e[32mSetting up FIDO2 device for authentication.\n\e[0m"
# Install required packages
omarchy-echo-info "Installing required packages..."
echo "Installing required packages..."
omarchy-pkg-add libfido2 pam-u2f
if ! check_fido2_hardware; then
@@ -52,30 +52,30 @@ fi
# Create the pamu2fcfg file
if [[ ! -f /etc/fido2/fido2 ]]; then
sudo mkdir -p /etc/fido2
omarchy-echo-success "\nLet's setup your device by confirming on the device now."
omarchy-echo-info "Touch your FIDO2 key when it lights up...\n"
echo -e "\e[32m\nLet's setup your device by confirming on the device now.\e[0m"
echo -e "Touch your FIDO2 key when it lights up...\n"
if pamu2fcfg >/tmp/fido2; then
sudo mv /tmp/fido2 /etc/fido2/fido2
omarchy-echo-success "FIDO2 device registered successfully!"
echo -e "\e[32mFIDO2 device registered successfully!\e[0m"
else
omarchy-echo-failure "\nFIDO2 registration failed. Please try again."
echo -e "\e[31m\nFIDO2 registration failed. Please try again.\e[0m"
exit 1
fi
else
omarchy-echo-info "FIDO2 device already registered."
echo "FIDO2 device already registered."
fi
# Configure PAM
setup_pam_config
# Test with sudo
omarchy-echo-info "\nTesting FIDO2 authentication with sudo..."
omarchy-echo-info "Touch your FIDO2 key when prompted.\n"
echo -e "\nTesting FIDO2 authentication with sudo..."
echo -e "Touch your FIDO2 key when prompted.\n"
if sudo echo "FIDO2 authentication test successful"; then
omarchy-echo-success "\nPerfect! FIDO2 authentication is now configured."
omarchy-echo-info "You can use your FIDO2 key for sudo and polkit authentication."
echo -e "\e[32m\nPerfect! FIDO2 authentication is now configured.\e[0m"
echo "You can use your FIDO2 key for sudo and polkit authentication."
else
omarchy-echo-failure "\nVerification failed. You may want to check your configuration."
echo -e "\e[31m\nVerification failed. You may want to check your configuration.\e[0m"
fi
+15 -15
View File
@@ -12,7 +12,7 @@ check_fingerprint_hardware() {
# Exit if no devices found
if [[ -z $devices ]]; then
omarchy-echo-failure "\nNo fingerprint sensor detected."
echo -e "\e[31m\nNo fingerprint sensor detected.\e[0m"
return 1
fi
return 0
@@ -21,16 +21,16 @@ check_fingerprint_hardware() {
setup_pam_config() {
# Configure sudo
if ! grep -q pam_fprintd.so /etc/pam.d/sudo; then
omarchy-echo-info "Configuring sudo for fingerprint authentication..."
echo "Configuring sudo for fingerprint authentication..."
sudo sed -i '1i auth sufficient pam_fprintd.so' /etc/pam.d/sudo
fi
# Configure polkit
if [[ -f /etc/pam.d/polkit-1 ]] && ! grep -q 'pam_fprintd.so' /etc/pam.d/polkit-1; then
omarchy-echo-info "Configuring polkit for fingerprint authentication..."
echo "Configuring polkit for fingerprint authentication..."
sudo sed -i '1i auth sufficient pam_fprintd.so' /etc/pam.d/polkit-1
elif [[ ! -f /etc/pam.d/polkit-1 ]]; then
omarchy-echo-info "Creating polkit configuration with fingerprint authentication..."
echo "Creating polkit configuration with fingerprint authentication..."
sudo tee /etc/pam.d/polkit-1 >/dev/null <<'EOF'
auth sufficient pam_fprintd.so
auth required pam_unix.so
@@ -43,15 +43,15 @@ EOF
}
add_hyprlock_fingerprint_icon() {
omarchy-echo-info "Adding fingerprint icon to hyprlock placeholder text..."
echo "Adding fingerprint icon to hyprlock placeholder text..."
sed -i 's/placeholder_text = .*/placeholder_text = <span> Enter Password 󰈷 <\/span>/' ~/.config/hypr/hyprlock.conf
sed -i 's/fingerprint:enabled = .*/fingerprint:enabled = true/' ~/.config/hypr/hyprlock.conf
}
omarchy-echo-success "Setting up fingerprint scanner for authentication.\n"
echo -e "\e[32mSetting up fingerprint scanner for authentication.\n\e[0m"
# Install required packages
omarchy-echo-info "Installing required packages..."
echo "Installing required packages..."
# libfprint-git provides+conflicts libfprint; pacman -S --noconfirm
# defaults the conflict prompt to N and aborts. Pre-remove libfprint
@@ -75,21 +75,21 @@ setup_pam_config
add_hyprlock_fingerprint_icon
# Enroll first fingerprint
omarchy-echo-success "\nLet's setup your right index finger as the first fingerprint."
omarchy-echo-info "Keep moving the finger around on sensor until the process completes.\n"
echo -e "\e[32m\nLet's setup your right index finger as the first fingerprint.\e[0m"
echo -e "Keep moving the finger around on sensor until the process completes.\n"
if sudo fprintd-enroll "$USER"; then
omarchy-echo-success "\nFingerprint enrolled successfully!"
echo -e "\e[32m\nFingerprint enrolled successfully!\e[0m"
# Verify
omarchy-echo-info "\nNow let's verify that it's working correctly.\n"
echo -e "\nNow let's verify that it's working correctly.\n"
if fprintd-verify; then
omarchy-echo-success "\nPerfect! Fingerprint authentication is now configured."
omarchy-echo-info "You can use your fingerprint for sudo, polkit, and lock screen (Super + Escape)."
echo -e "\e[32m\nPerfect! Fingerprint authentication is now configured.\e[0m"
echo "You can use your fingerprint for sudo, polkit, and lock screen (Super + Escape)."
else
omarchy-echo-failure "\nVerification failed. You may want to try enrolling again."
echo -e "\e[31m\nVerification failed. You may want to try enrolling again.\e[0m"
fi
else
omarchy-echo-failure "\nEnrollment failed. Please try again."
echo -e "\e[31m\nEnrollment failed. Please try again.\e[0m"
exit 1
fi
+20
View File
@@ -0,0 +1,20 @@
#!/bin/bash
# omarchy:summary=Set Hyprland, Hyprlock, Mako, and Walker corners to sharp or round
# omarchy:args=<sharp|round>
# omarchy:examples=omarchy style corners round | omarchy style corners sharp
if [[ $1 != "sharp" && $1 != "round" ]]; then
echo "Usage: omarchy-style-corners <sharp|round>"
exit 1
fi
omarchy-style-corners-hyprland "$1"
omarchy-style-corners-hyprlock "$1"
omarchy-style-corners-mako "$1"
omarchy-style-corners-walker "$1"
case $1 in
sharp) omarchy-notification-send "Sharp corners enabled" -g 󰝣 ;;
round) omarchy-notification-send "Round corners enabled" -g 󰘇 ;;
esac
+17
View File
@@ -0,0 +1,17 @@
#!/bin/bash
# omarchy:summary=Set or toggle shape of Hyprland window corners
# omarchy:args=[toggle|sharp|round]
# omarchy:examples=omarchy style corners hyprland toggle | omarchy style corners hyprland round | omarchy style corners hyprland sharp
case "${1:-toggle}" in
round) set -- on ;;
sharp) set -- off ;;
toggle) ;;
*)
echo "Usage: omarchy-style-corners-hyprland [toggle|sharp|round]"
exit 1
;;
esac
omarchy-hyprland-toggle rounded-corners "$1"
+35
View File
@@ -0,0 +1,35 @@
#!/bin/bash
# omarchy:summary=Set or toggle rounded Hyprlock input field corners
# omarchy:args=[toggle|sharp|round]
# omarchy:examples=omarchy style corners hyprlock toggle | omarchy style corners hyprlock round | omarchy style corners hyprlock sharp
TOGGLES_CONFIG="$HOME/.local/state/omarchy/toggles/hyprlock.conf"
set_rounding() {
local radius="$1"
mkdir -p "$(dirname "$TOGGLES_CONFIG")"
cat >"$TOGGLES_CONFIG" <<EOF
input-field {
rounding = $radius
}
EOF
}
case "${1:-toggle}" in
round) set_rounding 6 ;;
sharp) set_rounding 0 ;;
toggle)
if [[ -f $TOGGLES_CONFIG ]] && grep -q '^ rounding = 6$' "$TOGGLES_CONFIG"; then
set_rounding 0
else
set_rounding 6
fi
;;
*)
echo "Usage: omarchy-style-corners-hyprlock [toggle|sharp|round]"
exit 1
;;
esac
+38
View File
@@ -0,0 +1,38 @@
#!/bin/bash
# omarchy:summary=Set or toggle rounded Mako notification corners
# omarchy:args=[toggle|sharp|round]
# omarchy:examples=omarchy style corners mako toggle | omarchy style corners mako round | omarchy style corners mako sharp
TOGGLES_CONFIG="$HOME/.local/state/omarchy/toggles/mako.ini"
set_radius() {
local radius="$1"
mkdir -p "$(dirname "$TOGGLES_CONFIG")"
touch "$TOGGLES_CONFIG"
if grep -q '^border-radius=' "$TOGGLES_CONFIG"; then
sed -i "s/^border-radius=.*/border-radius=$radius/" "$TOGGLES_CONFIG"
else
echo "border-radius=$radius" >>"$TOGGLES_CONFIG"
fi
}
case "${1:-toggle}" in
round) set_radius 6 ;;
sharp) set_radius 0 ;;
toggle)
if [[ -f $TOGGLES_CONFIG ]] && grep -q '^border-radius=6$' "$TOGGLES_CONFIG"; then
set_radius 0
else
set_radius 6
fi
;;
*)
echo "Usage: omarchy-style-corners-mako [toggle|sharp|round]"
exit 1
;;
esac
makoctl reload
+40
View File
@@ -0,0 +1,40 @@
#!/bin/bash
# omarchy:summary=Set or toggle rounded Walker corners
# omarchy:args=[toggle|sharp|round]
# omarchy:examples=omarchy style corners walker toggle | omarchy style corners walker round | omarchy style corners walker sharp
TOGGLES_CSS="$HOME/.local/state/omarchy/toggles/walker.css"
set_radius() {
local radius="$1"
mkdir -p "$(dirname "$TOGGLES_CSS")"
touch "$TOGGLES_CSS"
if grep -q '^ border-radius:' "$TOGGLES_CSS"; then
sed -i "s/^ border-radius:.*/ border-radius: ${radius}px;/" "$TOGGLES_CSS"
elif grep -q '^border-radius:' "$TOGGLES_CSS"; then
sed -i "s/^border-radius:.*/border-radius: ${radius}px;/" "$TOGGLES_CSS"
else
echo ".box-wrapper { border-radius: ${radius}px; }" >>"$TOGGLES_CSS"
fi
}
case "${1:-toggle}" in
round) set_radius 6 ;;
sharp) set_radius 0 ;;
toggle)
if [[ -f $TOGGLES_CSS ]] && grep -q 'border-radius: 6px;' "$TOGGLES_CSS"; then
set_radius 0
else
set_radius 6
fi
;;
*)
echo "Usage: omarchy-style-corners-walker [toggle|sharp|round]"
exit 1
;;
esac
omarchy-restart-walker
+29
View File
@@ -0,0 +1,29 @@
#!/bin/bash
# omarchy:summary=Set Waybar position
# omarchy:args=<top|bottom|left|right>
# omarchy:examples=omarchy-style-waybar-position top | omarchy style waybar-position bottom
set -e
WAYBAR_CONFIG="$HOME/.config/waybar/config.jsonc"
position=$1
if [[ ! $position =~ ^(top|bottom|left|right)$ ]]; then
echo "Usage: omarchy-style-waybar-position top|bottom|left|right" >&2
exit 1
fi
if [[ $position == "left" || $position == "right" ]]; then
height=0
width=28
else
height=26
width=0
fi
sed -i -E "s/(\"position\"[[:space:]]*:[[:space:]]*\")[a-z]+(\")/\\1${position}\\2/" "$WAYBAR_CONFIG"
sed -i -E "s/(\"height\"[[:space:]]*:[[:space:]]*)[0-9]+/\\1${height}/; s/(\"width\"[[:space:]]*:[[:space:]]*)[0-9]+/\\1${width}/" "$WAYBAR_CONFIG"
omarchy-restart-waybar
+1 -1
View File
@@ -12,4 +12,4 @@ progress="$(awk -v p="$percent" 'BEGIN{printf "%.2f", p/100}')"
omarchy-swayosd-client \
--custom-icon display-brightness-symbolic \
--custom-progress "$progress" \
--custom-progress-text "${percent}%"
--custom-progress-text "$(printf '%3d%%' "$percent")"
+10
View File
@@ -0,0 +1,10 @@
#!/bin/bash
# omarchy:summary=Cache background switcher thumbnails for the current theme
theme_name=$(cat "$HOME/.config/omarchy/current/theme.name" 2>/dev/null)
omarchy-menu-images \
--cache-only \
"$HOME/.config/omarchy/current/theme/backgrounds" \
"$HOME/.config/omarchy/backgrounds/$theme_name"
+7 -10
View File
@@ -8,13 +8,15 @@ THEME_BACKGROUNDS_PATH="$HOME/.config/omarchy/current/theme/backgrounds/"
USER_BACKGROUNDS_PATH="$HOME/.config/omarchy/backgrounds/$THEME_NAME/"
CURRENT_BACKGROUND_LINK="$HOME/.config/omarchy/current/background"
mapfile -d '' -t BACKGROUNDS < <(find -L "$USER_BACKGROUNDS_PATH" "$THEME_BACKGROUNDS_PATH" -maxdepth 1 -type f -print0 2>/dev/null | sort -z)
mapfile -d '' -t BACKGROUNDS < <(
find -L "$USER_BACKGROUNDS_PATH" "$THEME_BACKGROUNDS_PATH" -maxdepth 1 -type f \
\( -iname '*.jpg' -o -iname '*.jpeg' -o -iname '*.png' -o -iname '*.gif' -o -iname '*.bmp' -o -iname '*.webp' \) \
-print0 2>/dev/null | sort -z
)
TOTAL=${#BACKGROUNDS[@]}
if (( TOTAL == 0 )); then
notify-send "No background was found for theme" -t 2000
pkill -x swaybg
setsid uwsm-app -- swaybg --color '#000000' >/dev/null 2>&1 &
omarchy-notification-send "No background was found for theme" -t 2000
else
# Get current background from symlink
if [[ -L $CURRENT_BACKGROUND_LINK ]]; then
@@ -42,10 +44,5 @@ else
NEW_BACKGROUND="${BACKGROUNDS[$NEXT_INDEX]}"
fi
# Set new background symlink
ln -nsf "$NEW_BACKGROUND" "$CURRENT_BACKGROUND_LINK"
# Relaunch swaybg
pkill -x swaybg
setsid uwsm-app -- swaybg -i "$CURRENT_BACKGROUND_LINK" -m fill >/dev/null 2>&1 &
omarchy-theme-bg-set "$NEW_BACKGROUND"
fi
+1 -1
View File
@@ -2,7 +2,7 @@
# omarchy:summary=Set the current background image
# omarchy:args=<path-to-image>
# omarchy:examples=omarchy theme bg set ~/Pictures/wallpaper.png
# omarchy:examples=omarchy theme bg set ~/Pictures/background.png
if [[ -z $1 ]]; then
echo "Usage: omarchy-theme-bg-set <path-to-image>" >&2
+15
View File
@@ -0,0 +1,15 @@
#!/bin/bash
# omarchy:summary=Open the Omarchy background switcher
# omarchy:group=theme
# omarchy:name=bg-switcher
# omarchy:aliases=omarchy background
OMARCHY_PATH=${OMARCHY_PATH:-$HOME/.local/share/omarchy}
theme_name=$(cat "$HOME/.config/omarchy/current/theme.name" 2>/dev/null)
current_background=$(readlink -f "$HOME/.config/omarchy/current/background" 2>/dev/null)
omarchy-menu-images \
--selected "$current_background" \
"$HOME/.config/omarchy/current/theme/backgrounds" \
"$HOME/.config/omarchy/backgrounds/$theme_name"
+3
View File
@@ -71,3 +71,6 @@ omarchy-theme-set-keyboard
# Call hook on theme set
omarchy-hook theme-set "$THEME_NAME" >/dev/null
# Warm the background selector cache after the theme is applied, off the critical path.
omarchy-theme-bg-cache >/dev/null 2>&1 &
+98
View File
@@ -0,0 +1,98 @@
#!/bin/bash
# omarchy:summary=Open the Omarchy theme switcher
OMARCHY_PATH=${OMARCHY_PATH:-$HOME/.local/share/omarchy}
USER_THEMES_PATH="$HOME/.config/omarchy/themes"
OMARCHY_THEMES_PATH="$OMARCHY_PATH/themes"
CACHE_PATH="${XDG_CACHE_HOME:-$HOME/.cache}/omarchy/theme-selector"
preview_dir="$CACHE_PATH/previews"
signature_file="$CACHE_PATH/signature"
mkdir -p "$preview_dir"
find_preview() {
local theme_path="$1"
local preview preview_name
for preview_name in preview.png preview.jpg preview.jpeg preview.webp preview.gif preview.bmp; do
preview=$(find -L "$theme_path" -maxdepth 1 -type f -iname "$preview_name" -print -quit 2>/dev/null)
if [[ -n $preview ]]; then
printf '%s\n' "$preview"
return
fi
done
if [[ -d $theme_path/backgrounds ]]; then
find -L "$theme_path/backgrounds" -maxdepth 1 -type f \( -iname '*.jpg' -o -iname '*.jpeg' -o -iname '*.png' -o -iname '*.gif' -o -iname '*.bmp' -o -iname '*.webp' \) -print 2>/dev/null | sort | head -n 1
fi
}
add_theme_preview() {
local theme_name="$1"
local preview="$2"
local extension="${preview##*.}"
extension="${extension,,}"
[[ -n $preview ]] || return
[[ -e $preview_dir/$theme_name.$extension ]] && return
ln -s "$preview" "$preview_dir/$theme_name.$extension"
}
theme_signature=""
for theme_dir in "$USER_THEMES_PATH" "$OMARCHY_THEMES_PATH"; do
if [[ -d $theme_dir ]]; then
theme_signature+="$theme_dir:$(stat -Lc '%Y' "$theme_dir")"$'\n'
while IFS= read -r -d '' theme_path; do
preview=$(find_preview "$theme_path")
theme_signature+="$theme_path:$(stat -Lc '%Y' "$theme_path")"$'\n'
if [[ -n $preview ]]; then
theme_signature+="$preview:$(stat -Lc '%s:%Y' "$preview")"$'\n'
fi
done < <(find -L "$theme_dir" -mindepth 1 -maxdepth 1 \( -type d -o -type l \) -print0 2>/dev/null | sort -z)
fi
done
if [[ ! -f $signature_file ]] || ! cmp -s "$signature_file" <(printf '%s' "$theme_signature"); then
rm -rf "$preview_dir"
mkdir -p "$preview_dir"
while IFS= read -r theme_path; do
theme_name=${theme_path##*/}
preview=$(find_preview "$theme_path")
if [[ -z $preview ]]; then
preview=$(find_preview "$OMARCHY_THEMES_PATH/$theme_name")
fi
add_theme_preview "$theme_name" "$preview"
done < <(find -L "$USER_THEMES_PATH" -mindepth 1 -maxdepth 1 \( -type d -o -type l \) -print 2>/dev/null | sort)
while IFS= read -r theme_path; do
theme_name=${theme_path##*/}
preview=$(find_preview "$theme_path")
add_theme_preview "$theme_name" "$preview"
done < <(find -L "$OMARCHY_THEMES_PATH" -mindepth 1 -maxdepth 1 -type d -print 2>/dev/null | sort)
printf '%s' "$theme_signature" >"$signature_file"
fi
current_theme=$(cat "$HOME/.config/omarchy/current/theme.name" 2>/dev/null)
selected_preview=""
for extension in png jpg jpeg webp gif bmp; do
if [[ -e $preview_dir/$current_theme.$extension ]]; then
selected_preview="$preview_dir/$current_theme.$extension"
break
fi
done
exec omarchy-menu-images \
--print-name \
--show-labels \
--filterable \
--lazy-thumbnails \
--selected "$selected_preview" \
"$preview_dir"
+7 -7
View File
@@ -3,7 +3,7 @@
# omarchy:summary=Enable, disable, or toggle the touchpad
# omarchy:args=[on|off|toggle]
STATE_CONF="$HOME/.local/state/omarchy/toggles/hypr/touchpad-disabled.conf"
STATE_FILE="$HOME/.local/state/omarchy/toggles/hypr/touchpad-disabled.lua"
device="$(omarchy-hw-touchpad)"
@@ -13,20 +13,20 @@ if [[ -z $device ]]; then
fi
enable() {
hyprctl keyword "device[$device]:enabled" true >/dev/null
rm -f "$STATE_CONF"
hyprctl eval "hl.device({ name = \"$device\", enabled = true })" >/dev/null
rm -f "$STATE_FILE"
omarchy-swayosd-client --custom-icon input-touchpad-symbolic --custom-message "Touchpad enabled"
}
disable() {
hyprctl keyword "device[$device]:enabled" false >/dev/null
mkdir -p "$(dirname "$STATE_CONF")"
printf 'device {\n name = %s\n enabled = false\n}\n' "$device" > "$STATE_CONF"
hyprctl eval "hl.device({ name = \"$device\", enabled = false })" >/dev/null
mkdir -p "$(dirname "$STATE_FILE")"
printf 'hl.device({ name = "%s", enabled = false })\n' "$device" >"$STATE_FILE"
omarchy-swayosd-client --custom-icon touchpad-disabled-symbolic --custom-message "Touchpad disabled"
}
case "${1:-toggle}" in
on) enable ;;
off) disable ;;
toggle) if [[ -f $STATE_CONF ]]; then enable; else disable; fi ;;
toggle) if [[ -f $STATE_FILE ]]; then enable; else disable; fi ;;
esac
+7 -7
View File
@@ -3,7 +3,7 @@
# omarchy:summary=Enable, disable, or toggle the touch functionality of the screen
# omarchy:args=[on|off|toggle]
STATE_CONF="$HOME/.local/state/omarchy/toggles/hypr/touchscreen-disabled.conf"
STATE_FILE="$HOME/.local/state/omarchy/toggles/hypr/touchscreen-disabled.lua"
device="$(omarchy-hw-touchscreen)"
@@ -13,20 +13,20 @@ if [[ -z $device ]]; then
fi
enable() {
hyprctl keyword "device[$device]:enabled" true >/dev/null
rm -f "$STATE_CONF"
hyprctl eval "hl.device({ name = \"$device\", enabled = true })" >/dev/null
rm -f "$STATE_FILE"
omarchy-swayosd-client --custom-icon device-support-touch-symbolic --custom-message "Touchscreen enabled"
}
disable() {
hyprctl keyword "device[$device]:enabled" false >/dev/null
mkdir -p "$(dirname "$STATE_CONF")"
printf 'device {\n name = %s\n enabled = false\n}\n' "$device" > "$STATE_CONF"
hyprctl eval "hl.device({ name = \"$device\", enabled = false })" >/dev/null
mkdir -p "$(dirname "$STATE_FILE")"
printf 'hl.device({ name = "%s", enabled = false })\n' "$device" >"$STATE_FILE"
omarchy-swayosd-client --custom-icon touch-disabled-symbolic --custom-message "Touchscreen disabled"
}
case "${1:-toggle}" in
on) enable ;;
off) disable ;;
toggle) if [[ -f $STATE_CONF ]]; then enable; else disable; fi ;;
toggle) if [[ -f $STATE_FILE ]]; then enable; else disable; fi ;;
esac
+4 -4
View File
@@ -4,7 +4,7 @@
# omarchy:name=
# omarchy:summary=Transcode pictures and videos for sharing
# omarchy:args=[--path path] [input] [format] [resolution]
# omarchy:examples=omarchy transcode|omarchy transcode --path ~/Downloads|omarchy transcode ~/Videos/demo.mov mp4 1080p|omarchy transcode ~/Pictures/wallpaper.heic jpg medium
# omarchy:examples=omarchy transcode|omarchy transcode --path ~/Downloads|omarchy transcode ~/Videos/demo.mov mp4 1080p|omarchy transcode ~/Pictures/background.heic jpg medium
set -euo pipefail
@@ -193,14 +193,14 @@ main() {
output=$(output_path "$input" "$format" "$resolution")
if [[ $type == "video" ]]; then
omarchy-notification-send "" "Transcoding video…" "$(basename -- "$input") to $format ($resolution)"
omarchy-notification-send -g  "Transcoding video…" "$(basename -- "$input") to $format ($resolution)"
transcode_video "$input" "$format" "$resolution" "$output"
copy_to_clipboard "$output"
omarchy-notification-send "" "Transcoded to $resolution $format" "Saved and copied to clipboard."
omarchy-notification-send -g  "Transcoded to $resolution $format" "Saved and copied to clipboard."
else
transcode_picture "$input" "$format" "$resolution" "$output"
copy_to_clipboard "$output"
omarchy-notification-send "" "Transcoded to $resolution $format" "Saved and copied to clipboard."
omarchy-notification-send -g  "Transcoded to $resolution $format" "Saved and copied to clipboard."
fi
}
+1
View File
@@ -10,6 +10,7 @@ omarchy-update-time
# Suppress Hyprland config errors while git updates default config files mid-pull
hyprctl keyword debug:suppress_errors true &>/dev/null || true
hyprctl eval 'hl.config({ debug = { suppress_errors = true } })' &>/dev/null || true
git -C $OMARCHY_PATH pull --autostash
git -C $OMARCHY_PATH --no-pager diff --check || git -C $OMARCHY_PATH reset --merge
+4 -2
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# omarchy:summary=Ensure the Omarchy keyring package is installed and populated
# omarchy:summary=Ensure the Omarchy and Arch keyring packages are installed and populated
# omarchy:requires-sudo=true
if omarchy-pkg-missing omarchy-keyring || ! sudo pacman-key --list-keys 40DFB630FF42BCFFB047046CF0134EE680CAC571 &>/dev/null; then
@@ -16,5 +16,7 @@ if omarchy-pkg-missing omarchy-keyring || ! sudo pacman-key --list-keys 40DFB630
fi
# Ensure we have the latest archlinux-keyring, maintainer keys might have changed
# Always reinstall, as the keyring can be updated without a package version bump.
echo -e "\e[32m\nUpdate Arch signing keys\e[0m"
sudo pacman -Sy --noconfirm archlinux-keyring >/dev/null
sudo pacman -Sy --noconfirm archlinux-keyring >/dev/null 2> >(grep -vE '^warning: archlinux-keyring-[^ ]+ is up to date -- reinstalling$' >&2)
echo "Keys are correct"
+2 -2
View File
@@ -6,7 +6,7 @@
set -e
# Ensure screensaver/sleep doesn't set in during updates
hyprctl dispatch tagwindow +noidle &>/dev/null || true
hyprctl dispatch 'hl.dsp.window.tag({ tag = "+noidle" })' &>/dev/null || hyprctl dispatch tagwindow +noidle &>/dev/null || true
# Perform all update steps
omarchy-update-keyring
@@ -22,4 +22,4 @@ omarchy-update-analyze-logs
omarchy-update-restart
# Re-enable screensaver/sleep after updates
hyprctl dispatch tagwindow -- -noidle &>/dev/null || true
hyprctl dispatch 'hl.dsp.window.tag({ tag = "-noidle" })' &>/dev/null || hyprctl dispatch tagwindow -- -noidle &>/dev/null || true
+7 -3
View File
@@ -4,6 +4,10 @@
echo
confirm_reboot() {
gum confirm "$1" && { omarchy-system-reboot; exit 0; }
}
running_kernel=$(uname -r)
kernel_updated=true
@@ -19,14 +23,14 @@ for kernel in /usr/lib/modules/*/vmlinuz; do
done
if [[ $kernel_updated == "true" ]]; then
gum confirm "Linux kernel has been updated. Reboot?" && omarchy-system-reboot
confirm_reboot "Linux kernel has been updated. Reboot?"
elif [[ -f $HOME/.local/state/omarchy/reboot-required ]]; then
gum confirm "Updates require reboot. Ready?" && omarchy-system-reboot
confirm_reboot "Updates require reboot. Ready?"
fi
running_hyprland=$(readlink /proc/$(pgrep -x Hyprland)/exe 2>/dev/null)
if [[ $running_hyprland == *"(deleted)"* ]]; then
gum confirm "Hyprland has been updated. Reboot?" && omarchy-system-reboot
confirm_reboot "Hyprland has been updated. Reboot?"
fi
for file in "$HOME"/.local/state/omarchy/restart-*-required; do
+1
View File
@@ -20,6 +20,7 @@ if gum confirm "Install Voxtype + AI model (~150MB) to enable dictation?"; then
fi
voxtype setup systemd
omarchy-hyprland-toggle voxtype on
omarchy-restart-waybar
notify-send " Voxtype Dictation Ready" "Hold F9 to dictate (or toggle with Super + Ctrl + X)." -t 10000
fi
+3 -3
View File
@@ -11,14 +11,14 @@ if omarchy-cmd-present voxtype; then
echo "Uninstall Voxtype to remove dictation."
# Remove services
systemctl --user stop voxtype.service 2>/dev/null || true
rm -f ~/.config/systemd/user/voxtype*
systemctl --user disable --now voxtype.service 2>/dev/null || true
systemctl --user daemon-reload
# Remove packages and configs
omarchy-pkg-drop wtype voxtype-bin
omarchy-pkg-drop voxtype-bin
rm -rf ~/.config/voxtype
rm -rf ~/.local/share/voxtype
omarchy-hyprland-toggle voxtype off
else
echo "Voxtype was not installed."
fi

Some files were not shown because too many files have changed in this diff Show More