πŸ’Ύ Archived View for gemi.dev β€Ί gemini-mailing-list β€Ί 000468.gmi captured on 2024-05-26 at 16:00:28. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2023-12-28)

-=-=-=-=-=-=-

Why not use the markdown way to deal with long lines?

1. Philipp Stanner (stanner (a) posteo.de)

I stumbled over Gemini a while ago and today tried to setup my first
blog post.

I take issue with the fact that a paragraph has to be one long line. I
think the markdown way is perfect: Two newlines create a paragraph.
Period. This way, everyone can write maintaining the common width of 80
characters, and it will still be displayed as intended.

For the first time in a long while I started to search neovim's help to
find out if there's any way to have long lines and still work with them
productively. Softwrap on or off doesn't do the trick, it's rather
annoying when you want to edit something in the mid of a huge
paragraph. `30w cw`...

My life would be more easy if I could just do what I always did and
wrap at 80. Considering Gemini will mostly target software people, I
think that's appropriate.

But if anyone here can provide me with a clever (neovim) trick to deal
with these long lines, I'm open to hear about it.

P.

Link to individual message.

2. Drew DeVault (sir (a) cmpwn.com)

It simplifies the client design this way.

On Fri Nov 13, 2020 at 1:37 PM EST, Philipp Stanner wrote:
> But if anyone here can provide me with a clever (neovim) trick to deal
> with these long lines, I'm open to hear about it.

Plugin 'https://tildegit.org/sloum/gemini-vim-syntax'
autocmd FileType gmi set wrap linebreak

Link to individual message.

3. James Tomasino (tomasino (a) lavabit.com)

On 11/13/20 6:37 PM, Philipp Stanner wrote:
> For the first time in a long while I started to search neovim's help to
> find out if there's any way to have long lines and still work with them
> productively. Softwrap on or off doesn't do the trick, it's rather
> annoying when you want to edit something in the mid of a huge
> paragraph. `30w cw`...

I'm a neovim user. The Pencil plugins are extremely useful for dealing 
with text in better ways. It provides modes such as :PencilSoft which does 
exactly what you'd need for gemtext. Without such a plugin, though, you 
can still use wordwrap with some regular vim settings to break on whole 
words. For navigating vertically in softwraps you can use gj and gk, or 
set that as the default with:

noremap <silent> <expr> j (v:count == 0 ? 'gj' : 'j')
noremap <silent> <expr> k (v:count == 0 ? 'gk' : 'k')

It's quite nice to work with once you have the settings in place.

Link to individual message.

4. Philipp Stanner (stanner (a) posteo.de)

Am Freitag, den 13.11.2020, 13:38 -0500 schrieb Drew DeVault:
> It simplifies the client design this way.

I guess it does.
But it also almost requires people to install plugins for their
standard tools (or to mouse-click in their editors).
I'm not sure whether I like that ? Gemini is supposed to make
everything more easy and leightweight, after all.

> Plugin 'https://tildegit.org/sloum/gemini-vim-syntax'
> autocmd FileType gmi set wrap linebreak

I'll check it out, thank you.

Link to individual message.

5. Γ–ppen (tva (a) fastmail.se)

> Period. This way, everyone can write maintaining the common width of 80

Mobile phones beg to differ.

Link to individual message.

6. Philip Linde (linde.philip (a) gmail.com)

On Sat, 14 Nov 2020 12:06:08 +0100
Philipp Stanner <stanner at posteo.de> wrote:

> But it also almost requires people to install plugins for their
> standard tools (or to mouse-click in their editors).

It doesn't require you to install anything, nor does it require you to
click your mouse. Perhaps you should read the NeoVim manual on
configuring wrapping behavior and display line oriented motions.

Quick guide:

Enable wrapping: set wrap lbr
Display line oriented motions: gj, gk, g^, g$, g0, ...

> I'm not sure whether I like that ? Gemini is supposed to make
> everything more easy and leightweight, after all.

It rather seems like you are overwhelmed by your editor here, not
Gemini. If you want easy, use tools that are easy to you.

-- 
Philip
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <https://lists.orbitalfox.eu/archives/gemini/attachments/20201114/094d
cd5a/attachment.sig>

Link to individual message.

7. Philipp Stanner (stanner (a) posteo.de)

Am Samstag, den 14.11.2020, 11:08 +0000 schrieb ?ppen:
> > Period. This way, everyone can write maintaining the common width
> > of 80
> 
> Mobile phones beg to differ.

Clients could still render it as desired on the phone.
Just like Markdown:
A single line feed is not printed as a new line by a gemini client, two
are.

Link to individual message.

8. Philipp Stanner (stanner (a) posteo.de)

Am Samstag, den 14.11.2020, 11:08 +0000 schrieb ?ppen:
> > Period. This way, everyone can write maintaining the common width
> > of 80
> 
> Mobile phones beg to differ.

Clients could still render it as desired on the phone.
Just like Markdown:
A single line feed is not printed as a new line by a gemini client, two
are.

Link to individual message.

9. Alexis (flexibeast (a) gmail.com)


Philipp Stanner <stanner at posteo.de> writes:

> Just like Markdown:
> A single line feed is not printed as a new line by a gemini 
> client, two
> are.

So the 30?000+ text/gemini pages (and maybe a number of the 
80?000+ text/plain pages that are actually gemtext?) currently 
reported by GUS would need to be reformatted by their authors?


Alexis.

Link to individual message.

10. Omar Polo (op (a) omarpolo.com)


Philipp Stanner <stanner at posteo.de> writes:

> I stumbled over Gemini a while ago and today tried to setup my first
> blog post.
>
> I take issue with the fact that a paragraph has to be one long line. I
> think the markdown way is perfect: Two newlines create a paragraph.
> Period. This way, everyone can write maintaining the common width of 80
> characters, and it will still be displayed as intended.

I think the reason for this choice is due to the fact that in
text/gemini you have different kinds of lines: paragraphs, links,
quotations, items and the ``` marker to switch to verbatim.  If you add
a rule to ?join? sequential non-blank ?simple? lines into one paragraph,
it can cause weird effects.

Let?s say you change some text in the paragraph and you reformat it:
your editor may decide to break a long line so that the next now starts
with a ?*? or with a ?>??  You can change the gemtext spec again so that
items and quotation needs a blank line before but? is ugly, isn?t it?

(this point is also aggravated by the fact that it isn?t clear if a
space after ?*?, ?=>? etc. is required or not, so clients can misbehave,
at least in theory)

I am not a fan of long lines and visual folding either, but it simplify
the syntax (good for parsers) and makes it difficult *for humans* to
introduce errors in their documents.

> For the first time in a long while I started to search neovim's help to
> find out if there's any way to have long lines and still work with them
> productively. Softwrap on or off doesn't do the trick, it's rather
> annoying when you want to edit something in the mid of a huge
> paragraph. `30w cw`...
>
> My life would be more easy if I could just do what I always did and
> wrap at 80. Considering Gemini will mostly target software people, I
> think that's appropriate.
>
> But if anyone here can provide me with a clever (neovim) trick to deal
> with these long lines, I'm open to hear about it.
>
> P.

Link to individual message.

11. Philipp Stanner (stanner (a) posteo.de)

Am Samstag, den 14.11.2020, 23:21 +1100 schrieb Alexis:
> So the 30?000+ text/gemini pages (and maybe a number of the 
> 80?000+ text/plain pages that are actually gemtext?) currently 
> reported by GUS would need to be reformatted by their authors?

In theory, better now than later.
Just think about all the other things which can't be improved or
changed anymore because they were established decades ago and now have
countless users and standards.
Gemini has no RFC yet (or does it?) so if there's a time when
adjustments are still reasonable, then it is now.

In theory.

But Polo's answer sounds rather reasonable anyways.

P.

Link to individual message.

12. Philip Linde (linde.philip (a) gmail.com)

On Sat, 14 Nov 2020 15:37:32 +0100
Philipp Stanner <stanner at posteo.de> wrote:

> In theory, better now than later.

Consider the advantages of a third option: never. To be frank, the
argument you've presented for this change is fundamentally that you
don't know how to use your editor to deal with soft wrapped lines, and
that it makes your life easier not having to learn it. What's the
advantage for the rest of us?

-- 
Philip
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <https://lists.orbitalfox.eu/archives/gemini/attachments/20201114/5e3b
fb5b/attachment.sig>

Link to individual message.

13. lel (lel (a) envs.net)

A solution to this problem for those who think this is an issue:

Just write a server that pulls single linebreaks back into one
line in source files before sending them to clients. Then you can
use vim more effectively or whatever without imposing change on a
spec already followed by oodles of clients and servers and
thousands upon thousands of pages of content.

Our options back when softwrap was decided were:

1) hardwrapping at some crazy small number of characters that
would only look good on a phone
2) optionally doing error-prone text reflowing that so it might
look good on something other than a phone
3) what actually happened

Each of these is still less complex than this markdown suggestion
and was done at a time when there was basically no content on the
protocol and even still didn't require anything to be rewritten,
because hard-wrapped content is still viewablw with softwrap.

What is being suggested would require substantial rewrites for 
literally every single thing ever created related to gemini, and
even if we accepted that, would require some means for new
clients to know the difference between the new spec and the old
one, either giving us a new mime type or some kind of version
header, and now we're in solderpunk's nightmare scenario.

So no, I don't think this will happen, but you could always write
a server that autoconverts your markdown-y content into gemtext!

best,
lel

Link to individual message.

14. James Henderson (henderson.j (a) protonmail.com)

> In theory, better now than later.

Or not at all. If you want markdowns line ends then use markdown.

>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.orbitalfox.eu/archives/gemini/attachments/20201114/c745
b7f7/attachment.htm>

Link to individual message.

---

Previous Thread: Geminisphere

Next Thread: (proposal) on metadata in documents