<commit_before>#!/usr/bin/env sh

while getopts ":p" opt; do
  case $opt in
    p ) PPA="mapbox" ;;
  esac
done

PROJECT="tilemill"
USER="developmentseed"
: ${PPA:="mapbox-dev"}

CWD=`pwd`
VERSION=`grep -m1 "$PROJECT ([a-z0-9.-]*)" debian/changelog | sed "s/$PROJECT (\([a-z0-9.-]*\)).*/\1/g"`
DIST=`grep -m1 "$PROJECT ([a-z0-9.-]*)" debian/changelog | sed "s/$PROJECT ([a-z0-9.-]*) \([a-z]*\);.*/\1/g"`
TAG=`echo $VERSION | sed "s/\([0-9.]*\).*/\1/g"`

if [ -z "$VERSION" ]; then
  echo "Version could not be determined from debian/changelog."
  exit
fi

if [ ! -f "$CWD/../../package.json" ]; then
  echo "package.sh must be run from the platforms/ubuntu directory."
  exit
fi

while true
do
  echo -n "Build $PROJECT-$TAG for $DIST and upload to $PPA (y/n)? "
  read CONFIRM
  if [ $CONFIRM = "y" ]; then
    break
  elif [ $CONFIRM = "n" ]; then
    echo "Aborting."
    exit
  fi<commit_msg>Allow tilde in debian changelog version.<commit_after>#!/usr/bin/env sh

while getopts ":p" opt; do
  case $opt in
    p ) PPA="mapbox" ;;
  esac
done

PROJECT="tilemill"
USER="developmentseed"
: ${PPA:="mapbox-dev"}

CWD=`pwd`
VERSION=`grep -m1 "$PROJECT ([a-z0-9~.-]*)" debian/changelog | sed "s/$PROJECT (\([a-z0-9~.-]*\)).*/\1/g"`
DIST=`grep -m1 "$PROJECT ([a-z0-9.-]*)" debian/changelog | sed "s/$PROJECT ([a-z0-9.-]*) \([a-z]*\);.*/\1/g"`
TAG=`echo $VERSION | sed "s/\([0-9.]*\).*/\1/g"`

if [ -z "$VERSION" ]; then
  echo "Version could not be determined from debian/changelog."
  exit
fi

if [ ! -f "$CWD/../../package.json" ]; then
  echo "package.sh must be run from the platforms/ubuntu directory."
  exit
fi

while true
do
  echo -n "Build $PROJECT-$TAG for $DIST and upload to $PPA (y/n)? "
  read CONFIRM
  if [ $CONFIRM = "y" ]; then
    break
  elif [ $CONFIRM = "n" ]; then
    echo "Aborting."
    exit
  fi
{'fraction_non_alphanumeric': 0.22679846238330587, 'fraction_numerical': 0.016474464579901153, 'mean_word_length': 2.9868708971553612, 'pattern_counts': {'":': 2, '<': 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': '2945397', 'n_tokens_mistral': 798, 'n_tokens_neox': 758, 'n_words': 198}