Searching txt.sour.is

Twts matching #vim
Sort by: Newest, Oldest, Most Relevant

All my newly added test cases failed, that movq thankfully provided in https://git.mills.io/yarnsocial/twtxt.dev/pulls/28#issuecomment-20801 for the draft of the twt hash v2 extension. The first error was easy to see in the diff. The hashes were way too long. You’ve already guessed it, I had cut the hash from the twelfth character towards the end instead of taking the first twelve characters: hash[12:] instead of hash[:12].

After fixing this rookie mistake, the tests still all failed. Hmmm. Did I still cut the wrong twelve characters? :-? I even checked the Go reference implementation in the document itself. But it read basically the same as mine. Strange, what the heck is going on here?

Turns out that my vim replacements to transform the Python code into Go code butchered all the URLs. ;-) The order of operations matters. I first replaced the equals with colons for the subtest struct fields and then wanted to transform the RFC 3339 timestamp strings to time.Date(…) calls. So, I replaced the colons in the time with commas and spaces. Hence, my URLs then also all read https, //example.com/twtxt.txt.

But that was it. All test green. \o/

⤋ Read More

Android shopping list apps disappointed me too many times, so I went back to writing these lists by hand a while ago.

Here’s what’s more fun: Write them in Vim and then print them on the dotmatrix printer. 🥳

And, because I can, I use my own font for that, i.e. ImageMagick renders an image file and then a little tool converts that to ESC/P so I can dump it to /dev/usb/lp0.

(I have so much scrap paper from mail spam lying around that I don’t feel too bad about this. All these sheets would go straight to the bin otherwise.)

Image

⤋ Read More
In-reply-to » @aelaraji tell us all about it, without omitting details!

Just typing twts directly into my twtxt file.

Details:

  • Opening my twtxt file remotely using vim scp://user@remote:port//path/to/twtxt.txt
  • Inserting the date, time and tab part of the twt with :.!echo "$(date -Is)\t"
  • In case I need to add a new line I just Ctrl+Shift+u, type in the 2028 and hit Enter
  • In order to replay, you just steal a twt hash from your favorite Yarn instance.

It looks tedious, but it’s fun to know I can twt no matter where I am, as long as can ssh in.

⤋ Read More

@movq@www.uninformativ.de streamlining jenny.vim?

index adc0db9..cb54abc 100644
--- a/vim/ftdetect/jenny.vim
+++ b/vim/ftdetect/jenny.vim
@@ -1 +1,2 @@
 au BufNewFile,BufRead jenny-posting.eml setl completefunc=jenny#CompleteMentions fo-=t wrap
+au BufRead,BufNewFile jenny-posting.eml normal $

⤋ Read More

Accelerated Gulf of Maine warming may pose a serious threat to American lobsters
The Gulf of Maine is warming faster than 99% of the world’s oceans, raising concerns for its $2 billion-a-year American lobster fishery. Scientists at William & Mary’s Batten School & VIMS have been studying the impacts of ocean acidification and warming on lobster reproduction, and the results of their most recent research suggest the rising temperatures pose the greatest risk. ⌘ Read more

⤋ Read More

Something happened with the frame rate of terminal emulators lately. It looks like there’s a trend to run at a high framerate now? I’m not sure exactly. This can be seen in VTE-based terminals like my xiate or XTerm on Wayland. foot and st, on the other hand, are fine.

My shell prompt and cursor look like this:

$ █

When I keep Enter pressed, I expect to see several lines like so:

$
$
$
$
$
$
$ █

With the affected terminal emulators, the lines actually show up in the following sequence. First, we have the original line:

$ █

Pressing Enter yields this as the next frame:

$
█

And then eventually this:

$
$ █

In other words, you can see the cursor jumping around very quickly, all the time.

Another example: Vim actually shows which key you just pressed in the bottom right corner. Keeping j pressed to scroll through a file means I get to see a j flashing rapidly now.

(I have no idea yet, why exactly XTerm in X11 is fine but flickering in Wayland.)

⤋ Read More

I probably should implement some editing feature in tt. Sure, I can easily edit my feed in vim to fix typos. But then I still have to manually remove the old message from the cache so that the new message is inserted on next reload and I don’t end up with “duplicates” in the message tree.

⤋ Read More
In-reply-to » Ha, I just learned that deleting text in my zsh with Ctrl+U to the front or Ctrl+K to the end puts it in a buffer that can be pasted by pressing Ctrl+Y! That's neat. Even removing the last word with Ctrl+W moves it into this paste buffer.

@lyse@lyse.isobeef.org Ctrl-U in Vim does something similar (“Delete all entered characters before the cursor in the current line”), but it does not put them into the “clipboard”. I sometimes hit Ctrl-U by accident and then my text is gone. 😡😂

⤋ Read More