restore legacy, include shorcut scripts
This commit is contained in:
85
dmapp/dmos/SETUP-KEYBOARD-SHORTCUTS.md
Normal file
85
dmapp/dmos/SETUP-KEYBOARD-SHORTCUTS.md
Normal file
@@ -0,0 +1,85 @@
|
||||
# Date/Time Clipboard Shortcuts Setup
|
||||
|
||||
This replaces espanso with a cleaner clipboard-based solution that won't trigger "Updated keyboard layout" notifications.
|
||||
|
||||
## How It Works
|
||||
|
||||
Instead of text expansion, keyboard shortcuts copy the formatted date/time to clipboard. You then paste with `Ctrl+V`.
|
||||
|
||||
## Available Formats
|
||||
|
||||
- **wd**: ISO week.day (e.g., `52.4`)
|
||||
- **3t**: 360-time division (e.g., `331`)
|
||||
- **uid**: Random UUID 8 chars (e.g., `a8b9bf0a`)
|
||||
|
||||
## GNOME Keyboard Shortcuts Setup
|
||||
|
||||
1. Open Settings → Keyboard → Keyboard Shortcuts (or run: `gnome-control-center keyboard`)
|
||||
|
||||
2. Scroll to bottom and click "+ Add Custom Shortcut"
|
||||
|
||||
3. Add three shortcuts:
|
||||
|
||||
### Shortcut 1: Week Day
|
||||
- **Name**: `Copy Week.Day`
|
||||
- **Command**: `/home/mariano/wdir/dm/dmapp/dmos/datetime-clipboard.py wd`
|
||||
- **Shortcut**: `Ctrl+Super+W`
|
||||
|
||||
### Shortcut 2: 360-Time
|
||||
- **Name**: `Copy 360-Time`
|
||||
- **Command**: `/home/mariano/wdir/dm/dmapp/dmos/datetime-clipboard.py 3t`
|
||||
- **Shortcut**: `Ctrl+Super+T`
|
||||
|
||||
### Shortcut 3: UUID
|
||||
- **Name**: `Copy UUID`
|
||||
- **Command**: `/home/mariano/wdir/dm/dmapp/dmos/datetime-clipboard.py uid`
|
||||
- **Shortcut**: `Ctrl+Super+U`
|
||||
|
||||
## Usage
|
||||
|
||||
1. Press the keyboard shortcut (e.g., `Ctrl+Super+W`)
|
||||
2. Paste with `Ctrl+V` wherever you need it
|
||||
|
||||
## Advantages Over Espanso
|
||||
|
||||
- No keyboard layout notifications
|
||||
- Works reliably on Wayland
|
||||
- Simpler architecture (no daemon running)
|
||||
- More control over when to paste
|
||||
- Works in password fields and other protected inputs
|
||||
|
||||
## Removing Espanso (Optional)
|
||||
|
||||
If you want to fully switch away from espanso:
|
||||
|
||||
```bash
|
||||
# Stop espanso service
|
||||
espanso stop
|
||||
|
||||
# Disable autostart
|
||||
espanso service unregister
|
||||
|
||||
# Uninstall (if desired)
|
||||
# sudo apt remove espanso # or however you installed it
|
||||
```
|
||||
|
||||
## Testing
|
||||
|
||||
```bash
|
||||
# Test each format
|
||||
/home/mariano/wdir/dm/dmapp/dmos/datetime-clipboard.py wd
|
||||
/home/mariano/wdir/dm/dmapp/dmos/datetime-clipboard.py 3t
|
||||
/home/mariano/wdir/dm/dmapp/dmos/datetime-clipboard.py uid
|
||||
|
||||
# Then paste to verify clipboard contents
|
||||
```
|
||||
|
||||
## Cross-Platform Notes
|
||||
|
||||
This solution is part of the deskmeter cross-platform configuration effort:
|
||||
|
||||
- **Linux (Wayland/X11)**: Uses `wl-copy` or `xclip` for clipboard
|
||||
- **Windows**: Would require AutoHotkey or similar for global shortcuts
|
||||
- **macOS**: Would use `pbcopy` for clipboard
|
||||
|
||||
The core datetime logic is platform-independent Python. Only clipboard mechanism needs platform-specific handling.
|
||||
Reference in New Issue
Block a user