~kas

Bornholm, Denmark

https://kas.bio.link/

Fortune favours the lucky


#19 Add support for ordered lists that start at a given number 2 months ago

Comment by ~kas on ~bouncepaw/mycomarkup

Yes, the format *.4 (*.N) was my initial suggestion. I could live with that. Another possibility is:

4. task 4
*. task 5

This may be more intuitive than *.4, but I have no idea how that affects the parser (or other markup I haven't thought of).

#19 Add support for ordered lists that start at a given number 2 months ago

Comment by ~kas on ~bouncepaw/mycomarkup

I like your base{4} thing, but what will I do if I actually want to write “base{4}” over an ordered list?

I think I've seen a markup (TiddlyWiki, perhaps?) where you can start an ordered list with the “base” you want to start with, and then the rest of the numbers don't matter. So, e.g.:

1. first
1. second
1. third

will give you

1. first
2. second
3. third

and

4. task 4
77. task 5

will give you

4. task 4
5. task 5

But that is a little confusing and not very intuitive. Better keep it simple and memorable.

#19 Add support for ordered lists that start at a given number 3 months ago

Ticket created by ~kas on ~bouncepaw/mycomarkup

I have a list that must start with 0, but mycomarkup insists that an ordered list starts with 1.

Other convenient uses: E.g., an ordered list with 10 items that are grouped into 3 groups with a heading-like markup inbetween.

= TODO

We have 10 urgent matters to resolve:

== Home
1. one task
2. another task
3. a third task

== Work
4. task 4
5. task 5

== Play
6. task 6
7. task 7
8. task 8
9. task 9
10. last task

I'm unsure how to markup this, but *.N, where N is the “base”, is a possibility.

#8 Please don't use ANSI escape sequences when output is not a TTY 1 year, 8 months ago

Comment by ~kas on ~mzhang/garbage

Thank you so much!

#7 Please make `garbage put -v` more useful 1 year, 8 months ago

Comment by ~kas on ~mzhang/garbage

Looks great now, thanks!

#8 Please don't use ANSI escape sequences when output is not a TTY 1 year, 8 months ago

Ticket created by ~kas on ~mzhang/garbage

In short: garbage shouldn't attempt to colourize output to standard output or standard error when the file desciptor is not a TTY:

$ date > test.txt
$ garbage put -vv test.txt >test.log 2>&2  # neither stdout, nor stderr, is a tty now
$ cat test.log
?[2m2022-11-02T10:52:19.415654Z?[0m ?[32m INFO?[0m ?[2mgarbage::ops::put?[0m?[2m:?[0m Chosen strategy. ?[3mpath?[0m?[2m=?[0m"test.txt" ?[3mstrategy?[0m?[2m=?[0mMoveTo(TrashDir { path: "/tmp/.Trash-1000" })
?[2m2022-11-02T10:52:19.415861Z?[0m ?[32m INFO?[0m ?[1mtrash_dir?[0m?[1m{?[0mTrashDir { path: "/tmp/.Trash-1000" }?[1m}?[0m?[2m:?[0m ?[2mgarbage::ops::put::strategy?[0m?[2m:?[0m ?[3mpath_to_trashed_file?[0m?[2m=?[0m"/tmp/.Trash-1000/files/1667386339415.test.txt"
?[2m2022-11-02T10:52:19.415888Z?[0m ?[32m INFO?[0m ?[1mtrash_dir?[0m?[1m{?[0mTrashDir { path: "/tmp/.Trash-1000" }?[1m}?[0m?[2m:?[0m ?[2mgarbage::ops::put::strategy?[0m?[2m:?[0m ?[3mpath_to_trash_info?[0m?[2m=?[0m"/tmp/.Trash-1000/info/1667386339415.test.txt.trashinfo"
?[2m2022-11-02T10:52:19.415980Z?[0m ?[32m INFO?[0m ?[1mtrash_dir?[0m?[1m{?[0mTrashDir { path: "/tmp/.Trash-1000" }?[1m}?[0m?[2m:?[0m ?[2mgarbage::ops::put::strategy?[0m?[2m:?[0m Trash info: TrashInfo { path: "/tmp/test/test.txt", deletion_date: 2022-11-02T11:52:19.415758413+01:00, deleted_path: "/tmp/.Trash-1000/files/1667386339415.test.txt", info_path: "/tmp/.Trash-1000/info/1667386339415.test.txt.trashinfo" }
?[2m2022-11-02T10:52:19.416017Z?[0m ?[32m INFO?[0m ?[1mtrash_dir?[0m?[1m{?[0mTrashDir { path: "/tmp/.Trash-1000" }?[1m}?[0m?[2m:?[0m ?[2mgarbage::ops::put::strategy?[0m?[2m:?[0m Renaming file into trash directory. ?[3mfrom?[0m?[2m=?[0m"/tmp/test/test.txt" ?[3mto?[0m?[2m=?[0m"/tmp/.Trash-1000/files/1667386339415.test.txt" ?[3mis_symlink?[0m?[2m=?[0mfalse

Output should have looked like this:

$ cat test.log
2022-11-02T10:52:19.415654Z  INFO garbage::ops::put: Chosen strategy. path="test.txt" strategy=MoveTo(TrashDir { path: "/tmp/.Trash-1000" })
2022-11-02T10:52:19.415861Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: path_to_trashed_file="/tmp/.Trash-1000/files/1667386339415.test.txt"
2022-11-02T10:52:19.415888Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: path_to_trash_info="/tmp/.Trash-1000/info/1667386339415.test.txt.trashinfo"
2022-11-02T10:52:19.415980Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: Trash info: TrashInfo { path: "/tmp/test/test.txt", deletion_date: 2022-11-02T11:52:19.415758413+01:00, deleted_path: "/tmp/.Trash-1000/files/1667386339415.test.txt", info_path: "/tmp/.Trash-1000/info/1667386339415.test.txt.trashinfo" }
2022-11-02T10:52:19.416017Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: Renaming file into trash directory. from="/tmp/test/test.txt" to="/tmp/.Trash-1000/files/1667386339415.test.txt" is_symlink=false

Thanks.

#7 Please make `garbage put -v` more useful 1 year, 8 months ago

Ticket created by ~kas on ~mzhang/garbage

Neither garbage put, nor garbage put -v, produce any output:

$ date > test.txt
$ garbage put -v test.txt  # no output

On the other hand, garbage put -vv is excessively noisy:

$ date > test.txt
$ garbage put -vv test.txt
2022-11-02T10:47:15.293887Z  INFO garbage::ops::put: Chosen strategy. path="test.txt" strategy=MoveTo(TrashDir { path: "/tmp/.Trash-1000" })
2022-11-02T10:47:15.294100Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: path_to_trashed_file="/tmp/.Trash-1000/files/1667386035293.test.txt"
2022-11-02T10:47:15.294127Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: path_to_trash_info="/tmp/.Trash-1000/info/1667386035293.test.txt.trashinfo"
2022-11-02T10:47:15.294259Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: Trash info: TrashInfo { path: "/tmp/test/test.txt", deletion_date: 2022-11-02T11:47:15.293973765+01:00, deleted_path: "/tmp/.Trash-1000/files/1667386035293.test.txt", info_path: "/tmp/.Trash-1000/info/1667386035293.test.txt.trashinfo" }
2022-11-02T10:47:15.294304Z  INFO trash_dir{TrashDir { path: "/tmp/.Trash-1000" }}: garbage::ops::put::strategy: Renaming file into trash directory. from="/tmp/test/test.txt" to="/tmp/.Trash-1000/files/1667386035293.test.txt" is_symlink=false

Could garbage put -v please produce useful output in the style of rm -v?

$ date > test.txt
$ rm -f test.txt
removed 'test.txt'

Thanks.

#4 port1965.eu doesn't render 4 years ago

Ticket created by ~kas on ~soapdog/racket-gemini

gemini://port1965.eu/ is an IPv6-only, dual stacked (normal and yggdrasil IPv6) gemini site served by the jetforce gemini server.

When attempting to spacewalk from Port 1965, the server responds with green lights (»"gemini://port1965.eu/" 20 text/gemini 2135« — i.e., status code 20 and mime-type text/gemini). However, the page is never parsed and fafi keeps showing a “Parsing…” message in its status bar.

Uncommenting line 125 in gemini-view.rkt seems to indicate that fafi didn't see the response?

(gemini-response #f "" #f)
car: contract violation
  expected: pair?
  given: '()
  context...:
   [… ]/fafi-browser/gemini-view.rkt:118:4: set-url method in gemini-view%
   /usr/share/racket/pkgs/gui-lib/mred/private/wx/common/queue.rkt:435:6
   /usr/share/racket/pkgs/gui-lib/mred/private/wx/common/queue.rkt:486:32
   /usr/share/racket/pkgs/gui-lib/mred/private/wx/common/queue.rkt:634:3