This file contains 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/php -q | |
<?php | |
// declaring some vars | |
(!empty($argv[1])) ? $inputFile = $argv[1] : exit('no input file given as parameter' . PHP_EOL); | |
date_default_timezone_set("Europe/Brussels"); | |
$selection = false; | |
$method = false; | |
$fh = fopen('php://stdin', 'r'); |
This file contains 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"?> | |
<locale> | |
<frontend> | |
<core> | |
</core> | |
</frontend> | |
<backend> | |
<core> |
This file contains 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 | |
/** | |
* This is the FE -Module -Detail action + form Gist | |
* sublime hooks : -Module -Detail | |
* | |
* | |
* @author Thijs De Paepe <[email protected]> | |
* | |
*/ |
This file contains 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
### Aliases | |
# Open specified files in Sublime Text | |
# "s ." will open the current directory in Sublime | |
alias s='open -a "Sublime Text"' | |
# Color LS | |
colorflag="-G" | |
alias ls="command ls ${colorflag}" | |
alias l="ls -lF ${colorflag}" # all files, in long format |
This file contains 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
server { | |
listen 8888; ## listen for ipv4; this line is default and implied | |
root /var/www/blog_test/web; | |
index index.php; | |
#site root is redirected to the app boot script | |
location = / { | |
try_files @site @site; | |
} |
This file contains 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 | |
NETRC=~/.netrc.transmission | |
TR="transmission-remote -N $NETRC" # command + authentication | |
FILE="lastrunning.list" | |
# accepts arguments -sleep -wake | |
if [ -z "$1" ]; then | |
echo usage: $0 -sleep or -wake | |
exit |
This file contains 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 | |
# | |
# This script will remove everything and pull in the new version | |
# | |
# @version 1.0.0 | |
# @author <[email protected]> | |
# mySQL settings | |
user=$1 | |
password=$2 |
This file contains 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
## | |
# Opcache recipe | |
# => convenience rules for dealing with opcode cache in PHP5.5+ applications using opcache (Zend Optimizer+) | |
## | |
_cset(:opcache_webroot) { "" } | |
namespace :opcache do | |
desc <<-DESC | |
Create a temporary PHP file to clear cache, call it (using curl) and removes it |
This file contains 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 | |
# | |
# This script will export a module out of fork | |
# | |
# @version 1.0.0 | |
# @author <[email protected]> | |
if [ $# -eq 0 ] | |
then | |
echo "please supply a module name" |
This file contains 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
// create a date | |
$this->frm->addDate('date', $this->record['date']); | |
// convert date with mysql | |
$date = \DateTime::createFromFormat('d/m/Y', $fields['date']->getValue()); | |
$item['date'] = $date->format('Y-m-d').' 00:00:00'; |
OlderNewer