<commit_before>#!/bin/bash

set -e

build_and_push() {
    local slug="$1"
    echo "* building $slug ..."
    docker build --pull -t "$slug" .

    echo "* pushing $slug ..."
    docker push "$slug"
}

main() {
    local tag slug version timestamp
    local branch="$1"

    version="$(jq -r '.version' ./packages/teraslice/package.json)"
    timestamp="$(date +%m.%d.%y)"

    if [ -n "$branch" ]; then
        tag="$branch-${timestamp}"
    else
        tag="v$version"
    fi<commit_msg>concretely associate git commit with nightly build of Teraslice, fixes #1038<commit_after>#!/bin/bash

set -e

build_and_push() {
    local slug="$1"
    echo "* building $slug ..."
    docker build --pull -t "$slug" .

    echo "* pushing $slug ..."
    docker push "$slug"
}

main() {
    local tag slug version timestamp commit_hash
    local branch="$1"

    version="$(jq -r '.version' ./packages/teraslice/package.json)"
    timestamp="$(date +%Y.%m.%d)"
    commit_hash="$(git rev-parse --short HEAD)"

    if [ -n "$branch" ]; then
        tag="$branch-${timestamp}-${commit_hash}"
    else
        tag="v$version"
    fi
{'fraction_non_alphanumeric': 0.17946428571428572, 'fraction_numerical': 0.007142857142857143, 'mean_word_length': 2.570063694267516, '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': '88005', 'n_tokens_mistral': 397, 'n_tokens_neox': 366, 'n_words': 98}