aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2013-05-02 17:37:36 +0000
committerDaniel Jasper <djasper@google.com>2013-05-02 17:37:36 +0000
commit82e3b47276f175a4b51772525da5314f0f48df9c (patch)
treea178dcea6bbcb043009d3b6e28feb32b57504dc3 /docs
parentfa6b079b1231366696f6a497c6a084c73a35c85d (diff)
Basic clang-format integration for BBEdit.
Thanks to Avi Drissman! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@180933 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'docs')
-rw-r--r--docs/ClangFormat.rst15
1 files changed, 15 insertions, 0 deletions
diff --git a/docs/ClangFormat.rst b/docs/ClangFormat.rst
index 1b65c2542b..964fc84d7b 100644
--- a/docs/ClangFormat.rst
+++ b/docs/ClangFormat.rst
@@ -81,6 +81,21 @@ This binds the function `clang-format-region` to C-M-tab, which then formats the
current line or selected region.
+BBEdit Integration
+==================
+
+:program:`clang-format` cannot be used as a text filter with BBEdit, but works
+well via a script. The AppleScript to do this integration can be found at
+`clang/tools/clang-format/clang-format-bbedit.applescript`; place a copy in
+`~/Library/Application Support/BBEdit/Scripts`, and edit the path within it to
+point to your local copy of :program:`clang-format`.
+
+With this integration you can select the script from the Script menu and
+:program:`clang-format` will format the selection. Note that you can rename the
+menu item by renaming the script, and can assign the menu item a keyboard
+shortcut in the BBEdit preferences, under Menus & Shortcuts.
+
+
Script for patch reformatting
=============================