Hacker News new | past | comments | ask | show | jobs | submit login
The Command-Line Office (ebeab.com)
131 points by marcuskaz on March 4, 2014 | hide | past | favorite | 62 comments



The author of this article uses pass [1] for password management. I'm the author of pass, if anyone here has any questions.

[1] http://www.zx2c4.com/projects/password-store/


Whoa, fancy seeing you here.

pass is pretty much the ONLY password manager I have actually found useful, and I have tried a LOT of them. I wrote about it here:

https://news.ycombinator.com/item?id=7175888

Also, I have a personal use "fork" (scare quotes cause its not really a fork, just an personal work-in-progress) on github:

https://github.com/abgoyal/password-store2

Its an attempt to fix the "leak" of sitenames/usernames I talked about in the HN thread linked above. I am sorry, I have not gotten around to fixing the READMEs etc yet. Is this something you would be interested in merging?

In any case, big thanks for making "pass". Its a pleasure to use.


I've been using it for a while, thanks! I had my own cli-based password manager, but yours is simpler and better.

I've made a few tiny hacks to make it work better for me: - add a default length to the generate command - allow abbreviating 'generate' as 'gen' - default to copying to clipboard instead of stdout - use xsel instead of xclip (no real reason except I already had it installed everywhere)


> The author of this article uses pass [1] for password management. I'm the author of pass, if anyone here has any questions.

Ah! I installed pass a few days ago! I was wondering why you decided to use gpg to encrypt instead of mcrypt (which would be "easier" to set up for the casual end-user since he'd only need a password and not a keys) ?

I also wished you could post your cgit.conf because I remember having troubles achieving something with mine but now I can't remember what. Well.

Also, are you involved with http://git.zx2c4.com/pulseaudio-raop2/ ? If so: any chances of progress being made in the near future ?


I eventually want to make a GUI equivalent as I learn to program, and had some other ideas that you have inspired as I try to get back to programming.

THANK YOU! I love your tool and it is one of my favorite tools. I check your git for other cool stuff as I stumbled upon your stuff many times.

Question: would you want to add a parameter to escape non-aplhanumeric characters? It took me a while of playing to figure out how to get mutt to handle my very complex IMAP passwords.

For anyone who cares, I do it with sed.

set my_pass=`pass email/this@email.org | sed 's/[[:punct:]]/\\&/g'`

#


Random question (I have no clue of mutt or Unix shells (the code there looks like one)): But isn't that a problem of the receiving application? You can't really ask every single application that outputs text to sprout arguments to support every possible escaping that might be needed eventually. And whatever comes out of the `foo` part shouldn't be interpreted or parsed anyway, right?


how about

    set my_pass="`pass email/this@email.org`"
[edit] Looks like this is a muttrc line not a sh line. Sadly I don't think muttrc supports the far superior $() expansion..


I tried this and it does not work. And yes, mutt does not support $() escaping.


Great tool! I found out about it just now from the article.

Any thoughts of cross platform compatibility for the future? I find one of the best features of KeePass is the fact that it can be used on all my computers (even the ones not running Linux).


Just added it to my cli toolbelt, thanks!


great tool, thanks!


I'm a big command line fan, but vi/emac/nano are not word processors. They're text editors.

You might be able to get close if you are using them to edit Markdown and running it through Pandoc (especially if you add in a non-commandline PDF viewer). But still.

WordPerfect 5.1 - now that was a curses/command line word processor :) I don't know of a modern equivalent though.


Wordstar before then. It's a real shame that it is still legally encumbered, I'd love to use it on a modern system. http://en.wikipedia.org/wiki/Wordstar

I actually found the other day I have a ROM for Wordwise+, the first word processor I ever used, for the BBC Micro. I might see if I can get away with doing some "real work" in it :-) http://en.wikipedia.org/wiki/Wordwise


Had a Microsoft Z-80 card in my Apple ][ just to run CP/M just to run Wordstar. Once AppleWorks came out, never booted to CP/M again. Also, ImageWriter and Epson MX100. :-)


What is your definition of "word processor"? Emacs + auctex? Emacs + orgmode? Words are text.

Do you feel better if section headings are bigger and take up more space than the text you are supposed to be working on:

latex: https://i.stack.imgur.com/etFst.png

org-mode: http://blog.nozav.org/public/images/tangotango_org.png

org-mode with pd preview: http://i1.ytimg.com/vi/lsYdK0C2RvQ/maxresdefault.jpg

Or is emacs excluded from being a word processor because you can also use it for powerpoint presentations: http://salomie.ro/tudor/wp-content/uploads/2010/10/orgmode_p...


Well Emacs can almost but not quite be everything of course.

But this is a pretty common distinction, surely?

Words are text, but word processors have historically been focused on preparing documents for printing (or nowdays viewing a visual representation of a printed document onscreen, eg PDF).

They handle differing visual layout (fonts, page breaks, margins, indenting). They are softwrapped and paragraph based not line based. Often they deal with formatting through styles - headers, bullet points, numbering. They usually handle inclusion of tables, images and other non-text elements.

The most common example of a word processor, Word, also handles collaborative writing with tracked changes and notes, and has inbuilt features such as on the fly word count, spelling and grammar checks.

As I said, for a command line word processor look at WordPerfect for DOS or equivalent.

What you are saying (and it is not entirely wrong) is that you can approximate a word processor by matching a text editor with a bunch of other programs (TeX, Pandoc, aspell etc). But that doesn't make the text editor a word processor.


The unstated distinction you are making is between a program a novice can use for word processing and a program that requires some level of experience. I will grant that ed/edlin/nano are not word processors. But excluding emacs from the category is just as absurd as including ed.

Have you used emacs in the past decade? Some of your requirements are laughable. Softwrapping? visual-line-mode has been baked in since 23. Word count? wordcountmode. Tables? I will take orgtbl mode over the libreoffice/ms-word interface any day. Bullet points? Nothing comes close to orgmode for manipulating/moving/adding bullet points.

Apple's Pages did not get "track changes" until 2012. Was it just a text editor prior to that?

Sidebar: It is kind of funny that you like WP 5.1 and are a lawyer. Were you ever a lawyer in the states? The only people I have ever heard gush over WP5.1 were lawyers. I never realized the fetish was global.


No, I'm not making that distinction. I'm just saying that text editors and word processors have historically and up to this day been somewhat different beasts written for different audiences with different focuses on their features.

Sure, I can do emacs with softwrapping to write my next legal contract. I can also do text editing in Word for my next LaTex document. But I wouldn't want to.

This is not an obscure distinction to make.

Sidebar: Actually I much prefer a recent Word to WordPerfect 5.1. But the question was command line tools, and WordPerfect 5.1 is a good example of a terminal based document creation tool focused on creating, well, documents. It should be easily possible to make a modern equivalent - a terminal based editor focused narrowly on the creation of the same sorts of documents Word is good at. But I don't know of one, and a tricked out emacs doesn't really get there.


WordPerfect was great because it was essentially a text editor with a markup language. When formatting wasn't coming out quite right it could be debugged easily with by pressing the key to "reveal codes".

The other thing that made WordPerfect great was their technical support. Free and unlimited over the phone...and they new what they were talking about and if it was a genuine bug, they would have an engineer call you back on their dime. Or at least that's what happened when I found a bug in Summer of 1992.

Microsoft Word buries its formatting. Sometimes it's easier to just nuke a file to text and reformat the whole thing than to try to solve conflicting formats overlapping.


You need a ruthless discipline to use Word in anger, do everything through styles and nothing "manually" otherwise it all goes to hell. Unfortunately Word makes it all too easy to do.


Which makes it nearly impossible to collaborate with other that don't think like that.

It seems like nobody I work with even knows what styles are.


Wait, can you style text in Emacs? Fonts? Colors? Bold, underline, italics? Isn't that the whole point of a word processor?


Yes you can do all of these things in emacs.


The crucial distinction between a word processor and a text editor is that the word processor hides the formatting instructions from the user, and instead displays formatted text. Text editors display text in all it's glory. Nothing is hidden.


Many people would role their eyes at the idea of using a chain of console tools for document production, think of it as contrived. But it's not such a fancy idea. One of the first things to work on unix was roff, an ancestor of the man page system. It processed text documents into a printable form.

Most serious document production company (publishing companies and newspapers; legal firms are probably less sophisticated) have a similar pipeline within their firm. Text (raw or rigidly styled), version-controlled, running through a pipeline of reviews and signoffs and markup and arrangement.

   > I don't know of a modern equivalent
I don't think monolithic word processors will be a feature of the future. The mainstream tool will be some kind of style editor. Maybe it'll incorporate a spellcheck and some other monolithic features. There'll be a pipeline underneath - to send things to paper or web or archive or accounts.

We'll think much more in terms of snippets of styled data, and its lifecycle. We'll laugh at memories of these laborious monolithic word processing systems, and how we thought that this was productivity.


The mainstream tool will be some kind of style editor. Maybe it'll incorporate a spellcheck and some other monolithic features. There'll be a pipeline underneath - to send things to paper or web or archive or accounts.

LyX is already (mostly) there: http://lyx.org While it's mostly LaTeX based, I could easily see it using any number of backends (another feature of pipelining underneath), such as markdown, roff, etc.


Also, vi/emacs/nano are not one would call "command-line" text editors (they are text-mode/console-based though). See "ed" for one.


This is convenient timing for me. I was just thinking about dual booting to a stripped down cli only arch install on my netbook for fun. I hadn't even thought about having some basic spreadsheet functionality.

Should be interesting to mess around with.

Not an office app, but I think tmux is probably my favorite all around need-to-have, for when I'm working cli only.

edit: this also makes me think it wouldn't be too hard to write an excel as a service layer on a normal windows machine, then use the cli comp to interface with it. You wouldn't get the fancy formatting, but you could pretty easily get the calculations and such, as well as some basic formatting. Also not tough to make it save itself and send it out via outlook or whatever you want. Without all the nutty formatting, the data transmission could be pretty light weight. Wonder if anyone's done that. Might screw around with it if I have spare time


Using a cli for everything is an extreme proposition! You'll probably get tired of it quickly and choose to add some fullscreen text mode programs to the mix, like vim or emacs. For a "full featured" console environment, add some programs that use the frame buffer to display images, you can probably setup your netbook to be pretty serviceable without installing a windowing system at all.


Yeah; I use vim as my editor of choice (outside of my job which is actually .net, heh).

I have other computers I use a lot, and I'd never 100% give up on gui's. Mostly I'd be setting up an environment that boots quickly, reduces background processes, and gives me a nice retro place to code in when I'm tooling with haskell or c. I also like having an environment that I've fully optimized for keyboard only.

The excel part would just be an interesting convergence of what I do at work with windows, and what I use mostly at home.

I've never messed with frame buffers in terminal; that'd be really interesting. Maybe I'll see if I can get to something more fully functional after all. I've always gone pretty much easy-mode when it comes to linux. I want to get more hands-on with the distro


>Yeah; I use vim as my editor of choice (outside of my job which is actually .net, heh).

In case you haven't seen it: ViEmu is a great addon for Visual Studio.


I tend to consider (n)curses be command-line. In fact I suspect that most people would consider "command line" to be more akin to a VT100 than a teletype.


You might be interested in the axlsx ruby gem: https://github.com/randym/axlsx

Haven't used it, but it allows the creation of pretty complex spreadsheets from ruby code. Not sure if it is able to read from spreadsheets, but it could be one part of the service layer.


The author seems to be advocating text mode, not strictly command-line. Editing files with sed is command-line; editing them with vi or emacs or nano is not.


Maybe terminal is a better phrase I should of used than command-line, or maybe non-X or non-Windowing environment


Text-mode is the term I use; I've heard "TUI" used as well. Non-windowing isn't a good name since I think this is clearly windowed: http://superuser.com/a/323614


Or with ed. But to many that's equally painful.


Or, God forbid, MS-DOS's version "edlin".


I've finally hit upon an electronic calendar scenario I am happy enough with to try for a few months. I use calcurse, with the main directory for daily, and subdirectories for Weekly, Monthly, Quarterly, and Yearly.

I have aliases defined to reach these subdirectories because I am lazy:

       # calcurse stuff
	export Week='-D .calcurse/Weekly'
	export Month='-D .calcurse/Monthly'
	export Quarter='-D .calcurse/Quarterly'
	export Year='-D .calcurse/Yearly'
I use tmux and a startup script to open daily, weekly, and monthly

  #!/bin/bash
	# Start a session named cal, name the window "Day", 
	# pane.  Detach the session for the setup process.
	tmux new -s cal -n Day -d
	# Create second window named "Week", split it and      select left pane
	tmux new-window -t cal:1 -n 'Week'
	# Create a third window named "Month", split and select left
	tmux new-window -t cal:2 -n 'Month'
	# Load the calendars
	## Note ^M and Enter seem to do the same thing
	tmux send-keys -t cal:0 'calcurse' ^M  
	tmux send-keys -t cal:1 'calcurse $Week' ^M
	tmux send-keys -t cal:2 'calcurse $Month' Enter
	# Select window 0 and re-attach the session so we can reach it.
	tmux select-window -t cal:0
	tmux attach -t cal
Now I can set up tasks and priorities, and update according to the work plan. Share via rsyn. And not dependent on the cloud (I can rsync to a stick). Drawback; it is not integrated with Evolution or Thunderbird.


Just for future record, the script I actually use has two returns at the end of the send-keys lines

        tmux send-keys -t cal:0 'calcurse' ^M  ^M
	tmux send-keys -t cal:1 'calcurse $Week' ^M ^M
	tmux send-keys -t cal:2 'calcurse $Month' Enter Enter


This is actually a list of obscure (20 years of Linux use here, and I haven't heard of most of them) command-line utilities. Definitely going to explore calcurse


I'd consider aspell and remind to be well known linux tools. Pandoc is more modern, but probably the most widely used markup conversion tool. Gnuplot and matplotlib are both very popular for graphing.


Roaring Penguin's remind is a great piece of software, it's been a standard for me since around 2000. Don't forget their include files for stuff like holidays and seasons.


If you haven't used wyrd, go check it out. You'll thank me later.

http://pessimization.com/software/wyrd/


Hah. Great article!

Also:

* https://github.com/sup-heliotrope/sup for decentralised and lightning fast email. Written in Ruby, very hackable.

* http://orgmode.org/ Although I'm a vim user, I use orgmode for: All my todos, clocking hours for clients, spreadsheets for my training, research notes, calendar, anything else that needs organising and planning.


How do you use orgmode in vim? I would love to have orgmode in vim.


I think timonv uses vim except for orgmode. In any case, there's https://github.com/hsitz/VimOrganizer


Also worth looking at: http://www.ledger-cli.org


Would be good to add Task Warrior on top of Todo.txt, though.


I'm writing a book, in my terminal. Have been for a while now, maybe 6 months, and all done through an amazing application called Wordgrinder. An old version should be in your distros repository (I know it's in Debian anyway). It's awesome to boot up to TTY1 and just start writing, no distractions possible. It's also entirely written in C and Lua so it's quite fun to hack on as well.


Shameless plug for more terminal-based slide/presentation software: now with fading, 256 colour transitions and experimental PDF export!

http://github.com/jclulow/vtmc



Very nice! I have made one as well[1], it is based on Markdown and not nearly as fancy.

[1]: https://github.com/arnemart/slid.js


allow for both the Correct and the American spellings …

Very funny. :-)


I was totally unaware of sc. My spreadsheeting life just got immeasurably better.


it was very famous 20 years ago when X configuration required complex frequency calculus.


Fun fact: The first time I tried ubuntu, in order to get my monitor working at its highest resolution I had to add a modeline to my xorg.conf

I had been previously using gentoo, where I selected the resolution from a gui. The difference was seems to be ubuntu adopting nouveau a bit earlier than they should have.


Or, how to live in UNIX System V, CP/M and MS-DOS days.


The good old days, I call 'em!


For me, the big one missing would be Skype. There seems to be a command line client called Clisk though, so perhaps that might be worth checking out.


shameless plug: if you want terminal calendaring with CalDAV support you might want to try khal [0], it's still in an early stage of development but it already seems to work well enough for quite a bunch of people.

[0] https://github.com/geier/khal/


taskwarrior !




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: