aboutsummaryrefslogtreecommitdiff
path: root/emacs
diff options
context:
space:
mode:
Diffstat (limited to 'emacs')
-rw-r--r--emacs/.emacs.d/lisp/my/my-dired.el2
-rw-r--r--emacs/.emacs.d/lisp/my/my-gitlab.el7
2 files changed, 5 insertions, 4 deletions
diff --git a/emacs/.emacs.d/lisp/my/my-dired.el b/emacs/.emacs.d/lisp/my/my-dired.el
index ee6f7b0..83607ab 100644
--- a/emacs/.emacs.d/lisp/my/my-dired.el
+++ b/emacs/.emacs.d/lisp/my/my-dired.el
@@ -183,7 +183,7 @@ Format: yyyymmdd_hhmmss[_N].ext"
(defun my-dired-do-rename-by-mtime ()
"Generates new file name based on mtime.
-Format: yyyymmdd_hhmmss.ext"
+Format: yyyymmdd_hhmmss_[N].ext"
(interactive)
(seq-do
'my-dired-rename-by-mtime
diff --git a/emacs/.emacs.d/lisp/my/my-gitlab.el b/emacs/.emacs.d/lisp/my/my-gitlab.el
index a25533f..6dd484c 100644
--- a/emacs/.emacs.d/lisp/my/my-gitlab.el
+++ b/emacs/.emacs.d/lisp/my/my-gitlab.el
@@ -30,9 +30,10 @@
(defun my-get-gitlab-project-id (url)
(with-current-buffer (url-retrieve-synchronously
(replace-regexp-in-string "\\.git$" "" url))
- (goto-char (point-min))
- (when (re-search-forward "Project ID: \\([0-9]+\\)" nil t)
- (match-string 1))))
+ (let ((dom (libxml-parse-html-region (point-min) (point-max))))
+ (dom-attr (car
+ (dom-search dom (lambda (n) (dom-attr n 'data-project-id))))
+ 'data-project-id))))
(defun my-grok-gitlab (url)
(when-let* ((urlobj (url-generic-parse-url url))