• Stars
    star
    497
  • Rank 88,652 (Top 2 %)
  • Language
    JavaScript
  • License
    GNU General Publi...
  • Created almost 15 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A Chromium "clone" of It's All Text for spawning an editor to edit text areas in browsers. Based on David Hilley's original Chromium extension.

Build Status MELPA MELPA Stable Webstore

About

Edit with Emacs is an addon for webextension compatible browsers like Google's Chrome(ium), Opera or Firefox that allows you to edit text areas on your browser in a more full featured editor. It does this in conjunction with an "Edit Server" which services requests by the browser. This is because extensions cannot spawn new processes as a security measure.

The extension packages a native elisp version that can be downloaded, just follow the instructions from the options page of the extension. It has been known to work with GNU Emacs and Aquamacs (MacOS); it is presently not compatible with XEmacs.

Other example edit servers can be found at the project homepage. There is no reason why other server scripts could not spawn other editors and currently a number of servers support the simple URL based protocol.

This extension is licensed under the GPL v3 and development versions can be found at: http://github.com/stsquad/emacs_chrome

Installing

As mentioned above there are two parts you will need. The edit server which needs to be installed and configured on Emacs and the browser extension itself.

Edit Server

Perhaps the easiest way to install edit-server.el is via MELPA which provides a range of packages that can be installed via the package manager:

M-x package-install edit-server

Once installed you will want to update your configuration so the server is started before you edit. For example using the popular use-package config framework you might do something like this:

(use-package edit-server
  :ensure t
  :commands edit-server-start
  :init (if after-init-time
              (edit-server-start)
            (add-hook 'after-init-hook
                      #'(lambda() (edit-server-start))))
  :config (setq edit-server-new-frame-alist
                '((name . "Edit with Emacs FRAME")
                  (top . 200)
                  (left . 200)
                  (width . 80)
                  (height . 25)
                  (minibuffer . t)
                  (menu-bar-lines . t)
                  (window-system . x))))

Please see the built-in help for more information on how to configure the edit servers behaviour.

Browser Extension

If you just want to install Edit with Emacs you can simply visit the Chrome Store at:

https://chrome.google.com/webstore/detail/edit-with-emacs/ljobjlafonikaiipfkggjbhkghgicgoh

Or if you're using Firefox, visit addons.mozilla.org (AMO) at:

https://addons.mozilla.org/en-US/firefox/addon/edit-with-emacs1/

You then have the option of installing the packaged edit-server from the options page or alternatively you can install the latest version from MELPA if you have it enabled in Emacs 24+.

If you would like to help with the development of Edit with Emacs the easiest way is to fork the github repository (https://github.com/stsquad/emacs_chrome) and clone it to your development system. Then in Chrome(ium) go to:

Tools->Extensions Select "Developer Mode" Click "Load Unpacked Extension"

and point it at the cloned repository.

Hacking

This modeline should be used in every source file to keep indentation consistent:

// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-

This tells both emacs use spaces instead of tabs and use a basic indentation of 4 spaces.

There is also a universal .editorconfig which should enforce this.

The code has a fair amount of whitespace damage. Please don't submit mega-patches to clean it up, just fixup the local code as you go. It makes history harder to navigate as well as potentially introducing changes in the noise.

There is currently a minimal Travis-CI control file which essentially ensures the edit-server.el still compiles. Additions to the test coverage are always welcome. ;-)

Submitting to Store

  • Update NEWS
  • Test
  • Tag vX.Y
  • git archive --format zip --output emacs_chrome_X.Y.zip vX.Y
  • Upload that

History

Dave Hilley wrote the original proof of concept that showed it could be done. I then hacked around with the Javascript to make the behaviour more like the classic It's All Text add-on available to Firefox.

Authors

Edit with Emacs is open source and is brought to you thanks to contributions from the following people:

David Hilley Alex Bennée Riccardo Murri Niels Giesen Wei Hu Ævar Arnfjörð Bjarmason Chris Houser Robert Goldman Phil Pennock Sudish Joseph IRIE Shinsuke Nelson Elhage David J. Biesack Christopher Browne Mark Shroyer Remco van 't Veer John Croisant Tim Cuthbertson Ryszard Szopa Kazuya Sakakihara Steve Purcell Dale Sedivec Jonas Bernoulli Le Wang Mike Shulman Matt Walker Aaron Schrab Adam Spiers Dato Simó Philippe Vaucher Eli Barzilay Marc Tamsky Attila Lendvai Daniel Kraus John Brzustowski

Other Code

This extensions takes advantage of the jQuery library to do a lot of the heavy lifting in searching the page for elements.

It uses John Resig's jQuery Colour Animation plug-in to do the colour fades of the elements.

The settings code uses Frank Kohlhepp's excellent fancy-settings library. This has since been pulled from the web.

The textarea code uses the rather nifty mutation summary library by Google.

More Repositories

1

dired-rsync

Support for rsync from Emacs dired buffers
Emacs Lisp
101
star
2

emacs-chromebooks

Some integrations for running a crouton powered emacs session on your Chromebook
Emacs Lisp
44
star
3

mpeg4ip

Git clone of the CVS repo of a now un-maintained project
C++
38
star
4

my-emacs-stuff

My .emacs and various support bits and pieces
Emacs Lisp
38
star
5

easytag

A git repo of the development series of EasyTag (as there was no official SCM). Since then the project has moved and is hosted at Gnome in it's own upstream repo.
C
28
star
6

dotfiles

A collection of .bashrc stuff and other dotfiles
Shell
18
star
7

emacs-mark-tools

A simple library for navigating the global and local mark rings in Emacs
Emacs Lisp
11
star
8

ps3enc

A bunch of scripts for handling media in a PS3/PS4 compatible way.
Python
8
star
9

rockbox

A git-svn repository tracking rockbox and whatever local changes I'm hacking with at the time
C
7
star
10

Gwibber

My hacks on the Gwibber Microblogging Client. Follows a few of the official branches
Python
6
star
11

async-org-babel

Emacs extension for executing org-babel blocks asynchronusly
Emacs Lisp
5
star
12

checkpatch-mode

A simple mode for running checkpatch scripts.
Emacs Lisp
5
star
13

scripts

A random collection of scripts to do a random collection of things.
Python
5
star
14

parsecvs

A hacked up copy of Kieth Packards parsecvs which contains mainly fprintfs and a few patches that fix things I ran into on the uber repo I was converting at work
C
5
star
15

stonx

A GIT conversion of the Sourceforge STonX repo.
C
3
star
16

same-diff-colour-test

A VisionEgg python script which is used for measuring colour sensitivity. This version hacked to use VISAGE
Python
3
star
17

retry

A wrapper for retrying failing functions, originally for running rsync on dodgy links
Python
3
star
18

openlayers-cbnl

Lightly patched Debian packge of OpenLayers
JavaScript
3
star
19

risu

My copy of Pete Maydell's risu code generator/tester (see git://git.linaro.org/people/pmaydell/risu.git)
Perl
3
star
20

qemu-mode

A modern comint based mode for running qemu
Emacs Lisp
3
star
21

curator

A meta-album curator
Python
3
star
22

Gentoo-Overlay

My Gentoo Overlay. Usually contains whatever ebuilds I'm currently hacking about with
Shell
2
star
23

testcases

A bunch of random testcases for various things
C
2
star
24

events-manager

My local hacks to Davide Benini's events manager to support RSVP codes and wedding type organisation
PHP
2
star
25

Personal-Weblog-to-Wordpress

A simple script to migrate data from Personal Weblog into Wordpress
1
star
26

jicmp

A working copy of the OpenNMS jicmp library
Java
1
star
27

find_text

A simple text finding utility for recovering text files from file-system dumps
Python
1
star
28

mydialler

A fork of NubDial/SpellDial for my own experimental hacking
Java
1
star
29

qemu-jeos

This is a simple build system that builds a super small environment that can be used within qemu-test.
1
star
30

dbgsym

A simple script to check the integrity of debug symbols on a system
Python
1
star
31

opengl-demo

Experimenting with Python and OpenGL
Python
1
star
32

cv

A copy of my current CV in org-mode form
Makefile
1
star