Skip to content

brantou/go-imenu.el

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

go-imenu.el

https://img.shields.io/badge/license-GPL_v3-green.svg https://melpa.org/packages/go-imenu-badge.svg https://stable.melpa.org/packages/go-imenu-badge.svg

Introduction

Imenu for go language!

go-mode.el use elisp, base regex.

go-imenu.el use go, base go’s package(ast/parse/token/format).

If you want to know more details, please click on the link above.
I think go's package is simpler, faster, and more accurate than elisp's regular expression.

Dependency

go get -u github.com/lukehoban/go-outline

Installation

Available on all major package.el community maintained repos - MELPA Stable and MELPA repos.

MELPA Stable is recommended as it has the latest stable version. MELPA has a development snapshot for users who don’t mind breakage but don’t want to run from a git checkout.

You can install go-imenu using the following command:

M-x package-install [RET] go-imenu [RET]

or if you’d rather keep it in your dotfiles:

(unless (package-installed-p 'go-imenu)
  (package-refresh-contents)
  (package-install 'go-imenu))

If the installation doesn’t work try refreshing the package list:

M-x package-refresh-contents

Setup

Call go-imenu-setup function at go-mode-hook

(require 'go-imenu) ;; Don't need to require, if you install by package.el
(add-hook 'go-mode-hook 'go-imenu-setup)