Skip to content

xuchunyang/another-emacs-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

An Emacs server built on HTTP and JSON

The builtin Emacs server is built on Unix domain socket, another-emacs-server is builton HTTP and JSON. Because the response is JSON, it's easy and reliable for other tool to consume.

Usage

Run M-x another-emacs-server to start the server. Send

  • {"eval": "expr"} to eval an expression
  • {"file": ["filename1", "filename2", ...]} to open files

For example,

~ $ curl -s -d '{"eval": "emacs-version"}' -H "Content-Type: application/json" localhost:7777 | jq
{
  "result": "27.0.90"
}

~ $ curl -s -d '{"file": ["/etc/hosts"]}' -H "Content-Type: application/json" localhost:7777 | jq
{
  "result": "OK"
}

Requires

  • Emacs 25.1
  • web-server 20200312

About

An Emacs server built on HTTP and JSON

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published