Hacker News new | past | comments | ask | show | jobs | submit login

After seven years of not working with Emacs, a few weeks ago I gave it a try. I was negative, biased and convinced that it would just be a distraction, a time waster. But the more I dived into it, I realized that the Emacs that I worked with in 2010-2013 was not the same anymore. Packages like `dash.el' or `s.el' make programming in Elisp fun! Then there are beautiful themes like `spacemacs'. Also packages for managing notes and files (`Deft' for instance).

Within a few days I migrated all my note-taking and task-managfement-systems to Emacs. Previously I was using Evernote, Bear app, Ulysses app for note taking and TaskPaper + OmniFocus for project management.

Emacs + Org-Mode replaced all those apps and many more. And it makes me `dance' with my data by using Elisp to transform all my data into ways I need and want.

I realized that I didn't use Emacs to its full potential in 2013 because I was reluctant to dive into (E)Lisp. This time I made a full dive into it. And I am absolutely loving it. I had some contanct with Scheme some twenty years ago, and that influenced me very much. But CL and Elisp offer much more.

Emacs does not need to be an IDE, but it can be a decent one. (Yes, I know and use intelliJ: PyCharm and PHPStorm). It can be used for everything text: Note taking, programming, transforming text. But via org-mode for much more than text: Project- and task-management, ascii-tables, note-management system. I even initiate my Google searches from within Emacs and keep a track of my searches via org-capture.

Thank you for all the maintainers!



- I am a user of a Mac with a US keyboard. Using an app named "Karabiner Elements" to remap my keys. I have my caps and enter key behave like a Control key whenever I hit them in combo with other keys. That way I have two control keys in reach of both my pinkies.

- r/emacs and r/orgmode are super helpful communities

- learn to program in Lisp and have a look at Lisp macros. That's a very useful concept to write DSLs to transform code very easily. - scratch buffer is your friend in learning elisp. Place the cursor after the last colon of your code and hit `C-x C-e`, that will evaluate that line.

- Learn about debugging your Elisp code. Edebug (`edebug-defun`) is your friend. See http://blog.binchen.org/posts/my-work-flow-to-debug-emacs-pl...

- Be patient. Once you have mastered the basics, you'll fly!

wow, it's like I could have written this comment!

I'm starting a new project this week, and a fresh, empty org-roam database in my Spacemacs instance is really nice. I'm filing all these links and little org documents with references to each other and documenting my learning as I go. I'm also using Karabiner, Spacemacs, Org-Mode, etc etc. The Emacs subreddit is consistently one of the most helpful out there, it's fantastic.

(I used a new, clean org-roam database in an empty ~/Org folder because I wanted to leave behind all the cruft and stuff from the previous project, including potentially client-specific stuff.)

(ooh, ooh, I forgot: Emacs and org-mode are 2 things I donate to monthly. Emacs via $10 to the FSF, and org-mode via $5 via Github direct to the maintainer.)

Thanks for the tip re donation!

Edit: Re "I used a new, clean org-roam database in an empty ~/Org folder because I wanted to leave behind all the cruft and stuff from the previous project, including potentially"

Exactly what I did and what gave me a boost in learning Emacs+Elisp and a fresh start. My old `.emacs' file was holding me back!

I wonder if I should do that. I'm deep into Spacemacs and wonder if I should go for a clean Emacs approach rather than the Vim bindings.

I abandoned vim bindings (evil-mode). There were too many edge cases where it didn't work, and where I had to customize it to make it work.

With a good keyboard setup (two Control keys on the left and right) Emacs keybindings aren't that bad. Actually I like them.

Wow, thank you for introducing me to `dash.el` and `s.el`. I tried to learn Elisp a year back and was frustrating by the lack of basic functional facilities that I'm used to in my primary language (Elixir).

How do you recommend diving deeper? I feel like there is so much to Emacs that would make me much more productive, but I'm apprehensive to dive below the surface

Elixir is a beautiful language. I love the pipe operator and the elegance of the language. Much more consistent than the language I use daily (Python). Also: Coming to Python from Scheme I was missing the difference between destructive vs non-destructive operators [^1]. In Python I'd use `my_list.sort()'. That does not return the sorted list but `None', whereas `sorted(my_list)' returns a sorted copy of `my_list'. That's why I can't use method chaining in Python like this: `my_list.sort().first().to_str()'.

Re diving in Lisp:

1. I deleted my previous `.emacs` file and started from scratch.

2. I learned all about the internal help system of Emacs. `C-h f' will let me look up help for a function (it's "docstring"), `C-h v' will let me look up a variable, etc. - Navigating help via `C-h i' and then 'm' (for menu) will let me search the TOC entries in the help page. `l' (lower L) will let me go back in help.

3. Read good old recommended Lisp books. Seibel and many more are the classics.

4. Write code! Practical code that you need. Solve problems. Think of use-cases. - For instance, I needed to parse my Kindle annotations, which are saved like a log file in a file on the Kindle itself (the file is named `My Clippings.txt'. I had written a parser in Python to get the entries out of the file, now I did it in Elisp. Or you need a convenience function that performs several steps you need daily in your text-editing or org-files (creating template files, navigating the headars, whatnot).

5. Read the source code of the packages. They have wonderful examples for how to write code in Elisp. For instance `org-table.el'. It gave me many ideas for how to write idiomatic Elisp. - You can go to the source code of a package by looking up a function you use (`C-h f org-table-create RET', then click the hyperlinked package name `org-table.el'; that'll bring you right to the function in the package).

6. Read good code. For instance: Magnar Sveen. He has written many excellent packages. `dash.el' and `s.el' and some more. Check his github, read the code, and check his http://emacsrocks.com/ videos.


[^1]: "The names of procedures and syntactic forms that cause side effects end with an exclamation point ( ! ).". Source: https://www.scheme.com/tspl2d/intro.html

I'd very much recommend against using packages like dash and s. Most of dash can either be done with cl-lib or seq, and s are basically just wrapper functions. Both introduce bad style (look more like Clojure than Elisp) and promote inefficient (often functional) patterns.

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