Live data from Hacker News

Write plain text files

sive.rs

311–320 of 425 posts

Re: Write plain text files

#311
post #47
post #35

Another advantage to plain text files: source control. You can check your writing into git and get a history of all your edits. It’s something programmers take for granted, but it would be amazing if this got more widely adopted outside of tech. The number of files with names like “Report Final Final draft v3.docx” is truly staggering. “Git for everything“ would be a multi-billion dollar startup easily.

I was actually surprised : last time I used Git Bash on Windows it did work quite well with .docx files. Then I switched jobs to avoid touching .docx files ... The best alternative I've found to generate .docx output is R markdown, which uses pandoc under the hood and let's you program the whole document the way LaTeX would.

Pre LaTeX (I am old...) I wrote a huge command definition document for an embedded telecom product in nroff/troff. The whole thing was text files, with all the common parameters documented once, and the whole thing was assembled using a Makefile. So a typical page would be the command name, a descriptive paragraph, an include list of the parameters it used, and an include list of the possible return errors. Very little writing for a new command that mostly used existing parameters and errors.

And all tracked under CVS with a management/tracking layer on top.

# make command_doc

and the pile of text became a lovely 250 page postcript ready for the laser printer.

Re: Write plain text files

#313

Earlier quoted context omitted.

Isnt docx binary ? So git is storing a new version of the file every commit. That way too much storage space youre wasting.

I've heard somewhere that docx is actually gzipped xml. But I never really confirmed that myself. But it's binary once gzipped, so your point still stands.

[deleted]

Re: Write plain text files

#314
post #46

Earlier quoted context omitted.

Yeah, in high school I and another student did our essay peer reviews using annotated diffs once. It was so much easier than Google Docs, since we didn't have to leave our editors. Wrapping version control with a non-tech-friendly porcelain could help a lot of people escape user domestication from vendor lock-in.

I don't care how much porcelain you add. Using git effectively beyond add and commit requires undestanding quite a few concepts. Mass adoption of git in the consumer space ain't happening anytime soon.

It cracks me up that this many years later, you put five people in a room to establish a git branch/merge/release strategy, and you get five very different opinions, and such strong opinions they are.

Luckily, that responsibility is not in my wheelhouse, I just have to live with whatever decisions are made.

So yeah, mass adoption in the consumer space, I don't see that happening.

A revert or a rebase gone wrong and wails of "what happened to my file?"

Re: Write plain text files

#315
post #279

Earlier quoted context omitted.

I once thought git for humans would be a great idea but never got around to speccing it out. Later on, a lawyer friend showed me the software they used 'for backup' (that they paid thousands per month for) and it turned out everything about it was just exactly like SVN. The terminology was different, the UX was laser focused to the intended users, but at the end of the day it was commits, syncs, merging, pretty much…

I tried to git my resume once upon a time. It's still something I'd love to finish doing, it just makes sense to have a git repository as a timeline of your life: https://github.com/ben174/bugben

My official CV is a page on my site, that I print to PDF if someone asks for it. The page itself is as source-controlled as the rest of the site.

Re: Write plain text files

#316

I disagree with the whole "NEED VISUALS OR GRAPHICS?" section. I do need visuals! I do need graphics! I'm not a typewriter, why must my flow be interrupted with me having to leave my document to open some JPEG file whenever I need to show something that isn't text? It's not like this is crazy difficult or requires proprietary apps either. Writing a modern browser may be an impossible feat but I'm certain that it woul…

> but I'm certain that it would take just a day or two to get a very simple barebones HTML renderer which supports and a couple of formatting options. https://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect This tells me you've never actually tried this. For example the img tag allows you to, amongst other things, render an svg. If you want a more full spec you can see here what it takes to render an img element:…

> For example the img tag allows you to, amongst other things, render an svg.

I don't think the GP meant "write an image renderer" when they said "get a very simple barebones HTML renderer". Most languages have libraries for encoding/decoding images in various formats, so aside from how it would fit into document layout, this is a non-issue.

Re: Write plain text files

#317
I was also looking for a way to better visualize text as a set of notes while still using markdown and .txt, then I came up with the idea "Sticky notes + Markdown + Tabs, All in one .txt file"[1].

It's nothing fancy, just a prototype using electron and vanilla javascript, but it might be useful.

[1] https://github.com/zonetti/zonote

Re: Write plain text files

#318
post #35

Another advantage to plain text files: source control. You can check your writing into git and get a history of all your edits. It’s something programmers take for granted, but it would be amazing if this got more widely adopted outside of tech. The number of files with names like “Report Final Final draft v3.docx” is truly staggering. “Git for everything“ would be a multi-billion dollar startup easily.

> “Git for everything“ would be a multi-billion dollar startup easily. Worked on a “Git for Word” project [1], which is currently on hold. The diff part was manageable, though not trivial to get diffs that make sense for prose/regular text. The hard parts are UX/UI (making Git concepts transparent to “normal” users) and merging. Yet without automatic merging, branching is not very convenient. Would love to collaborat…

I don't think merging will ever be fully solved by software. It's a problem created and solved by process. How annoying merges are is entirely dictated by process.

Sourcetree is the best git GUI I've used. That could be used as a model.

I think an old-style solution to merging would be fine: output a word file that uses a unique font style to indicate which user made what conflicting changes, have the user edit the document and remove all of the "merge styles", then continue.

Re: Write plain text files

#319
post #35

Another advantage to plain text files: source control. You can check your writing into git and get a history of all your edits. It’s something programmers take for granted, but it would be amazing if this got more widely adopted outside of tech. The number of files with names like “Report Final Final draft v3.docx” is truly staggering. “Git for everything“ would be a multi-billion dollar startup easily.

> “Git for everything“ would be a multi-billion dollar startup easily.

Didgets (recently surfaced here on HN) seems like a sane approach to this, from the file system up. Pretty incredible performance too.

https://didgets.substack.com/p/where-did-i-put-that-file

Sadly not (yet) open source, though the developer is considering it.

Re: Write plain text files

#320
post #35

Another advantage to plain text files: source control. You can check your writing into git and get a history of all your edits. It’s something programmers take for granted, but it would be amazing if this got more widely adopted outside of tech. The number of files with names like “Report Final Final draft v3.docx” is truly staggering. “Git for everything“ would be a multi-billion dollar startup easily.

I mourn that StackEdit [1] got abandoned. It's online markdown editor that can use git as a backend. Fully cross platform editing (in browser) with synced all text. I used it with GitHub private repository for all my notes but editing on mobile was really buggy. So I moved to notion (unfortunately).

[1]: https://github.com/benweet/stackedit

Post reply on HN