<commit_before>#!/bin/bash
# Tested with Base AMI: ami-9b0228e4

sudo pacman -Sy --noconfirm sudo git curl tmux vim mc tig python2 python2-pip p7zip htop mc wget unzip zsh protobuf
sudo pacman -Sy --noconfirm tree nano dos2unix bc python python-pip cmake graphviz python-h5py ctags 
sudo pacman -Sy --noconfirm rsync ranger go compton virtualgl termite i3 i3status i3blocks sddm feh tigervnc ttf-inconsolata

groupadd gbencke
useradd -m -g gbencke  -s /bin/bash gbencke
echo "gbencke  ALL=(ALL) ALL" >> /etc/sudoers

git config --global user.email "<EMAIL>"  
git config --global user.name "<NAME>"  
git config --global push.default simple
git config --global core.editor vim

pip2 install autopep8 pylint virtualenv pmm cython pillow lxml
pip install autopep8 pylint virtualenv pmm cython pillow lxml

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash

vncserver

mkdir -p /var/git/000.INFRA
chmod 755 -R /var/git 
chmod 755 /root
cd /var/git/000.INFRA
git clone http://github.com/gbencke/dotfiles/
mkdir -p ~/.config/termite
cp /var/git/000.INFRA/dotfiles/new.host/arch/termite/config ~/.config/termite/config
cp -r /var/git/000.INFRA/dotfiles/new.host/wallpaper ~/Wallpapers
cp /var/git/000.INFRA/dotfiles/new.host/arch/vnc/xstartup ~/.vnc/xstartup
cp /var/git/000.INFRA/dotfiles/new.host/arch/vnc/config ~/.vnc/config
mkdir -p ~/.config/i3/
cp /var/git/000.INFRA/dotfiles/new.host/arch/vnc/i3config ~/.config/i3/config
cat /var/git/000.INFRA/dotfiles/shells/bashrc >> ~/.bashrc

vncserver -kill :1
vncserver

passwd gbencke
su gbencke
cd
ln -s /var/git ~/git 
unset NVM_DIR 2>/dev/null
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash
git config --global user.email "<EMAIL>"  
git config --global user.name "<NAME>"  
git config --global push.default simple
git config --global core.editor vim
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
cat /var/git/000.INFRA/dotfiles/shells/bashrc >> ~/.bashrc
cat /var/git/000.INFRA/dotfiles/shells/zshrc >> ~/.zshrc
cp /var/git/000.INFRA/dotfiles/new.host/tmux/.tmux.conf ~/.tmux.conf
sed -i -e 's/robbyrussell/clean/g' /home/gbencke/.zshrc
$SHELL
<commit_msg>Separated interactive and non-interactive commands<commit_after>#!/bin/bash
# Tested with Base AMI: ami-9b0228e4

#NONINTERACTIVE
    sudo pacman -Sy --noconfirm sudo git curl tmux vim mc tig python2 python2-pip p7zip htop mc wget unzip zsh protobuf
    sudo pacman -Sy --noconfirm tree nano dos2unix bc python python-pip cmake graphviz python-h5py ctags 
    sudo pacman -Sy --noconfirm rsync ranger go compton virtualgl termite i3 i3status i3blocks sddm feh tigervnc ttf-inconsolata

    groupadd gbencke
    useradd -m -g gbencke  -s /bin/bash gbencke
    echo "gbencke  ALL=(ALL) ALL" >> /etc/sudoers

    git config --global user.email "<EMAIL>"  
    git config --global user.name "<NAME>"  
    git config --global push.default simple
    git config --global core.editor vim

    pip2 install autopep8 pylint virtualenv pmm cython pillow lxml
    pip install autopep8 pylint virtualenv pmm cython pillow lxml

    curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash

#INTERACTIVE
    vncserver

#NONINTERACTIVE
    mkdir -p /var/git/000.INFRA
    chmod 755 -R /var/git 
    chmod 755 /root
    cd /var/git/000.INFRA
    git clone http://github.com/gbencke/dotfiles/
    mkdir -p ~/.config/termite
    cp /var/git/000.INFRA/dotfiles/new.host/arch/termite/config ~/.config/termite/config
    cp -r /var/git/000.INFRA/dotfiles/new.host/wallpaper ~/Wallpapers
    cp /var/git/000.INFRA/dotfiles/new.host/arch/vnc/xstartup ~/.vnc/xstartup
    cp /var/git/000.INFRA/dotfiles/new.host/arch/vnc/config ~/.vnc/config
    mkdir -p ~/.config/i3/
    cp /var/git/000.INFRA/dotfiles/new.host/arch/vnc/i3config ~/.config/i3/config
    cat /var/git/000.INFRA/dotfiles/shells/bashrc >> ~/.bashrc
    vncserver -kill :1
    vncserver

#INTERACTIVE	
    passwd gbencke
    su gbencke
	
#NONINTERACTIVE
    cd
    ln -s /var/git ~/git 
    unset NVM_DIR 2>/dev/null
    curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash
    git config --global user.email "<EMAIL>"  
    git config --global user.name "<NAME>"  
    git config --global push.default simple
    git config --global core.editor vim
	
#INTERACTIVE
	sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

#NONINTERACTIVE	
    cat /var/git/000.INFRA/dotfiles/shells/bashrc >> ~/.bashrc
    cat /var/git/000.INFRA/dotfiles/shells/zshrc >> ~/.zshrc
    cp /var/git/000.INFRA/dotfiles/new.host/tmux/.tmux.conf ~/.tmux.conf
    sed -i -e 's/robbyrussell/clean/g' /home/gbencke/.zshrc
$SHELL

{'fraction_non_alphanumeric': 0.12701065385418842, 'fraction_numerical': 0.029663672446208482, 'mean_word_length': 3.163478260869565, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 29, 'https://': 6, 'lorem ipsum': 0, 'www.': 0, 'xml': 4}, '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': '100163', 'n_tokens_mistral': 1982, 'n_tokens_neox': 1848, 'n_words': 439}