[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnunet] 02/04: add clang-format to emacs configuration (st
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnunet] 02/04: add clang-format to emacs configuration (still requires clang-format to be installed globally first) |
Date: |
Thu, 18 Apr 2019 18:44:22 +0200 |
This is an automated email from the git hooks/post-receive script.
grothoff pushed a commit to branch master
in repository gnunet.
commit 6ea190f42924f74736fe21ec5bd38df105e39562
Author: Christian Grothoff <address@hidden>
AuthorDate: Thu Apr 18 17:49:08 2019 +0200
add clang-format to emacs configuration (still requires clang-format to be
installed globally first)
---
.dir-locals.el | 3 +++
.gitignore | 1 +
bootstrap | 3 +++
3 files changed, 7 insertions(+)
diff --git a/.dir-locals.el b/.dir-locals.el
index 687863811..29999b944 100644
--- a/.dir-locals.el
+++ b/.dir-locals.el
@@ -1,5 +1,8 @@
;; Per-directory local variables for GNU Emacs 23 and later.
+((c-mode
+ (eval add-hook 'before-save-hook #'clang-format-buffer nil t)))
+
((nil
. ((fill-column . 78)
(tab-width . 4)
diff --git a/.gitignore b/.gitignore
index 31cfa5897..e898f41f8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -11,6 +11,7 @@
*.swp
*.trs
*.kdev4
+.clang-format
.deps/
.libs/
.svn/
diff --git a/bootstrap b/bootstrap
index 9d9d97b1d..c87f375ea 100755
--- a/bootstrap
+++ b/bootstrap
@@ -3,6 +3,9 @@
echo "Removing folder 'libltdl'..."
rm -rf libltdl
+# Install clang format symlink (if possible)
+ln -s contrib/conf/editors/clang-format .clang-format &> /dev/null
+
echo "checking for libtoolize / libtool... "
# This is more portable than `which' but comes with
--
To stop receiving notification emails like this one, please contact
address@hidden