2013-02-26 11:48:32 -07:00
|
|
|
|
;;; go-mode-load.el --- automatically extracted autoloads
|
2009-10-22 09:54:26 -06:00
|
|
|
|
;;; Commentary:
|
|
|
|
|
|
|
|
|
|
;; To install go-mode, add the following lines to your .emacs file:
|
|
|
|
|
;; (add-to-list 'load-path "PATH CONTAINING go-mode-load.el" t)
|
|
|
|
|
;; (require 'go-mode-load)
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;;
|
2009-10-22 09:54:26 -06:00
|
|
|
|
;; After this, go-mode will be used for files ending in '.go'.
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;;
|
2009-10-22 09:54:26 -06:00
|
|
|
|
;; To compile go-mode from the command line, run the following
|
|
|
|
|
;; emacs -batch -f batch-byte-compile go-mode.el
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;;
|
2009-10-22 09:54:26 -06:00
|
|
|
|
;; See go-mode.el for documentation.
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;;
|
2009-10-22 09:54:26 -06:00
|
|
|
|
;; To update this file, evaluate the following form
|
|
|
|
|
;; (let ((generated-autoload-file buffer-file-name)) (update-file-autoloads "go-mode.el"))
|
|
|
|
|
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;;; Code:
|
|
|
|
|
|
2009-10-22 09:54:26 -06:00
|
|
|
|
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;;;### (autoloads (go-download-play godoc gofmt-before-save go-mode)
|
|
|
|
|
;;;;;; "go-mode" "go-mode.el" (20767 50749))
|
2009-10-22 09:54:26 -06:00
|
|
|
|
;;; Generated autoloads from go-mode.el
|
|
|
|
|
|
2011-03-24 08:35:39 -06:00
|
|
|
|
(autoload 'go-mode "go-mode" "\
|
2009-10-22 09:54:26 -06:00
|
|
|
|
Major mode for editing Go source text.
|
|
|
|
|
|
2013-02-26 11:48:32 -07:00
|
|
|
|
This mode provides (not just) basic editing capabilities for
|
|
|
|
|
working with Go code. It offers almost complete syntax
|
|
|
|
|
highlighting, indentation that is almost identical to gofmt,
|
|
|
|
|
proper parsing of the buffer content to allow features such as
|
|
|
|
|
navigation by function, manipulation of comments or detection of
|
|
|
|
|
strings.
|
|
|
|
|
|
|
|
|
|
Additionally to these core features, it offers various features to
|
|
|
|
|
help with writing Go code. You can directly run buffer content
|
|
|
|
|
through gofmt, read godoc documentation from within Emacs, modify
|
|
|
|
|
and clean up the list of package imports or interact with the
|
|
|
|
|
Playground (uploading and downloading pastes).
|
|
|
|
|
|
|
|
|
|
The following extra functions are defined:
|
|
|
|
|
|
|
|
|
|
- `gofmt'
|
|
|
|
|
- `godoc'
|
|
|
|
|
- `go-import-add'
|
|
|
|
|
- `go-remove-unused-imports'
|
|
|
|
|
- `go-goto-imports'
|
|
|
|
|
- `go-play-buffer' and `go-play-region'
|
|
|
|
|
- `go-download-play'
|
|
|
|
|
|
|
|
|
|
If you want to automatically run `gofmt' before saving a file,
|
|
|
|
|
add the following hook to your emacs configuration:
|
|
|
|
|
|
|
|
|
|
\(add-hook 'before-save-hook 'gofmt-before-save)
|
|
|
|
|
|
|
|
|
|
If you're looking for even more integration with Go, namely
|
|
|
|
|
on-the-fly syntax checking, auto-completion and snippets, it is
|
|
|
|
|
recommended to look at goflymake
|
|
|
|
|
\(https://github.com/dougm/goflymake), gocode
|
|
|
|
|
\(https://github.com/nsf/gocode) and yasnippet-go
|
|
|
|
|
\(https://github.com/dominikh/yasnippet-go)
|
2009-10-22 09:54:26 -06:00
|
|
|
|
|
|
|
|
|
\(fn)" t nil)
|
|
|
|
|
|
2013-02-26 11:48:32 -07:00
|
|
|
|
(add-to-list 'auto-mode-alist (cons "\\.go\\'" 'go-mode))
|
2011-03-24 08:35:39 -06:00
|
|
|
|
|
|
|
|
|
(autoload 'gofmt-before-save "go-mode" "\
|
|
|
|
|
Add this to .emacs to run gofmt on the current buffer when saving:
|
2013-02-26 11:48:32 -07:00
|
|
|
|
(add-hook 'before-save-hook 'gofmt-before-save).
|
|
|
|
|
|
|
|
|
|
Note that this will cause go-mode to get loaded the first time
|
|
|
|
|
you save any file, kind of defeating the point of autoloading.
|
2011-03-24 08:35:39 -06:00
|
|
|
|
|
|
|
|
|
\(fn)" t nil)
|
2009-10-22 09:54:26 -06:00
|
|
|
|
|
2013-02-26 11:48:32 -07:00
|
|
|
|
(autoload 'godoc "go-mode" "\
|
|
|
|
|
Show go documentation for a query, much like M-x man.
|
|
|
|
|
|
|
|
|
|
\(fn QUERY)" t nil)
|
2009-10-22 09:54:26 -06:00
|
|
|
|
|
2013-02-26 11:48:32 -07:00
|
|
|
|
(autoload 'go-download-play "go-mode" "\
|
|
|
|
|
Downloads a paste from the playground and inserts it in a Go
|
|
|
|
|
buffer. Tries to look for a URL at point.
|
|
|
|
|
|
|
|
|
|
\(fn URL)" t nil)
|
|
|
|
|
|
|
|
|
|
;;;***
|
|
|
|
|
|
2009-10-22 09:54:26 -06:00
|
|
|
|
(provide 'go-mode-load)
|
2013-02-26 11:48:32 -07:00
|
|
|
|
;; Local Variables:
|
|
|
|
|
;; version-control: never
|
|
|
|
|
;; no-byte-compile: t
|
|
|
|
|
;; no-update-autoloads: t
|
|
|
|
|
;; coding: utf-8
|
|
|
|
|
;; End:
|
|
|
|
|
;;; go-mode-load.el ends here
|