[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/git-commit a6f9c78374 11/15: Use seq-take and seq-drop ins
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/git-commit a6f9c78374 11/15: Use seq-take and seq-drop instead of -split-at |
Date: |
Mon, 31 Jul 2023 10:00:21 -0400 (EDT) |
branch: elpa/git-commit
commit a6f9c783748d2908160d313f6d12a8cf0bb2c59f
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>
Use seq-take and seq-drop instead of -split-at
---
lisp/magit-process.el | 29 +++++++++++++++--------------
1 file changed, 15 insertions(+), 14 deletions(-)
diff --git a/lisp/magit-process.el b/lisp/magit-process.el
index 8295e3b0e9..b766140606 100644
--- a/lisp/magit-process.el
+++ b/lisp/magit-process.el
@@ -674,16 +674,17 @@ Magit status buffer."
(defun magit-process--format-arguments (program args)
(cond
((and args (equal program (magit-git-executable)))
- (setq args (-split-at (length magit-git-global-arguments) args))
- (concat (propertize (file-name-nondirectory program)
- 'font-lock-face 'magit-section-heading)
- " "
- (propertize (magit--ellipsis)
- 'font-lock-face 'magit-section-heading
- 'help-echo (mapconcat #'identity (car args) " "))
- " "
- (propertize (mapconcat #'shell-quote-argument (cadr args) " ")
- 'font-lock-face 'magit-section-heading)))
+ (let ((global (length magit-git-global-arguments)))
+ (concat
+ (propertize (file-name-nondirectory program)
+ 'font-lock-face 'magit-section-heading)
+ " "
+ (propertize (magit--ellipsis)
+ 'font-lock-face 'magit-section-heading
+ 'help-echo (mapconcat #'identity (seq-take args global) "
"))
+ " "
+ (propertize (mapconcat #'shell-quote-argument (seq-drop args global) "
")
+ 'font-lock-face 'magit-section-heading))))
((and args (equal program shell-file-name))
(propertize (cadr args)
'font-lock-face 'magit-section-heading))
@@ -745,10 +746,10 @@ Magit status buffer."
(--when-let
(magit-get-section
`((commit . ,(magit-rev-parse "HEAD"))
- (,(pcase (car (cadr (-split-at
- (1+ (length magit-git-global-arguments))
- (process-command process))))
- ((or "rebase" "am") 'rebase-sequence)
+ (,(pcase (car (seq-drop
+ (process-command process)
+ (1+ (length magit-git-global-arguments))))
+ ((or "rebase" "am") 'rebase-sequence)
((or "cherry-pick" "revert") 'sequence)))
(status)))
(goto-char (oref it start))
- [nongnu] elpa/git-commit updated (decd5f40dd -> 95d5be9ac3), ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 2b82fc2afc 01/15: Use cl-set-difference instead of -difference, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit da23111429 06/15: Use seq-remove instead of -remove-first, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit e8d4674fd7 08/15: Use seq-find instead of -first, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 3029f64b4a 05/15: Use seq-remove instead of -remove, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 488ed2ad58 04/15: Use seq-filter instead of -filter, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit a6f9c78374 11/15: Use seq-take and seq-drop instead of -split-at,
ELPA Syncer <=
- [nongnu] elpa/git-commit a5ca96edcd 02/15: Use cl-union instead of -union, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 82408757b0 03/15: Use seq-map-indexed instead of -map-indexed, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit c9fad8b58e 10/15: Use mapcar and delq instead of -keep, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit bbb0afb516 13/15: No longer use -separate, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 87afefca87 14/15: No longer use -none-p, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 95d5be9ac3 15/15: No longer use certain obscure dash functions, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit dcbef90475 09/15: Use seq-some instead of -some, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit 8a8ac32def 12/15: magit--transient-args-and-files: New function, ELPA Syncer, 2023/07/31
- [nongnu] elpa/git-commit ecccdfa3a4 07/15: Use cl-substitute instead of -replace, ELPA Syncer, 2023/07/31