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 | |
# | |
# Script to prepare and restore full and incremental backups created with innobackupex-runner. | |
# | |
# This script is provided as-is; no liability can be accepted for use. | |
# | |
INNOBACKUPEX=innobackupex-1.5.1 | |
INNOBACKUPEXFULL=/usr/bin/$INNOBACKUPEX | |
TMPFILE="/tmp/innobackupex-restore.$$.tmp" |
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
(::) étapes échouées (::) | |
01. Server process has been terminated: (1) [ | |
/private/var/folders/fv/kbv9krds57b11blw5vkq1nbw0000gn/T/mink_nodejs_serverAMgtnJ:19 | |
browser = new zombie.Browser(); | |
^ | |
TypeError: undefined is not a function | |
at Socket.<anonymous> (/private/var/folders/fv/kbv9krds57b11blw5vkq1nbw0000gn/T/mink_nodejs_serverAMgtnJ:19:17) | |
at Socket.EventEmitter.emit (events.js:93:17) | |
at TCP.onread (net.js:417:51) |
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
set :domain, 'your.vps.com' | |
set :application, 'your.website.com' | |
set :github_user, 'mnbbrown' | |
set :user, 'www-deploy' | |
set :repository, "git@github.com:#{user}/#{application}.git" | |
set :deploy_to, "/srv/www/#{application}/public" # or whatever path you want to copy it to | |
set :deploy_via, :remote_cache | |
set :port, 22 | |
set :scm, 'git' |
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 | |
# | |
# Script to prepare and restore full and incremental backups created with innobackupex-runner. | |
# | |
# This script is provided as-is; no liability can be accepted for use. | |
# | |
INNOBACKUPEX=innobackupex-1.5.1 | |
INNOBACKUPEXFULL=/usr/bin/$INNOBACKUPEX | |
TMPFILE="/tmp/innobackupex-restore.$$.tmp" |
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
" toggle Nerdtree and open the current folder | |
function! ToggleNerdTree() | |
if exists("t:NERDTreeBufName") && bufwinnr(t:NERDTreeBufName) != -1 | |
execute ":NERDTreeClose" | |
else | |
execute ":NERDTreeFind" | |
endif | |
endfunction | |
map <leader>w :call ToggleNerdTree()<CR> |
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 | |
use Symfony\Component\Translation\TranslatorInterface; | |
function format(\DateTime $date, TranslatorInterface $translator) | |
{ | |
$diff = date_create()->diff($date); | |
$seconds = $diff->days * 86400 + $diff->h * 3600 + $diff->i * 60 + $diff->s; | |
$format = $translator->transChoice('reldate', $seconds); |
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
require "rubygems" | |
require "sinatra" | |
require "json" | |
# Configure this with the directory path for the Web server's clone of the Git repo | |
git_dir = '/var/www/origin.git' | |
# Configure the mappings between Git branches and Web document roots | |
branch_to_working_directory = { | |
'www' => '/var/www/www.example.com', |
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
# Set cache dir | |
proxy_cache_path /var/cache/nginx levels=1:2 | |
keys_zone=microcache:5m max_size=1000m; | |
# Virtualhost/server configuration | |
server { | |
listen 80; | |
server_name yourhost.domain.com; | |
# Define cached location (may not be whole site) |
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 Clever\Presenter\CoreBundle\Assetic\Filter; | |
use Assetic\Filter\BaseCssFilter; | |
use Assetic\Asset\AssetInterface; | |
/** | |
* Fixes relative CSS urls. | |
* Support of Symfony relative bundles url |
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
Non working with : | |
if (class_exists("Sonata\AdminBundle\Admin\Admin")) { | |
$sonataAdmin = new Definition("Jm\ABBundle\Admin\TemplateAdmin", array( | |
null, | |
"Jm\ABBundle\Entity\Template", | |
"JmABBundle:TemplateAdmin", | |
)); | |
$sonataAdmin->addTag("sonata.admin", array( | |
'manager_type' => 'orm', | |
'group' => 'Site', |