forked from stsquad/emacs_chrome
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathoptions.html
53 lines (51 loc) · 1.91 KB
/
options.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<html>
<head><title>Edit with Emacs</title></head>
<script type="text/javascript" src="options.js"></script>
<body onload="restore_options()">
For Edit with Emacs to work you need to be running an "edit server" on
your local machine. This is because extensions in Chrome(ium) cannot
directly start new programs. For Emacs users it is recommended you use the use supplied native
<a href="servers/edit-server.el">edit-server.el</a>.
<p>
Save the file to somewhere visible to your your Emacs <code>load-path</code> and add the following to your <code>.emacs</code>:
<pre>
(require 'edit-server)
(edit-server-start)
</pre>
If you're already running an instance of Emacs in <code>--daemon</code> mode then you can wrap the code in something like:
<pre>
(if (and (daemonp) (locate-library "edit-server"))
(progn
(require 'edit-server)
(edit-server-start)))
</pre>
To open pages for editing in a new buffer instead of a new frame on
your running Emacs instance do:
<pre>
(if (locate-library "edit-server")
(progn
(require 'edit-server)
(setq edit-server-new-frame nil)
(edit-server-start)))
</pre>
<p>
If for some reason you don't want to use Emacs you have a couple of other options available.
<ul>
<li>
Other servers at the <a href="http://github.com/stsquad/emacs_chrome/tree/master/servers/">project site</a>
</li>
<li><a href="https://chrome.google.com/extensions/detail/ppoadiihggafnhokfkpphojggcdigllp">TextAid</a>'s Edit Server can be found <a href="http://opencoder.net/edit-server">here</a>.
</li>
</ul>
Other edit servers may well exist, please let me know at the project web site.
<p>
<hr>
Edit Server @ 127.0.0.1:
<input id="port" type="text" name="port"><em>default: <code>9292</code></em><br>
<div id="status"></div>
<button onclick="save_options()">Save</button>
<hr>
<button onclick="test_server()">Test Edit Server</button>
<div id="server_status"></div>
</body>
</html>