Allow autoload. Move cursor to the beginning of buffer.
--- a/spring-actuator.el Sun Feb 19 14:38:21 2017 +0200
+++ b/spring-actuator.el Sun Feb 19 14:44:26 2017 +0200
@@ -6,6 +6,7 @@
'("actuator" "auditevents" "autoconfig" "beans" "configprops" "dump" "env" "flyway" "health" "heapdump"
"info" "jolokia" "liquibase" "logfile" "loggers" "mappings" "metrics" "shutdown" "trace")))
+;;;###autoload
(defun my/spring-actuator (server path)
(interactive (list (read-string "Server: " my/spring-actuator-last-server 'my/spring-actuator-server-history)
(completing-read "Path: " my/spring-actuator-path-completion nil nil "" 'my/spring-actuator-path-history)))
@@ -20,4 +21,5 @@
(forward-char)
(delete-region (point-min) (point))
(json-pretty-print-buffer)
+ (goto-char (point-min))
(json-mode) ))