[ prog / sol / mona ]

prog


Regarding Emacs

1 2022-06-17 11:11

I am a vim user but Emacs users can convinced me that I am seriously missing out by now using Emacs. I have used Emacs for small periods of time in the past but I have always hated it. I currently use nnn to traverse directories and vim to edit the files. Will using Emacs improve my productivity in any way?
Also I see a lot of big names supposedly using Emacs or a modified version of it. That also pulls me towards Emacs.

2 2022-06-17 11:12

I am a vim user but Emacs users can convinced me

have*

3 2022-06-17 13:05

Subscribed to the thread.

4 2022-06-17 13:10

vim

Emacs

nnn

These are all bloated and non-standard tools. Stick to the standard tools such as ed, vi, cd, and ls.

5 2022-06-17 14:31

>>4
Computer is bloated and non-standard. Stick to standard tools such as paper, pen stylus, papyrus, etc.

6 2022-06-17 14:35

I'm just like you OP. Well, "today I learned" that I can put file tree to the left, file opened on the right and interactive shell enabled at the bottom (e.g. to run git commands). It all creates quite comfy IDE, however, I still lack browser-like tabs of of opened files. Maybe, Emacs can supply with that, too, who knows?

7 2022-06-17 15:10 *

>>6
https://www.gnu.org/software/emacs/manual/html_node/emacs/Tab-Line.html -- for switching between buffers
https://www.gnu.org/software/emacs/manual/html_node/emacs/Tab-Bars.html -- for switching between window layouts

I don't get the appeal of tabs. When I want to switch to buffer `xyz' I think "man I should switch to buffer `xyz'" and simultaneously press =C-x b= and start typing in `xyz' to which the completion system helpfully fills in the rest for me. This is a direct translation of my thoughts, unlike with tabs where you have to find the correct tab and it gets crowded and by the time you find it you forget what you wanted from that buffer anyway. Maybe the tab bar makes more sense, I do something like that with multiple frames using emacsclient, but even for that I see no point in the visuals.

8 2022-06-17 15:21 *

The file tree is another thing I can't understand, sometimes when I help coworkers with their issues they will have their super-modern IDE open and I tell them to take a look at `foobar.c' or whatever concrete file and they will start browsing that tiny list with those little icons. Come on man, I told you its name, just type it in! If I want to look at files I have dired, which is a first-class solution and the focus of my attention, I don't need some tiny crippled list sitting on the side all day doing nothing most of the time but when it does its job it does it badly.

9 2022-06-17 16:10

>>6

I still lack browser-like tabs of of opened files

You can click on tabs with gvim.

10 2022-06-17 16:19

>>8

Well, I can reply on your question. The tree is needed for quick overview of all files for example, when you are browsing a new project. However, my concern is not about the tree structure, but rather about how to remove meta info about files like ownership. Is there any way without plugins?

11 2022-06-17 16:38

>>10
What mode are you using? You can do an M-x customize-group, type in the mode name, and it should give you the settings. If you are using dired, there's a dired-hide-details-mode that changes it so only the names are shown.

12 2022-06-17 16:54

>>11

I was in Dired and your second advice worked for me, thanks.

BTW, how to switch back?

------
I'm editing some stylesheets and Emacs is displaying color hexes as their background color right in the code. That's insane and very helpful. I'm starting understand why people like it.

13 2022-06-17 17:11

>>12
You can read its documentation by pressing C-h f and typing in its name.

14 2022-06-17 20:30

Emacs can display inline images.

15 2022-06-18 10:01

>>13

Thanks, I've read the tutorial, it's educational.

Can anyone say what Doom Emacs add-on actually adds except for "modern" design?

My second concern is that GNU Emacs doesn't recognize quite popular languages/scripts and markdowns (I noticed so far MarkDown, Rust, Golang, PHP). There're probably plugins for those, right?

16 2022-06-18 10:31

>>15
I never used Doom Emacs, but isn't it based on vim keybindings?

Emacs has a package manager: https://www.gnu.org/software/emacs/manual/html_node/emacs/Packages.html

The popular repositories for it are:
https://elpa.gnu.org/
https://elpa.nongnu.org/
https://melpa.org/#/

17 2022-06-18 13:02

>>16

isn't it based on vim keybindings

Dunno, its README doesn't say much on this, instead gives a fancy design screenshot. I actually like classic Emacs, it's more solid.

Anyway, I'm fine with Emacs keybindings, they are fitting GUI text editor.

18 2022-06-19 08:27

> 8

`cd` ing around or clicking around those file-tree sidebars is to me the sign of a mediocre programmer.

I once worked with a guy that would manually `cd` into the directory with the file, open the file with `vim`, edit, close, and the `cd` back out. Just this incessant changing of directories accounted for, I'd say, 20-30% of all his keystrokes while at work. Incredibly painful to witness. Yeah, and he was a very mediocre programmer.r

19 2022-06-19 08:31

>>18

I once worked with a guy that would manually `cd` into the directory with the file, open the file with `vim`, edit, close, and the `cd` back out.

What should he do instead? Vim onto absolute path of the file?

20 2022-06-19 09:38 *

You can use cd - to quickly switch between the current and last directories.

21 2022-06-19 10:34

>>20

But you don't need pleb cd navigation if you can use pushd, popd, and dirs.

22 2022-06-20 02:57

>>21

pushd

popd

dirs

These are all non-standard tools. Stick to POSIX sh.

23 2022-06-20 06:11

OP here using Emacs rn
I love it! I just converted all my spreadsheets to org-mode tables. Im also the guy who was asking for a libreoffice calc alternative.

24 2022-06-20 20:52

I like how I can open guide webpage on the left, write code on the right and evaluate it on the go with C-x C-e to output at the bottom. I don't need to switch between browser and terminal and IDE, which is so annoying especially when I have a lot of windows opened.

I am glad I started learning Emacs, it makes my life easier.

25 2022-06-21 00:00

>>24
Vim can do the same without consuming all your RAM.

26 2022-06-21 09:12

>>25

Vim can do the same

Without 1 trillion unmaintained buggy plugins installed? I don't think so.

I regularly use Vim when there's no X11 or Wayland environment i.e. on servers, but that's the only thing what Vim is good or maybe even best for. Trying to hack it into full-scale IDE is actually breaking Unix philosophy do one thing and do it well.

without consuming all your RAM

Emacs hardly can consume all my 32GiB of RAM. I usually have around 5 workplaces opened with two or more windows in each including fat FF, Thunderbird, Element, etc. and I didn't notice any downgrade in performance since I started using Emacs instead of the other GUI code editor.

27 2022-06-24 19:10 *

>>1
If you like nnn, dired should suit you just fine. The keybindings are easy to change.

(define-key dired-mode-map "j" 'dired-next-line)
(define-key dired-mode-map "k" 'dired-previous-line)
(define-key dired-mode-map "c" 'dired-copy-file)

28


VIP:

do not edit these