News for hackers. Stuff that matters.
Re:Ask HN: Programs that saved you 100 hours? by wwweston on Sunday April 12, 2020 @10:13PM (#22852506)
Anyone know what the best way to set up Emacs on macOS is?
Re:Ask HN: Programs that saved you 100 hours? by dnhz on Monday April 13, 2020 @12:37AM (#22853219)
I just use this version. https://emacsformacosx.com/ I have a one line shell script that then lets me start Emacs from the cmd line. something like

    open -A [path to applications/emacs startup] $@
This supports emacs —daemon
Re:Ask HN: Programs that saved you 100 hours? by m463 on Monday April 13, 2020 @07:43AM (#22854936)
That is what I use.

Additionally in my .bashrc I have:

  EMACS="/Applications/Emacs.app/Contents/MacOS/Emacs"
  EMACSPOS="-g 140x66+655+23 --fullheight"
  e() { ( $EMACS $EMACSPOS "$@" & ) }
I also have it in the dock, but sometimes environment variables are not set up properly.

For this case, I create a plist file ~/.MacOSX/environment.plist and can add stuff to it like this:

    add_plist PATH "$PATH"
where:

  add_plist () {
    /usr/libexec/PlistBuddy -c 'Delete :'"$1" ~/.MacOSX/environment.plist >/dev/null
    /usr/libexec/PlistBuddy -c 'Add :'"$1"' string "'"$2"'"' ~/.MacOSX/environment.plist >/dev/null
  }
Re:Ask HN: Programs that saved you 100 hours? by dnhz on Monday April 13, 2020 @09:29AM (#22855641)
I wrote the last reply from my phone. The command is simply

/Applications/Emacs.app/Contents/MacOS/Emacs “$@“

The script goes into /usr/local/bin or wherever that’s in your path.

Re:Ask HN: Programs that saved you 100 hours? by Arubis on Sunday April 12, 2020 @10:27PM (#22852595)
Best is subjective, but my current go-to is:

```

$ brew tap d12frosted/emacs-plus

$ brew install emacs-plus [options]

```

Cf. https://github.com/d12frosted/homebrew-emacs-plus

Re:Ask HN: Programs that saved you 100 hours? by chiefsucker on Monday April 13, 2020 @01:29AM (#22853419)
I use the “Emacs Mac Port” which is available via Homebrew.

https://github.com/railwaycat/homebrew-emacsmacport

Re:Ask HN: Programs that saved you 100 hours? by ddavis on Sunday April 12, 2020 @11:53PM (#22853038)
I keep a clone of the main GNU Emacs git repository and build the emacs-27 branch (27 is the upcoming release) every few days on my MacBook (and the master branch on my Linux workstation).