From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id E422415807A for ; Sun, 6 Oct 2024 19:45:21 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 203E6E29A4; Sun, 6 Oct 2024 19:45:21 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id C2916E29A4 for ; Sun, 6 Oct 2024 19:45:20 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A2B92342FE1 for ; Sun, 6 Oct 2024 19:45:19 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id DA9C911DF for ; Sun, 6 Oct 2024 19:45:17 +0000 (UTC) From: "Maciej Barć" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Maciej Barć" Message-ID: <1728243858.2a5d555bcef7479cc8c10849938e4eb96af922ee.xgqt@gentoo> Subject: [gentoo-commits] proj/emacs-ebuild-snippets:master commit in: / X-VCS-Repository: proj/emacs-ebuild-snippets X-VCS-Files: ebuild-snippets.el X-VCS-Directories: / X-VCS-Committer: xgqt X-VCS-Committer-Name: Maciej Barć X-VCS-Revision: 2a5d555bcef7479cc8c10849938e4eb96af922ee X-VCS-Branch: master Date: Sun, 6 Oct 2024 19:45:17 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 2ec25560-5ca7-43f0-95ee-d1db9f7beb4e X-Archives-Hash: 1271416fd38dcec8bfad5b85707f9ba1 commit: 2a5d555bcef7479cc8c10849938e4eb96af922ee Author: Maciej Barć gentoo org> AuthorDate: Sun Oct 6 19:44:18 2024 +0000 Commit: Maciej Barć gentoo org> CommitDate: Sun Oct 6 19:44:18 2024 +0000 URL: https://gitweb.gentoo.org/proj/emacs-ebuild-snippets.git/commit/?id=2a5d555b fix(ebuild-snippets): account for yas-snippet-dirs being a string and not a list Signed-off-by: Maciej Barć gentoo.org> ebuild-snippets.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ebuild-snippets.el b/ebuild-snippets.el index fccb40d..a16b14f 100644 --- a/ebuild-snippets.el +++ b/ebuild-snippets.el @@ -78,7 +78,12 @@ ;;;###autoload (defun ebuild-snippets-initialize () "Ebuild-Snippets initialization." - (add-to-list 'yas-snippet-dirs ebuild-snippets-directory t) + ;; Because `yas-snippet-dirs' may be a string. + (cond + ((listp yas-snippet-dirs) + (add-to-list 'yas-snippet-dirs ebuild-snippets-directory t)) + (t + (setq yas-snippet-dirs (list yas-snippet-dirs ebuild-snippets-directory)))) (yas-load-directory ebuild-snippets-directory)) ;;;###autoload