10 ms·
The thesis of this post is roughly that nano, when configured, is enough of an editor for the author. Which is totally fine! People should be happy with their
by ctur 5y ago
The thesis of this post is roughly that nano, when configured, is enough of an editor for the author. Which is totally fine! People should be happy with their tools and not feel pressured by popularity to use what others use (vim, emacs being prime competitors in this case).
Alas, nano (and pico before it) have a certain stigma among more "experienced" Unix users that more or less boils down to gatekeeping and snobbery. Which is a shame.
That said... it is worth considering that learning tools like editors is an investment in one's self and pushing through preference to genuinely try to use what others find value in can, if nothing else, help you better understand what you value and adjust your tooling to fit (much like the author adjusted Nano to be more like vim).
That's a pretty nuanced distinction though and I am glad that the author feels comfortable owning their preference and not feeling pressured by peers to conform to more "acceptable" choices while still having tried and learned from them.
- relax88 5y agoIt’s not really gatekeeping or snobbery to say that knowing vim is more useful simply because I can log into any Linux machine on the planet and edit a text file without having to install an editor.
- hkt 5y agoIs installing an editor really such a hardship?
- dllthomas 5y agoUsually not, sometimes very much so.
- yakubin 5y agoIn "linux embedded", absolutely. You take what's there. At some point I even had a debugging session through TeamViewer connected to a Windows machine which had Terraterm open connected to serial port of a linux box. Unfortunately, there was a lot of spam on the serial port, so even using vi was impossible, because the screen got garbled pretty fast. So I printed the files with cat, worked out a set of sed commands to get those files to the desired state and typed them back in. Crazy. But real. (Add to that communicating with a guy on-site over notepad.exe. Mr. Robot vibes.)
- orthoxerox 5y agoYes, because your sysadmins won't give you sudo, so you must scp a copy of nano into your home dir. Surprise, it's an AIX server running on Power, so your x86 nano won't run. Does building one from source count as hardship?
- emef 5y agothis is less true these days w/ slim docker images that don't include any editors by default
- dijit 5y agoDoesn’t POSIX designate vi as a requirement? https://ieeexplore.ieee.org/document/6880751 https://ieeexplore.ieee.org/document/6880751
- yakubin 5y agoPOSIX doesn't say anything about containers.
- dijit 5y agoBut your containers may be a bit weird if their environment isn’t POSIX. Like if you removed the “cd” command or the ability to read environment variables. “Containers” is any definition you want, but surely they’re built to some standard. PS: I do make “from scratch” images a lot, I know you don’t “need” to have any utilities at all, but I’m fairly certain that a lot of software expects the “OS” to be POSIX.
- yakubin 5y agoI don't know what you mean. Linux containers don't contain operating systems. They contain processes. POSIX describes operating systems. Every Linux process can read environment variables. They are contained in its address space. "cd" is a shell built-in. When there is no shell, there is no "cd". Not providing access to a shell sounds like great security practice tbh. Your applications shouldn't be using it anyway (they should create new processes directly).
- messe 5y agoThis is just being obtuse for the sake of it. Yes, technically nothing in the notion of a container necessitates that; containers are just a form of namespacing. Have a gold star for understanding that. But the fact is: the vast majority of containers in use are going to be based on some minimal OS image, which is what the commenter was referring to.
- aroman 5y agoThey probably meant snobbery that vim is superior because it's more capable, not because it's more ubiquitous. Nano is also very widely installed, so the latter point isn't even particularly true.
- brundolf 5y agoEvery Unix machine (Mac or Linux) that I've ever tried to use nano on has had it preinstalled. I'm sure not all of them have it preinstalled, but it's common at least in mainstream distros
- relax88 5y agoIf you’ve never logged into a Linux machine without nano installed, then you probably haven’t logged into that many flavours of Linux machine. I agree this is pretty much a non issue for the average developer, but those of us who work on network infrastructure, as red-team hackers, or do any work on embedded systems can attest to how much of a pain it would be to not know how to use vi/vim.
- koolba 5y agoThis is even more common in the world of containers where “nice to have just for debugging” get omitted. You haven’t lived till you have to edit using only sed.
- KronisLV 5y agoThere is definitely something to be said about having minimalistic container images for security and smaller sizes... But not having a basic text editor that is probably a few hundred KB feels a bit silly, especially given how many environment dependencies usually get packaged into containers anyways. That's like not including any sort of a shell in your container and wondering why people are having troubles with debugging. Personally, i think that just basing container images on something like Alpine, Debian or even Ubuntu images is good enough because those are stripped down enough already for the most part.
- koolba 5y agoOf course you add a sane editor after it happens. But that first time…
- trissylegs 5y ago
- bluedino 5y agoExcept when it's vi and casual vim users can't figure out why nothing works
- trey-jones 5y agoAren't casual vim users really vi users? I use emacs primarily but years ago created an extremely minimal (~20 lines) .vimrc to be installed by default on every server I work on. Some color, maybe indentation, I don't even know because I usually just use Emacs/TRAMP these days, but I'm nearly 100% sure that every config there works in vi. I would consider myself a casual vim/vi user in that I don't know the differences.
- hn8788 5y agoI may be misremembering, but the biggest differences I remember between vi and vim as a semi-casual user is vi defaults to not supporting arrow keys, and doesn't tell you the mode it's in.
- wahern 5y agoI can't remember the last time I used vi and was unable to use arrow keys. That includes typical Linux installations (Vim, Busybox), Solaris (default is Vim, oddly, but I just confirmed arrow keys work in /usr/xpg4/bin/vi), and various BSDs (nvi). I'm not a power vi user, though. I usually use JOE (thanks/blame to '90s Slackware education), but occasionally vi is more convenient. It wouldn't be nearly as convenient without the arrow keys as I never learned proper typing technique.
- bluedino 5y agoRaspbian, for example included vim-tiny
- deleted 5y ago[deleted]
- citrin_ru 5y ago
- babypuncher 5y agoI've never worked with distros targeting enterprise, but I've never encountered a distro that didn't include nano. Even if Vim is "better", I think it's important for all distros to include a text editor that is easy to use out of the box, and nano fits that bill perfectly.
- KronisLV 5y agoIn my experience, the DEB distributions (Debian, Ubuntu, ...) usually have nano by default, whereas the RPM ones (RHEL, CentOS, Oracle Linux, ...) don't. That said, i immensely enjoy how small the install size for nano is and how there's no actual work that you need to do to get started with it (unless you need/want customization, like the author of the original article).
- snowwrestler 5y agoWhen I first started working in Linux, it was in Centos and RHEL and I used nano, since it was already installed and easier to understand than vim. That was about a decade ago though, maybe RHEL has removed nano since then.
- ineedasername 5y agoThat said, i immensely enjoy how small the install size for nano I used to install lynx web browser for the same reason, especially because at the time it was the age of countless popups and swf everywhere. I should check to see how it is these days, but I stopped using it when webdev made many pages unusable in it.
- shapefrog 5y agoIts not snobbery if it is better
- jakelazaroff 5y agothat’s literally what snobbery is
- shapefrog 5y agosnobbery: the character or quality of being a snob. snob: a person who believes that their tastes in a particular area are superior to those of other people.
- loudtieblahblah 5y agoBut Vim is superior in many ways. Nano is superior in that its easier to use. But it's certainly no where near as powerful as Vim or emacs.
- IncRnd 5y agoThat's funny!
- sdljfjafsd 5y agoDespite having 7 years of back end experience, I've never learned vim. Is there any other editor that hits these requirement (being able to login to any server to edit text) or does every server engineer need to learn vim? (I mostly use a mix of sublime, intellij, and vscode to edit text)
- hulug 5y agoed(1)
- ineedasername 5y agoThat's probably the #1 reason to learn the bare basics of vim even if nano was a daily driver.
- dijit 5y agoThe thing about that “snobbery and gate keeping” is that it’s not at all that. Maybe not everyone’s experience mimics mine but I felt like people looked down at me a bit when I was 16 for using nano on the command line. But, and here’s the kicker, if I hadnt been pushed into vim I would not be nearly as productive now. There have been countless times in my career as a sysadmin/devops/SRE where I’ve been stuck with horrible latency to machines half a world away (or, a few miles away but the network is crappy) and being able to send just a few keystrokes and get a lot of power out of it is helpful. That’s not counting all the “repeat” patterns or complex search and replace. I remember still when I got my first job as a junior sysadmin, I spent a really long time logging in to each machine, updating a config file, logging out then going to the next one. I didn’t need to be told that “ssh and nano is fine”, I needed to be told “there are better tools that you should invest in learning, because they will repay you back thousandfold”. What I thought were people looking down on me were in fact people looking at me with hopeless pity, because I fought the idea of learning vim.
- 2muchcoffeeman 5y agoMaybe not everyone’s experience mimics mine but I felt like people looked down at me a bit when I was 16 for using nano on the command line. … What I thought were people looking down on me were in fact people looking at me with hopeless pity, because I fought the idea of learning vim. People need to check how they encourage other people or promote things. You probably weren’t wrong about feeling looked down upon. Even if they really thought you would benefit.
- davmar 5y ago+1 for vim. I also spent a lot of time resisting it. Now it's all I use because it's just so much better.
- crazygringo 5y ago> What I thought were people looking down on me were in fact people looking at me with hopeless pity Or maybe they actually were looking down on you. When we feel bad in response to someone else, we're not usually misinterpreting the emotional cues. It's not just what they say -- it's the way they say it. Which is why the term "constructive criticism" exists. If you want to help them, then make them feel good by expanding their knowledge. But support them in their own choices and autonomy.
- dheera 5y agoIt's not gatekeeping, anyone can use any editor they want, but you bet I will judge your ability to code by your preference of editor, for the simple fact that there are lots of frequent tasks in coding that the basic editors like nano/gedit/Notepad do not provide for. Simple tasks like jumping to line numbers, refactoring and search/replace with regexes, sending the output of a set of lines through a command, syntax highlighting, importing from a file, looking at column numbers, split pane editing, repeating commands, ease of conversion between DOS/UNIX carriage returns, git status, being able to insert 4 spaces when you hit the tab key, being able to adjust the indent level of multiple lines at once, and much more, I expect experienced coders to want at least a large subset of this stuff in their editor. If you say your favorite editor is vim, emacs, sublime, eclipse, VS code, Atom, pycharm, anything along those lines, I'll likely think you're an experienced coder. And if you have an especially strong opinion, I'll consider you even more experienced, even if your strong opinion differs from mine; simply by virtue of having of strong opinion it means you likely have been using it for years and have found other tools inadequate for your skills. If you say your favorite editor is gedit, notepad, or nano, chances are I won't think of you as beyond a beginner-level coder. It means you have zero desire for certain features that are almost necessary to be efficient in large software projects, and signals to me that your skill set is possibly not high enough to have experienced that desire for advanced editor features.
- brazzy 5y ago>And if you have an especially strong opinion, I'll consider you even more experienced, even if your strong opinion differs from mine; simply by virtue of having of strong opinion it means you likely have been using it for years and have found other tools inadequate for your skills. If you really think strength of opinion indicates experience, then clearly you don't have a lot of experience with people...
- techrat 5y ago> It's not gatekeeping, > you bet I will judge your ability to code by your preference of editor, FYI. That's called 'gatekeeping.'
- 5y ago
- swiley 5y agoI'm glad for nano users because the popularity of their editor probably won't ever mean stuff that won't work with mine.
- shapefrog 5y agoI too was bullied from nano onto vi/vim. I still dont think I 'get it' but the brainwashing is complete, I cant even type the word nano into a terminal. I too applaud the author for their bravery in coming out as a proud nano user, not that there is anything wrong with it.
- KronisLV 5y ago> Alas, nano (and pico before it) have a certain stigma among more "experienced" Unix users that more or less boils down to gatekeeping and snobbery. You know, after a number of years in the industry, I've largely stopped caring about what others think and wouldn't lose my sleep over it - the best tools are the ones that you're familiar with and that solve your problems. For me, that's using nano, for someone else that could be vim. I might want to use some of the JetBrains IDEs, use something like Java liberally because of its verbosity and not even scoff at older software like Lazarus/FreePascal in some circumstances (their approach to GUI is still superior to most modern ones). For someone else that could be Visual Studio Code, a language like Python, or generally looking in the direction of the bleeding edge of languages, such as Rust. As long as you reach your goals, i think it's perfectly reasonable to dismiss peer pressure or criticism, unless it's constructive (like the person who suggested that vim is better for replace operations over slow connections, which was a good point but also something I've never needed). That said, the author's approach to customizing nano made me appreciate how nice having proper configuration files and options within them is!
- ineedasername 5y agoWell, I'd put some limits on this. If a coworker cobbled together something that still let them program by punch card then I'd 1) probably be frustrated with their level of output and 2) impressed at the setup. 3) asking for their extra set of eyes on my own code because if they had the patience for punch cards they would probably be better than me at catching errors.
- rascul 5y agoI would probably be wondering where the machine is kept that reads punch cards. And how to use it. And how do I make punch cards. Then, after all that, your list seems like it would suffice.
- ineedasername 5y agowhere the machine is kept that reads punch cards In my mind I envisioned in on their desk in the next office over that looked like something out of the movie "Brazil" and machines on the desks during the Central Services scene [0] [0] https://www.youtube.com/watch?v=V-yXL-LDMyg https://www.youtube.com/watch?v=V-yXL-LDMyg
- mraza007 5y agoThis is my favorite comment. You have stated facts which I totally agree with Learning tools is an investment when you master tools you can achieve so much in short amount of time. If a person knows his tools pretty well he can get work done faster and I have experienced this by learning vim and forcing my self to use it for writing code. It has improved my workflow significantly
- 908B64B197 5y ago> The thesis of this post is roughly that nano, when configured, is enough of an editor for the author. Which is totally fine! People should be happy with their tools and not feel pressured by popularity to use what others use (vim, emacs being prime competitors in this case). My advice to the author would be to give emacs an other shot. It can be configured to behave a lot like nano (and isn't modal), and runs in the terminal. But there's an ecosystem of plugins around it and has a lot of stuff that's built-in. But one day one of the journey it'll behave almost exactly as nano.
- alpaca128 5y agoWhat's the point in making Emacs behave roughly like another editor when you can just use the original? Also, Emacs has about a million lines too much bloat for the target audience of Nano. Which is the one thing you can't fix by adding tons of plugins.