File: reformat-patch-for-git-am.sh

package info (click to toggle)
sagemath 8.6-6
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 113,052 kB
  • sloc: python: 996,064; cpp: 6,208; sh: 3,252; ansic: 3,226; objc: 1,407; makefile: 1,087; lisp: 5
file content (13 lines) | stat: -rwxr-xr-x 498 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh
# Hacky script to make it easier to forward our patches upstream, using git-am
sed \
  -e 's/^Description: /Subject: /g' \
  -e 's/^Author: /From: /g' \
  -e '/^Forwarded: /d' \
  -e 's,^--- a/sage/,--- a/,g' \
  -e 's,^+++ b/sage/,+++ b/,g' \
  -e '/^---$/d' \
  -e '/^This patch header follows DEP-3/d' \
  "$1"
echo >&2 "You will still need to edit extended Description stanzas to put them after the"
echo >&2 "email headers, separated by 1 blank line, and de-indent them by 1 space."