actually, this is so simple and so specific I should probably just attempt to write it in Rust as a practice project.
What I basically want is a global hot key I can press to pop up a textbox, enter a sentence and it will append it to a specific file.
@why it's a path I'll investigate but I'm not sure what the interface for text entry would look like. I do want some control over that rather than a bigass console coming up in my face.

@RustyCrab@clubcyberia.co @why@shitposter.world basically thought of the same thing but with making a wm prompt box (i.e dmenu) but >needs to work on windows stopped this

@iska @why if windows has an equivalent of zenity I can just build a different script because this took maybe 10 minutes in total

@iska @why cc @pwm also

#!/bin/bash FILE_PATH="$HOME/shitnotes.txt" TEXT=$(zenity --entry --title="Shit out a note with Shitnote" --text="WRITE:") if [ -n "$TEXT" ]; then echo "- [ ] $TEXT" >> "$FILE_PATH" fi

the - [ ] gets translated as a checkable box in obsidian

@iska @pwm @why okay yeah I modified it to just add the new line into a specific file in my obsidian directory. Works perfect tbh. Surely, SURELY windows has this and if not I can just make a small C++ program that does it since I know how to call win32 apis
Follow

@RustyCrab @iska @pwm @why
Visual Basic Scripting edition had a way to display graphical input box and Windows 11 still has VBS I think, although they have obsoleted it. I'm not sure it's still possible with PowerShell without relying on a DLL call ๐Ÿค”
It would probably be easier to bring bash and zenity to Windows machines together with the script ๐Ÿคญ

ยท bloat ยท 1 ยท 0 ยท 1
@m0xee @iska @pwm @why yeah you can very likely run it via gitbash which is something I have installed anyway. Less portable but who cares really.

I should investigate powershell though to see if there's an easy way. Didn't think of that.
Sign in to participate in the conversation
Librem Social

Librem Social is an opt-in public network. Messages are shared under Creative Commons BY-SA 4.0 license terms. Policy.

Stay safe. Please abide by our code of conduct.

(Source code)

image/svg+xml Librem Chat image/svg+xml