[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/auto-header 9afc94dea4 09/26: Warn if not being used in
From: |
ELPA Syncer |
Subject: |
[elpa] externals/auto-header 9afc94dea4 09/26: Warn if not being used in a C-mode buffer |
Date: |
Sun, 26 Mar 2023 07:57:34 -0400 (EDT) |
branch: externals/auto-header
commit 9afc94dea465039b621e72ff72c544dbd740f25f
Author: Philip Kaludercic <philip.kaludercic@fau.de>
Commit: Philip Kaludercic <philip.kaludercic@fau.de>
Warn if not being used in a C-mode buffer
---
auto-header.el | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/auto-header.el b/auto-header.el
index a62a9ace2e..3536bde469 100644
--- a/auto-header.el
+++ b/auto-header.el
@@ -3,7 +3,7 @@
;; Copyright (C) 2022 Philip Kaludercic
;; Author: Philip Kaludercic <philip.kaludercic@fau.de>
-;; Version: $Id: auto-header.el,v 1.7 2022/05/01 20:15:59 oj14ozun Exp
oj14ozun $
+;; Version: $Id: auto-header.el,v 1.8 2022/05/01 20:19:34 oj14ozun Exp $
;; Package-Version: 1.0
;; Keywords: c
@@ -151,7 +151,10 @@ NAME."
"Run `auto-header-buffer' before saving."
:lighter " AH"
(if auto-header-mode
- (add-hook 'before-save-hook #'auto-header-buffer nil t)
+ (progn
+ (unless (derived-mode-p 'c-mode)
+ (warn "Auto-header ought to be used in a C-mode buffer"))
+ (add-hook 'before-save-hook #'auto-header-buffer nil t))
(remove-hook 'before-save-hook #'auto-header-buffer t)))
(provide 'auto-header)
- [elpa] externals/auto-header 49634257f4 03/26: Document auto-header-mode, (continued)
- [elpa] externals/auto-header 49634257f4 03/26: Document auto-header-mode, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header dece50cc3e 05/26: Avoid generating cyclic lists, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 68909a22d3 10/26: Abbreviate Package-Version, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 4cd6c76318 12/26: Add auto-header-insert command, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header bc966c2d8b 22/26: Add a .gitignore, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 25b62deb83 24/26: Add a basic README file, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 1d4201c2c9 18/26: Downcase gcc executable name, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 65cbd3f81d 19/26: Add stdbool.h keywords to auto-header--c-keywords, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 2681884766 26/26: Bump version to 0.1.1 for GNU ELPA, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 74a0455ab5 08/26: Denote internal functions and variables, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 9afc94dea4 09/26: Warn if not being used in a C-mode buffer,
ELPA Syncer <=
- [elpa] externals/auto-header 8fee687422 14/26: Revert last change, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 2afead22b1 17/26: Add completion for auto-header-insert, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header d1734aace9 21/26: Add a .dir-locals.el, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header eb2673089a 23/26: Add GPL-3 as a the license, ELPA Syncer, 2023/03/26
- [elpa] externals/auto-header 4262ea6cc0 25/26: Assign copyright to the FSF, ELPA Syncer, 2023/03/26