Code Monkey home page Code Monkey logo

ace-link's Introduction

ace-link

GNU Emacs package for selecting a link to jump to

What and why

Currently, to jump to a link in an Info-mode or help-mode or woman-mode or org-mode or eww-mode or compilation-mode or goto-address-mode buffer, you can tab through the links to select the one you want. This is an O(N) operation, where the N is the amount of links. This package turns this into an O(1) operation, or at least O(log(N)) if you manage to squeeze thousands of links in one screen. It does so by assigning a letter to each link using avy.

Install

Either clone from here or install from MELPA (recommended).

Setup

Put this in your ~/.emacs:

(ace-link-setup-default)

This will bind o to:

  • ace-link-info in Info-mode
  • ace-link-help in help-mode
  • ace-link-woman in woman-mode
  • ace-link-eww in eww-mode
  • ace-link-compilation in compilation-mode
  • ace-link-custom in custom-mode-map

This shortcut is usually unbound and is very close to l which is the default shortcut to go back.

To bind ace-link-org, you can use something like this:

(define-key org-mode-map (kbd "M-o") 'ace-link-org)

To bind ace-link-gnus, you can use something like this:

(define-key gnus-summary-mode-map (kbd "M-o") 'ace-link-gnus)
(define-key gnus-article-mode-map (kbd "M-o") 'ace-link-gnus)

If you use ert, ace-link-help also works on ert results:

(require 'ert)
(define-key ert-results-mode-map "o" 'ace-link-help)

To bind 'ace-link-addr' in all modes (useful when using goto-address-mode or goto-address-prog-mode):

(global-set-key (kbd "M-o") 'ace-link-addr)

Usage

Just press o when you're in Info-mode or help-mode or woman-mode or eww-mode or compilation-mode.

Here's a screencast of browsing Info using ace-link-info:

gif

ace-link's People

Contributors

abo-abo avatar cute-jumper avatar dakra avatar damiencassou avatar djr7c4 avatar edvorg avatar fice-t avatar gilbertw1 avatar illikainen avatar jockej avatar joncol avatar kyleam avatar littlevalley avatar madand avatar marcowahl avatar marsam avatar mosic avatar papercatlol avatar whatacold avatar whilp avatar yuhan0 avatar yunhao94 avatar zaeph avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.