Suggestions: A simple human-readable format for suggesting changes to text files
suggestions.ink
suggestions.ink
I'm just curious who this is for? I've done lots of collaboration with Word and Docs. And with code in git.
But I'm having a hard time imagining the scenario where you would be using a plaintext file to make suggestions.
Like is this for committing documentation changes in git but you want someone else to review them first?
Or is this meant for e.g. papers in LaTeX?
Or something else? I just feel like I'm missing the full context here. When do you need to provide suggestions but it's important to be plaintext rather than rich text like Word/Docs?
My workflow is a .tex file checked into git repository that everybody has full access to. We do a lot of face-to-face conversation to make sure that we are synchronized with our changes, which I think is a really good thing, but it is nice adding commentary in line. Instead of some ad hoc system with comments, this scheme adds a little bit more discipline that might be welcome.
I understand it has some actual virtues as an editor/programming language, but to me (a non-academic) it seems to mostly function as a group membership signifier.
Thoughts on the spec are very welcome. I’m considering --[ deleted // added]-- as a shorthand for a common case.
Curious if you’ve thought about attacking this problem, or have seen any other tools that solve it elegantly?
There's a tension between "making it clear what the change is" and "making it clear what the old and new versions are".
One approach would be something like --[MOVED X: blah blah blah]-- ... +[FROM X: blah blah blah]++.
A more radical one is --[>>>]-- ... ++[<<< blah blah blah]++ where you actually delete the content from its old position, leaving only a marker.
I'm wondering how it compares to https://github.com/CriticMarkup/CriticMarkup-toolkit
I haven't tried using either yet; does anyone here have any opinions about features/ergonomics/tooling?
I mildly prefer having the marks outside the brackets: ++[foo]++ seems easier to read than {++foo++} because the "wrapping" is outside the "box".
Step 1: give me your edited `.tex` file.
Step 2: I selectively merge it into mine.
Step 3: There is no step 3.
To selectively merge, I use `meld` https://meldmerge.org/ but there are others.
Benefits of this even simpler approach:
- We continue to use the tools we are used to.
- We and our software don't have to learn a new inline diff format.
- Both files retain valid syntax before and during the selective merge.
- I can choose chunks to accept with a simple mouse click instead of editing a diff chunk.
If I am the person who has to incorporate these suggested changes into my document, having to delete two segments, one on either side, for each change is not an ideal experience.
If this type of formatting does become adopted, I would recommend that the process of accepting or rejecting the change be done programmatically, rather than manually. I could envision a small utility program that is fed a file with this text format and allows the user to interactively accept or reject the changes without having to do the deletions within the file itself.
The proper way is of course to actually use format/tools/apps with builtin feature for such needs, as addressed in the beginning of the landing page. There is initial cost for adopting it, but if you actually doing it regularly (novelist/journalist/programmer) it would make more sense in the long run.
In the end its about tradeoff. If your medium is limited and you only need it for once in a while, this format is simple & clear. But for more frequent uses I think this format is costly to maintain compared to using specialized tools/apps.
I’ve been toying with the notion of using Typst as the source of truth to assemble contracts so I’m going to give this a spin.
we don't need to create a new tool just to stop people from learning the right one
For those using markdown, I highly suggest newline after every sentence.
html started simple, and went down a path of unreadable complexity.
markdown has already started down that path with the mathjax stuff, urls, images, etc, all of it ugly and paradigm shattering. The markdown document should be fully readable; the new changes are making it "nope, you're gonna need a viewer". I think people gonna need to learn to comfortably read markdown.
i'm not opposed to this suggestion (as if what i think matters to anybody but me), but seems to me it needs to be considered in light of other semantic needs other usages might want, and hopefully the discovery of common syntax elements that serve multiple/overlapping purposes, something that's not simply one weird scheme within another weird scheme. This syntax seems busy. What's the justification for each and every additional character?
I'd rather see (maybe/depending) a diff based "view both side by side" sort of tool working from two versions of the file, perhaps with an annotation file. I'd differentiate between changes that fix typos ("must haves") vs fixing language/meaning ("requests")
I think it's a big mistake to go the way that C (for example) went, where every possible ascii character has a meaning, and nothing can be changed without breaking it.
markdown needs a Benevolent Dictator for Life for the time being.
The syntax is quite close to git's --word-diff syntax
The [-old-]{+new+} word is betterI’m not sure using git is any more or less difficult than suggestions.
A proper vcs for documentation is what Wikipedia does.
You always see the latest version of a document and you can see the changes to that document, revert and follow renames.
No global history, no commits of multiple files, no manual pull/push, no branches, no CI, no pr, no rewrite of history, no multiple remotes, etc etc etc
I think this is not git problem, rather diff tool it's using? Wonder if using another one, e.g. difftastic[1] would be a better experience.
The PR/MR is the biggest win, being able to comment on, discuss, suggest, resolve and 'sign off' changes works better in a PR/MR than any other versioned tool I've seen.
It is a bit messy once suggestions get nested, and given the option I’d still strongly prefer visually separating the change suggestions from the original content by pulling them out to aside blocks, but - if you held a gun to my head and forced me to do it all in plaintext, I wouldn’t hate this method.
%%[
% ... would work
% for an aside...
%%]
but I wonder if it is too much effort for most people to arrange.The html formatter prints comments in <aside> blocks, which is possibly incorrect but the closest semantic match.
Think 'heredoc' like syntax or <!-- --> from XML/xhtml.
If two deletions partially overlap then they can't be acted on easily either.
I am unsure if the suggestion files are meant to just be snippets long enough to uniquely identify where changes are meant to go, or the whole file again but with change suggestions.
--[
]--++[ ]++
%%[The following paragraph should be merged into the preceding paragraph. @dotancohen]%%> style it yourself
Not my area (am back end guy). Can you give some links, I don't know how to, TIA
> %%[Is this clearer? @stephen]%%
> You can sign the comment with a @handle as the last word.
Author seems to fundamentally misunderstand the significance of having "@" precede the names of folks in the conventions of online discourse. "@" means "at". You're addressing someone. In this example, they're signing off, instead—the exact opposite. Their prescribed format means that if you encounter a message like the one in the above example somewhere in the wild, then you have to be very careful to stop and consider the context to disambiguate between whether it was written by someone (who is not Stephen) expecting Stephen respond to the question, or whether it was written by Stephen himself expecting someone else to answer. This is bad design.
(The choice of "%" to denote comments is also pretty odd—particularly for a format that's supposed to be more human-centered than other more traditional formats. It strikes me as something that was arbitrary more than anything else.)
More seriously, it's called an "address" because people can "address" you with it. There's a natural overlap between at-ing somebody, and putting your name up so that people can at you. The @ sign helps clarify that is what this is, and it also differentiates it from the text. Have you got a simpler and more intuitive alternative?
The linked proposal reverses this by turning "@foo" into a signoff/attribution instead of an address, increasing the amount of ambiguity in communication—"Wait, what conventions are we following? The natural way of reading things, or are we in the world of Suggestions files where up is down?"
> Have you got a simpler and more intuitive alternative?
Yeah, the way people have been doing it forever:
--stephen
You don't need to invent new syntax for it, let alone counterintuitive syntax.I see the strength of your argument, but I suspect it works better for the extremely online.
Someone else already pointed out the existing "plain word diff" syntax[1] that (a) is actually more human-friendly and (b) neither you nor the other respondent actually addressed—you both just pirouetted around it while hoping that no one would notice, I guess (by changing the subject to how bad Git and GitHub are—true, but completely irrelevant to the merit of using --[foo]-- over [-foo-]).
> One would be ~~[ ]~~
That would be genuinely terrible—for basically the same reasons that --[foo]-- is worse than [-foo-], but more extreme.
> it works better for the extremely online
I thought this was supposed to be designed for actual human beings?