diff options
author | jao <jao@gnu.org> | 2021-09-02 00:48:56 +0100 |
---|---|---|
committer | jao <jao@gnu.org> | 2021-09-02 00:48:56 +0100 |
commit | 7babc823092f8d6dcf45f147b3457c5f770af527 (patch) | |
tree | 0106edc36157714e30b4a21c11a592f6a58a8163 | |
parent | e2f71dd9a2a7fd503cba706278715dceeabb6670 (diff) | |
download | elibs-7babc823092f8d6dcf45f147b3457c5f770af527.tar.gz elibs-7babc823092f8d6dcf45f147b3457c5f770af527.tar.bz2 |
jenkins: refresh console output, brittlely
-rw-r--r-- | init.org | 13 |
1 files changed, 11 insertions, 2 deletions
@@ -2066,12 +2066,21 @@ ;; optionally: jenkins-colwidth-id, jenkins-colwidth-last-status (setq jenkins-colwidth-name 35) :config - (defun jao-jenkins-first-job () + (defun jao-jenkins-first-job (&rest _) (interactive) (goto-char (point-min)) (when (re-search-forward "^- Job" nil t) (goto-char (match-beginning 0)))) (add-hook 'jenkins-job-view-mode-hook #'jao-jenkins-first-job) + (advice-add 'jenkins-job-render :after #'jao-jenkins-first-job) + + (defun jenkins-refresh-console-output () + (interactive) + (let ((n (buffer-name))) + (when (string-match "\\*jenkins-console-\\([^-]+\\)-\\(.+\\)\\*$" n) + (jenkins-get-console-output (match-string 1 n) (match-string 2 n)) + (goto-char (point-max))))) + :bind (:map jenkins-job-view-mode-map (("n" . next-line) ("p" . previous-line) @@ -2080,7 +2089,7 @@ :map jenkins-console-output-mode-map (("n" . next-line) ("p" . previous-line) - ("g" . jenkins--refresh-console-output)))) + ("g" . jenkins-refresh-console-output)))) #+END_SRC * Programming *** Automatic modes |