<commit_before>#!/bin/sh
trap 'echo PACK FAILED!; exit 1' ERR
SELF=`echo $0 | sed 's/\\\\/\\//g'`
cd "`dirname "$SELF"`" || exit 1
PATH="Stuff:$PATH"
OUT="upload"

VERSION=$(cat VERSION.txt)

# Detect branch and revision
REVISION=`git rev-parse --short HEAD`
BRANCH=`git rev-parse --abbrev-ref HEAD`

# Disable suffix on release branches, otherwise
# use commit SHA as prerelease suffix
case $BRANCH in
release-*)
    ;;
master)
    VERSION="$VERSION-master-$REVISION"
    ;;
*)
    VERSION="$VERSION-dev-$REVISION"
    ;;
esac

uno doctor --configuration=Release --build-number=$VERSION

# Make packages
for f in Source/*; do
    name=`basename "$f"`
    project=$f/$name.unoproj
    if [ -f "$project" ]; then
        uno pack "$project" \
            --version=$VERSION \
            --out-dir="$OUT"
    fi
done<commit_msg>pack.sh: get branch name on AppVeyor<commit_after>#!/bin/sh
trap 'echo PACK FAILED!; exit 1' ERR
SELF=`echo $0 | sed 's/\\\\/\\//g'`
cd "`dirname "$SELF"`" || exit 1
PATH="Stuff:$PATH"
OUT="upload"

VERSION=$(cat VERSION.txt)

# Detect branch and revision
REVISION=`git rev-parse --short HEAD`

if [ -n "$APPVEYOR_REPO_BRANCH" ]; then
    BRANCH=$APPVEYOR_REPO_BRANCH
else
    BRANCH=`git rev-parse --abbrev-ref HEAD`
fi

# Disable suffix on release branches, otherwise
# use commit SHA as prerelease suffix
case $BRANCH in
release-*)
    ;;
master)
    VERSION="$VERSION-master-$REVISION"
    ;;
*)
    VERSION="$VERSION-dev-$REVISION"
    ;;
esac

uno doctor --configuration=Release --build-number=$VERSION

# Make packages
for f in Source/*; do
    name=`basename "$f"`
    project=$f/$name.unoproj
    if [ -f "$project" ]; then
        uno pack "$project" \
            --version=$VERSION \
            --out-dir="$OUT"
    fi
done
{'fraction_non_alphanumeric': 0.1650595575723199, 'fraction_numerical': 0.003403289846851957, 'mean_word_length': 3.0458715596330275, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6006773', 'n_tokens_mistral': 649, 'n_tokens_neox': 612, 'n_words': 167}