<commit_before>#!/bin/bash
. /opt/farm/scripts/init
. /opt/farm/scripts/functions.custom


if [ "`getent passwd backup`" = "" ]; then
	echo "creating backup user and group"
	if [ "$OSTYPE" = "freebsd" ]; then
		pw groupadd backup -g 34
		pw useradd backup -u 34 -g backup -s /bin/sh -m
	else
		groupadd -g 34 backup
		useradd -u 34 -g backup -s /bin/sh -m backup
	fi
fi

path=`local_backup_directory`

echo "setting up backup directories"
mkdir -p            $path/daily $path/weekly $path/custom
chmod 0700          $path/daily $path/weekly $path/custom<commit_msg>enabling shell for backup user on debian, moved from core sf to extension<commit_after>#!/bin/bash
. /opt/farm/scripts/init
. /opt/farm/scripts/functions.custom


if [ "`getent passwd backup`" = "" ]; then
	echo "creating backup user and group"
	if [ "$OSTYPE" = "freebsd" ]; then
		pw groupadd backup -g 34
		pw useradd backup -u 34 -g backup -s /bin/sh -m
	else
		groupadd -g 34 backup
		useradd -u 34 -g backup -s /bin/sh -m backup
	fi
fi

if [ "$OSTYPE" = "debian" ] && [ "`getent passwd backup |cut -d: -f7`" = "/usr/sbin/nologin" ]; then
	echo "enabling rsync access for backup user"
	usermod -s /bin/sh backup
fi

path=`local_backup_directory`

echo "setting up backup directories"
mkdir -p            $path/daily $path/weekly $path/custom
chmod 0700          $path/daily $path/weekly $path/custom
{'fraction_non_alphanumeric': 0.12773722627737227, 'fraction_numerical': 0.01824817518248175, 'mean_word_length': 3.0323529411764705, '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': '2414613', 'n_tokens_mistral': 537, 'n_tokens_neox': 483, 'n_words': 164}