<commit_before>#!/bin/bash

REPOSITORY=~/lively4/"$1"
USERNAME="$2"
PASSWORD="$3"
EMAIL="$4"
BRANCH="$5"
MSG="$6"

pushd $REPOSITORY > /dev/null

ORIGIN=`git config --get remote.origin.url | sed "s/https:\/\//https:\/\/$USERNAME:$PASSWORD@/"`

echo "REPO: " "$REPOSITORY" "USERNAME: " "$USERNAME" 

git status --porcelain | grep  "??" | sed 's/^?? /git add /' | bash
git config user.name "$USERNAME"
git config user.email "$EMAIL"
STATUS=`git status --porcelain | grep -v "??" | tr "\n" ";"`
if [ $MSG = "" ]; then
  COMMIT="SYNC "$STATUS
else  
  COMMIT=$MSG
fi
echo COMMIT $COMMIT

git commit -m "$COMMIT" -a ; 
echo "PULL"
git pull --no-edit origin "$BRANCH" ; 

echo "PUSH"
git push $ORIGIN $BRANCH

echo "FETCH AGAIN"
#git fetch origin "$BRANCH"
git fetch
popd > /dev/null<commit_msg>this is a sync message again<commit_after>#!/bin/bash

REPOSITORY=~/lively4/"$1"
USERNAME="$2"
PASSWORD="$3"
EMAIL="$4"
BRANCH="$5"
MSG="$6"

pushd $REPOSITORY > /dev/null

ORIGIN=`git config --get remote.origin.url | sed "s/https:\/\//https:\/\/$USERNAME:$PASSWORD@/"`

echo "REPO: " "$REPOSITORY" "USERNAME: " "$USERNAME" 

git status --porcelain | grep  "??" | sed 's/^?? /git add /' | bash
git config user.name "$USERNAME"
git config user.email "$EMAIL"
STATUS=`git status --porcelain | grep -v "??" | tr "\n" ";"`
if [ -z "$MSG" ]; then
  COMMIT="SYNC "$STATUS
else  
  COMMIT="$MSG"
fi
echo COMMIT $COMMIT

git commit -m "$COMMIT" -a ; 
echo "PULL"
git pull --no-edit origin "$BRANCH" ; 

echo "PUSH"
git push $ORIGIN $BRANCH

echo "FETCH AGAIN"
#git fetch origin "$BRANCH"
git fetch
popd > /dev/null
{'fraction_non_alphanumeric': 0.2043887147335423, 'fraction_numerical': 0.00877742946708464, 'mean_word_length': 3.8658536585365852, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '6567488', 'n_tokens_mistral': 672, 'n_tokens_neox': 647, 'n_words': 175}