<commit_before>#!/bin/bash

set -e

echo '[setup] Checking for a ~/.emacs.'
if [[ -e ~/.emacs || -L ~/.emacs ]]; then
    echo "[setup] Found one, moving it to originals/$UUID."
    mv ~/.emacs originals/$UUID/.emacs
else
    echo "[setup] Looks like you don't have one."
fi

echo '[setup] Checking for a ~/.emacs.el.'
if [[ -e ~/.emacs.el || -L ~/.emacs.el ]]; then
    echo "[setup] Found one, moving it to originals/$UUID."
    mv ~/.emacs.el originals/$UUID/.emacs.el
else
    echo "[setup] Looks like you don't have one."
fi

echo '[setup] Checking for a ~/.emacs.d.'
if [[ -e ~/.emacs.d || -L ~/.emacs.d ]]; then
    echo "[setup] Found one, moving it to originals/$UUID."
    mv ~/.emacs.d originals/$UUID/.emacs.d
else
    echo "[setup] Looks like you don't have one."
fi

echo '[setup] Creating symlink for .emacs.d.'
ln -s "$(cd .. && pwd)/.emacs.d" ~/.emacs.d<commit_msg>Don't recreate .emacs.d symlink if unnecessary<commit_after>#!/bin/bash

set -e

echo '[setup] Checking for a ~/.emacs.'
if [[ -e ~/.emacs || -L ~/.emacs ]]; then
    echo "[setup] Found one, moving it to originals/$UUID."
    mv ~/.emacs originals/$UUID/.emacs
else
    echo "[setup] Looks like you don't have one."
fi

echo '[setup] Checking for a ~/.emacs.el.'
if [[ -e ~/.emacs.el || -L ~/.emacs.el ]]; then
    echo "[setup] Found one, moving it to originals/$UUID."
    mv ~/.emacs.el originals/$UUID/.emacs.el
else
    echo "[setup] Looks like you don't have one."
fi

echo '[setup] Checking for a ~/.emacs.d.'
if [[ ~/.emacs.d -ef ../.emacs.d ]]; then
    echo '[setup] It appears that ~/.emacs.d is already correctly symlinked.'
else
    if [[ -e ~/.emacs.d || -L ~/.emacs.d ]]; then
        echo "[setup] Found one, moving it to originals/$UUID."
        mv ~/.emacs.d originals/$UUID/.emacs.d
    else
        echo "[setup] Looks like you don't have one."
    fi
    echo '[setup] Creating symlink for .emacs.d.'
    ln -s "$(cd .. && pwd)/.emacs.d" ~/.emacs.d
fi
{'fraction_non_alphanumeric': 0.19171779141104295, 'fraction_numerical': 0.0, 'mean_word_length': 2.526126126126126, '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': '5878406', 'n_tokens_mistral': 737, 'n_tokens_neox': 729, 'n_words': 247}