Skip to content

Instantly share code, notes, and snippets.

View havramar's full-sized avatar

Marcin Hawraniak havramar

  • Plum Research S.A.
View GitHub Profile
@havramar
havramar / gist:da9ae1eeb42f7a0de9b4
Created February 11, 2015 08:36
Vagrant (file) nfs on steroids
# Found here https://github.com/mitchellh/vagrant/issues/4204
if RUBY_PLATFORM =~ /mingw32/
config.vm.synced_folder ".", "/project"
else
config.vm.synced_folder ".", "/project", type: "nfs", mount_options:['nolock,vers=3,udp,noatime,actimeo=1']
end
@havramar
havramar / config.yml
Created February 11, 2015 08:18
Compass configuration in Symfony2 app as a filter.
assetic:
# When enabling compass, don't forget to add to parameters.yml:
# assetic.filter.compass.images_dir: %kernel.root_dir%/../web
# assetic.filter.compass.http_path: /
compass:
bin: /usr/local/bin/compass
apply_to: "\.scss$"
load_paths:
- %kernel.root_dir%/../assets/scss
namespace :apc do
desc <<-DESC
Create a temporary PHP file to clear APC cache, call it (using curl) and removes it
This task must be triggered AFTER the deployment to clear APC cache
DESC
task :clear_cache do
front_url = fetch(:front_url)
apc_script_path = fetch(:apc_script_path)
@havramar
havramar / jenknis-table-rows-hover-background-color.md
Created October 21, 2014 23:03
Jenkins theme - table rows background highlight on hover
  1. Install Simple Theme Plugin.
  2. Put rows.css to .jenkins/userContent/rows.css.
  3. Go to http://localhost:8080/configure.
  4. URL of theme CSS set to http://localhost:8080/userContent/rows.css.
  5. Save and Reload page.
@havramar
havramar / bash-setup.md
Last active August 29, 2015 14:07
Some bash configuration tips

Case insensitive tab completion:

echo "set completion-ignore-case on" >> ~/.inputrc

Git branch being displayed. Add to ~/.bashrc:

PS1="$GREEN\u@\h$NO_COLOR:\w$YELLOW\$(parse_git_branch)$NO_COLOR\$ "
@havramar
havramar / selenium-xvfb-debian.md
Last active August 29, 2015 14:07
Selenium with Xvfb on Debian

Steps to setup selenium with xvfb on debian

apt-get install xvfb
wget http://selenium-release.storage.googleapis.com/2.43/selenium-server-standalone-2.43.1.jar

sudo echo "deb http://downloads.sourceforge.net/project/ubuntuzilla/mozilla/apt all main" >> /etc/apt/sources.list
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com C1289A29

sudo apt-get update
@havramar
havramar / PHPCS-PSR2-standard-with-var_dump-disallowed
Last active April 3, 2018 14:53
PHPCS PSR2 standard with var_dump disallowed
We couldn’t find that file to show.