update packages

This commit is contained in:
2025-03-11 21:14:26 +01:00
parent 45d49daef0
commit 14dcaaddde
440 changed files with 13229 additions and 8718 deletions

View File

@@ -1,3 +1,4 @@
;;; -*- lexical-binding: t -*-
(require 'yasnippet)
;; whitespace removing functions from Magnar Sveen ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -28,9 +29,17 @@
"This function returns `comment-start' trimmed by whitespaces."
(yas-s-trim comment-start))
(defun yas-trimmed-add-comment ()
"This function returns `comment-start' trimmed by whitespaces. It uses
`comment-add' to determine how many comment symbols to insert."
(yas-s-trim (apply #'concat (mapcar (lambda (x)
comment-start)
(number-sequence 0 comment-add)))))
(defun yas-trimmed-comment-end ()
"This function returns `comment-end' trimmed by whitespaces if `comment-end' is not empty.
Otherwise the reversed output of function `yas-trimmed-comment-start' is returned."
"This function returns `comment-end' trimmed by whitespaces if
`comment-end' is not empty. Otherwise the reversed output of
function `yas-trimmed-comment-start' is returned."
(if (eq (length comment-end) 0)
(yas-string-reverse (yas-trimmed-comment-start))
(yas-s-trim comment-end)))

View File

@@ -15,15 +15,20 @@ ${1:$(let* ((col (current-column))
${1:$(let* ((col (current-column))
(str "")
(start (yas-trimmed-comment-start))
(start (if (string= start ";") ";;" start))
(end (yas-trimmed-comment-end)))
(while (< (length str) (ffloor (/ (- 78.0 (+ col (length start) (string-width yas-text) (length end))) 2.0)))
(setq str (concat str " ")))
(concat start str))} ${1:comment} ${1:$(let* ((col (current-column))
(str "")
(start (yas-trimmed-comment-start))
(end (yas-trimmed-comment-end)))
(while (< (length str) (- 79.0 (if (eq (mod (string-width yas-text) 2) 1) (- col 1) col) (length end)))
(setq str (concat str " ")))
(concat start str))} ${1:comment} ${1:$(
let* ((col (current-column))
(str "")
(start (yas-trimmed-comment-start))
(start (if (string= start ";") ";;" start))
(end (yas-trimmed-comment-end)))
(while (< (length str)
(- 79 (length end)
(if (eq (mod (+ (string-width yas-text) (length start) (length end)) 2) 1) (- col 1) col)))
(setq str (concat str " ")))
(concat str end))}
${1:$(let* ((col (current-column))
(str "")

View File

@@ -1,6 +1,6 @@
# -*- mode: snippet -*-
# name: fixme
# key: fi
# condition: (not (eq major-mode 'sh-mode))
# condition: (not (member major-mode '(sh-mode bash-ts-mode)))
# --
`comment-start`FIXME: $0`comment-end`

View File

@@ -0,0 +1,6 @@
# -*- mode: snippet -*-
# contributor: Antero Mejr <mail@antr.me>
# name: spdxcopyright
# key: spc
# --
`(yas-trimmed-add-comment)` SPDX-FileCopyrightText: $0`comment-end`

View File

@@ -0,0 +1,6 @@
# -*- mode: snippet -*-
# contributor: Antero Mejr <mail@antr.me>
# name: spdxlicense
# key: spl
# --
`(yas-trimmed-add-comment)` SPDX-License-Identifier: $0`comment-end`