This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/usr/bin/env bash | |
# MIT © Sindre Sorhus - sindresorhus.com | |
# forked by Gianluca Guarini | |
changed_files="$(git diff-tree -r --name-only --no-commit-id ORIG_HEAD HEAD)" | |
check_run() { | |
echo "$changed_files" | grep --quiet "$1" && eval "$2" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project name="my-project" default="build"> | |
<target name="build" depends="prepare,install-dependencies,lint,phploc,pdepend,phpmd-ci,phpcs-ci,phpcpd,phpdoc,phpunit,phpcb"/> | |
<target name="build-parallel" depends="prepare,lint,tools-parallel,phpunit,phpcb"/> | |
<target name="tools-parallel" description="Run tools in parallel"> | |
<parallel threadCount="2"> | |
<sequential> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo "Downloading and installing Scala 2.10.3..." | |
sudo /usr/local/src | |
sudo wget -c http://www.scala-lang.org/files/archive/scala-2.10.3.tgz | |
sudo tar zxf scala-2.10.3.tgz | |
sudo mv scala-2.10.3 /usr/share/scala | |
sudo ln -s /usr/share/scala/bin/scala /usr/bin/scala |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Entity; | |
use Doctrine\ORM\Mapping as ORM; | |
use Doctrine\Common\Collections\ArrayCollection; | |
/** | |
* Product entity | |
* | |
* @ORM\Table(name="catalog_product") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# SHOW GIT BRANCH | |
function parse_git_branch { | |
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' | |
} | |
# no colors | |
export PS1="\u@\h:\W \$(parse_git_branch)\$ " | |
# with some colors | |
export PS1="\[\033[01;32m\]\u@\h\[\033[01;34m\]:\W \$(parse_git_branch)\$\[\033[00m\] " |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# httpd Startup script for the Apache HTTP Server | |
# | |
# chkconfig: - 85 15 | |
# description: The Apache HTTP Server is an efficient and extensible \ | |
# server implementing the current HTTP standards. | |
# processname: httpd | |
# config: /etc/httpd/conf/httpd.conf | |
# config: /etc/sysconfig/httpd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### ADD RPM Forge repository | |
wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm | |
rpm --import http://apt.sw.be/RPM-GPG-KEY.dag.txt | |
rpm -K rpmforge-release-0.5.2-2.el6.rf.*.rpm # Verifies the package | |
rpm -i rpmforge-release-0.5.2-2.el6.rf.*.rpm | |
### APACHE | |
# Dependencies |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Add Percona repository | |
rpm -Uhv http://www.percona.com/downloads/percona-release/percona-release-0.0-1.x86_64.rpm | |
# Install | |
yum install Percona-Server-client-55 Percona-Server-server-55 | |
# Set root password | |
mysql -u root | |
mysql> use mysql; |