Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F159121893
D28337.id82867.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D28337.id82867.diff
View Options
Index: tools/tools/git/arc-patch
===================================================================
--- /dev/null
+++ tools/tools/git/arc-patch
@@ -0,0 +1,9 @@
+#!/bin/sh
+# Run arc patch and update the commit message afterwards to filter out
+# unneccessary phabricator tags.
+# Since the message probably still needs some editing afterwards, it also
+# runs git commit --amend to allow finalizing the message.
+scriptdir=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)
+arc patch --nobranch --skip-dependencies "$@" && "$scriptdir"/arcfilter.sh
+git commit --amend
+
Index: tools/tools/git/arcfilter.sh
===================================================================
--- /dev/null
+++ tools/tools/git/arcfilter.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+# Remove unnecessary phabricator tags from the commit at HEAD
+# Based on the arcfilter.sh script from LLVM
+git log -1 --pretty=%B | \
+ sed 's/^Summary://' | \
+ awk '/Reviewers:|Subscribers:/{p=1} /Reviewed By:|Differential Revision:/{p=0} !p && !/^Summary:$/ {sub(/^Summary: /,"");print}' | \
+ sed 's/^Reviewers: /Reviewers:\t/' | \
+ sed 's/^Reviewed By: /Reviewed By:\t/' | \
+ git commit --amend --date=now -F -
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Jun 11, 8:54 AM (9 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33873480
Default Alt Text
D28337.id82867.diff (1 KB)
Attached To
Mode
D28337: Add tools/tools/git/arc-patch
Attached
Detach File
Event Timeline
Log In to Comment