port code review scripts to git

This commit is contained in:
hankhill19580
2020-10-18 20:41:16 +00:00
parent 6da859492f
commit d616a88c87
16 changed files with 99 additions and 5 deletions

View File

@ -19,7 +19,7 @@ MTN=mtn
#SERVER="mtn.i2p-projekt.de:4691"
SERVER="localhost:8998"
INCLUDE_BRANCHES=0
PUSH_TO_GITHUB=1
PUSH_TO_GITHUB=0
BARE_REPO=1
#cd $(dirname "$0")

View File

@ -5,7 +5,7 @@
# zzz 06-2012
# public domain
#
DB=i2p.mtn
DB=/home/idk/.monotone/databases/default.mtn
TMP=/var/tmp/i2platest$$
TMP2=/var/tmp/i2platestx$$

6
source/git-diffreport.sh Normal file
View File

@ -0,0 +1,6 @@
#! /usr/bin/env sh
# diffstat the changes from the last release to the current workspace;
# similar to diffreport.sh
git diff $(git tag --sort=committerdate | tail -1) | diffstat -D . -f 4

10
source/git-review.sh Normal file
View File

@ -0,0 +1,10 @@
#! /usr/bin/env sh
#
# view the diff for the files listed in filelist.txt
# zzz 2008-10
#
# This does not diff based on the latest release tag, it diffs
# the workspace against the latest checked in code.
# idk 2020-10
git diff `cat filelist.txt` > out.diff 2>&1
$EDITOR out.diff

10
source/git-reviewall.sh Normal file
View File

@ -0,0 +1,10 @@
#! /usr/bin/env sh
#
# view the diff from the current head for all files changed in the workspace
# zzz 2008-10
#
# This does not diff based on the latest release tag, it diffs
# the workspace against the latest checked in code.
# idk 2020-10
git diff > out.diff
$EDITOR out.diff

View File

@ -0,0 +1,12 @@
#! /usr/bin/env sh
#
# view the changes from the last release for all files in the workspace;
# this includes local changes not checked in
# zzz 2008-10
#
# Re-written for git.
# idk 2020-10
REL=$(git diff `git tag --sort=committerdate | tail -1`)
git diff $(git tag --sort=committerdate | tail -1) > $REL.diff
$EDITOR $REL.diff

View File

@ -0,0 +1,13 @@
#! /usr/bin/env sh
#
# view the changes from the last release to the current head;
# files not checked in are not included
# Note that this actually diffs the workspace base (w:) not the head (h:)
# zzz 2008-10
#
# Re-written for git. The git version uses the current head.
# idk 2020-10
REL=$(git diff `git tag --sort=committerdate | tail -1`)
git diff $(git tag --sort=committerdate | tail -1) $(git rev-parse --short HEAD) > $REL.diff
$EDITOR $REL.diff

View File

@ -0,0 +1,25 @@
#! /usr/bin/env sh
#
# view the changes from the last release to the current head;
# files not checked in are not included
# Skip .po files and geoip.txt
# Note that this actually diffs the workspace base (w:) not the head (h:)
# zzz 2010-03
#
# Re-written for git. The git version uses the current head.
# idk 2020-10
REL=$(git diff `git tag --sort=committerdate | tail -1`)
MOREEXCLUDE="installer/resources/geoip.txt"
echo "Diffing from $REL"
POS=`find -name \*.po`
for i in $MOREEXCLUDE $POS core/java/src/gnu/getopt/*.properties
do
EXCLUDE="$EXCLUDE :(exclude)$i"
done
echo "excluding $EXCLUDE"
git diff $(git tag --sort=committerdate | tail -1) $(git rev-parse --short HEAD) $EXCLUDE > $REL.diff
$EDITOR $REL.diff

View File

@ -0,0 +1,14 @@
#! /usr/bin/env sh
#
# view the changes in the current workspace for files NOT listed
# in filelist.txt; this is a good way to make sure you're not
# forgetting something that should be in filelist.txt before you
# check it in
# zzz 2008-10
#
# Re-written for git.
# idk 2020-10
git diff `cat filelist.txt` > out.diff
git diff > all.diff
diff all.diff out.diff | cut -c3- > missing.diff
$EDITOR missing.diff

View File

@ -1,4 +1,4 @@
#!/bin/sh
#! /bin/sh
#
# grep the source
# maybe grep -R would be better

View File

@ -1,4 +1,4 @@
#!/bin/bash
#! /bin/sh
#
# view the diff for the files listed in filelist.txt
# zzz 2008-10

View File

@ -1,3 +1,4 @@
#! /bin/sh
#
# view the diff from the current head for all files changed in the workspace
# zzz 2008-10

View File

@ -1,3 +1,4 @@
#! /bin/sh
#
# view the changes from the last release for all files in the workspace;
# this includes local changes not checked in

View File

@ -1,4 +1,4 @@
#!/bin/sh
#! /bin/sh
#
# view the changes from the last release to the current head;
# files not checked in are not included

View File

@ -1,3 +1,4 @@
#!/bin/sh
#
# view the changes from the last release to the current head;
# files not checked in are not included

View File

@ -1,3 +1,4 @@
#! /bin/sh
#
# view the changes in the current workspace for files NOT listed
# in filelist.txt; this is a good way to make sure you're not