diff options
| author | Alex Kost <alezost@gmail.com> | 2018-07-22 00:15:59 +0300 |
|---|---|---|
| committer | Alex Kost <alezost@gmail.com> | 2018-07-27 12:14:24 +0300 |
| commit | 5dd520820d7a9bf6d7b2a55bb9e7cc2ec53deeb5 (patch) | |
| tree | 77819dbdcec4e51f3e448b704ff265d05424dac3 /build-farm.el | |
| parent | Add project button (diff) | |
| download | emacs-build-farm-5dd520820d7a9bf6d7b2a55bb9e7cc2ec53deeb5.tar.gz | |
Add jobset button
* build-farm.el (build-farm-info-jobset): Inherit from 'link' face.
(build-farm-jobset): New button type.
(build-farm-info-insert-jobset): New procedure.
* build-farm-build.el (build-farm-build-info-insert-jobset): Use it.
* build-farm-project.el (build-farm-project-info-insert-jobset): Use it.
Diffstat (limited to 'build-farm.el')
| -rw-r--r-- | build-farm.el | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/build-farm.el b/build-farm.el index 9ab8200..4c72512 100644 --- a/build-farm.el +++ b/build-farm.el @@ -70,7 +70,7 @@ :group 'build-farm-faces) (defface build-farm-info-jobset - '((t)) + '((t :inherit link)) "Face for jobsets in 'info' buffers." :group 'build-farm-faces) @@ -102,6 +102,20 @@ 'help-echo "Display project info" 'action 'build-farm-project-button-action) +(define-button-type 'build-farm-jobset + :supertype 'bui-url + 'face 'build-farm-info-jobset) + +(defun build-farm-info-insert-jobset (project jobset) + "Insert info about JOBSET of the PROJECT at point." + (let ((url (build-farm-jobset-url + :root-url (build-farm-current-url) + :project project + :jobset jobset))) + (bui-insert-button jobset 'build-farm-jobset + 'url url + 'help-echo (format "Browse %s" url)))) + ;;; System types |
