<commit_before>#!/bin/sh -e
# Author: <NAME>
# Description: Installs Fedora 20 basics environment
# Usage: su -c "sh install.sh"
# set -e

set -o errexit

yum update -y

# basic
yum install -y nano wget tree gnome-tweak-tool deluge audacious audacious-plugin audacious-plugins-exotic gparted grsync

# git
yum install -y git git-cola

# phpbrew
yum install -y php php-devel php-pear bzip2-devel yum-utils bison re2c libmcrypt-devel libpqxx-devel libxslt-devel
curl -L -O https://raw.githubusercontent.com/c9s/phpbrew/master/phpbrew
chmod +x phpbrew
mv phpbrew /usr/local/bin/phpbrew
/usr/local/bin/phpbrew init
source /root/.phpbrew/bashrc
echo '# loading phpbrew' >> ~/.bashrc
echo 'source ~/.phpbrew/bashrc' >> ~/.bashrc

# fedy
curl http://satya164.github.io/fedy/fedy-installer -o fedy-installer && chmod +x fedy-installer && ./fedy-installer
fedy --enable-log --exec google_chrome
fedy --enable-log --exec sublime_text3
fedy --enable-log --exec tor_browser
fedy --enable-log --exec config_selinux
fedy --enable-log --exec config_sudo
fedy --enable-log --exec oracle_jre
fedy --enable-log --exec adobe_flash

# VirtualBox
wget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo -O /etc/yum.repos.d/virtualbox.repo
yum update -y
yum install -y VirtualBox.x86_64

# composer
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer

# phpunit
wget https://phar.phpunit.de/phpunit-beta.phar
chmod +x phpunit-beta.phar
mv phpunit-beta.phar /usr/local/bin/phpunit

# php-cs-fixer
wget http://get.sensiolabs.org/php-cs-fixer.phar -O /usr/local/bin/php-cs-fixer
chmod +x /usr/local/bin/php-cs-fixer

# php repl
# composer global require psy/psysh
wget psysh.org/psysh
chmod +x psysh
mv psysh /usr/local/bin/psysh

# revisor
yum install -y revisor

echo "OK, all set :)"<commit_msg>add better bootstrap for fedora php devel machine<commit_after>#!/usr/bin/env bash
# Author: <NAME>
# Description: Installs Fedora 20 basics environment
# Usage: sudo bash fedora-bootstrap.sh

trap "exit 1" ERR

USERHOME=$(eval "echo ~$SUDO_USER")
USERBASHRC="$USERHOME/.bashrc"

# add virtual box repo
echo -e "\nAdding Virtual Box repo to yum...\n"
curl http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo -o /etc/yum.repos.d/virtualbox.repo

# update distro
echo -e "\nUpdating distro...\n"
yum clean all
yum -y update

# basic packages
echo -e "\nInstalling basic packages with yum...\n"
yum install -y nano wget curl tree gnome-tweak-tool deluge audacious audacious-plugin audacious-plugins-exotic gparted grsync git git-daemon git-cola livecd-tools spin-kickstarts system-config-kickstart qemu gstream pgadmin3

# install fedy
echo -e "\nInstalling Fedy...\n"
command -v fedy || su -c "curl http://satya164.github.io/fedy/fedy-installer -o fedy-installer && chmod +x fedy-installer && ./fedy-installer"

echo -e "\nInstalling basic programs with Fedy...\n"
fedy --enable-log --exec config_selinux
fedy --enable-log --exec sublime_text3
fedy --enable-log --exec google_chrome
fedy --enable-log --exec tor_browser
fedy --enable-log --exec config_sudo
fedy --enable-log --exec oracle_jre 
fedy --enable-log --exec nautilus_dropbox
fedy --enable-log --exec core_fonts
fedy --enable-log --exec adobe_flash
fedy --enable-log --exec media_codecs
fedy --enable-log --exec rpmfusion_repos

# install docker
yum -y install docker-io && systemctl enable docker

# install phpbrew requirements
echo -e "\nInstalling phpbrew requirements...\n"
yum install -y php php-devel php-pear bzip2-devel yum-utils bison re2c libmcrypt-devel libpqxx-devel libxslt-devel

# install phpbrew
echo -e "\nInstalling phpbrew...\n"
curl -L -O https://raw.githubusercontent.com/phpbrew/phpbrew/master/phpbrew
chmod +x phpbrew
mv phpbrew /usr/local/bin/phpbrew
runuser -l $SUDO_USER -c '/usr/local/bin/phpbrew init'
curl https://raw.githubusercontent.com/phpbrew/phpbrew/master/completion/bash/_phpbrew -o "$USERHOME/.phpbrew/comp"
grep -q '# loading phpbrew' "$USERBASHRC" || echo -e "\n# loading phpbrew\nsource ~/.phpbrew/bashrc && source ~/.phpbrew/comp\n" >> $USERBASHRC
    
# echo -e "\nInstalling php 5.5.13 with phpbrew...\n"
# /usr/local/bin/phpbrew install 5.5.13 +default+dbs-json+tokenizer && phpbrew ext install phar && phpbrew ext install xdebug

# VirtualBox
# yum install -y VirtualBox

# composer
echo -e "\nInstalling composer...\n"
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer

# phpunit
echo -e "\nInstalling phpunit...\n"
curl https://phar.phpunit.de/phpunit-beta.phar -o /usr/local/bin/phpunit
chmod +x /usr/local/bin/phpunit

# php-cs-fixer
echo -e "\nInstalling php-cs-fixer...\n"
curl http://get.sensiolabs.org/php-cs-fixer.phar -o /usr/local/bin/php-cs-fixer
chmod +x /usr/local/bin/php-cs-fixer

# php repl
echo -e "\nInstalling psysh (php repl)...\n"
curl http://psysh.org/psysh -o /usr/local/bin/psysh
chmod +x /usr/local/bin/psysh

echo -e "\nAll set!\n"

exit 0
{'fraction_non_alphanumeric': 0.13777867041574612, 'fraction_numerical': 0.006426993372163085, 'mean_word_length': 3.662921348314607, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 11, 'https://': 7, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4767968', 'n_tokens_mistral': 1940, 'n_tokens_neox': 1827, 'n_words': 484}