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
@echo off | |
::where do we store the messages | |
SET mailpath=c:\xampp\tmp\mail\ | |
if not exist %mailpath% mkdir %mailpath% | |
::create filename | |
echo %date:~0,11% | |
SET filename=%date:~11,4%-%date:~7,2%-%date:~3,2%_%hours%-%time:~3,2%-%time:~6,2%_%time:~9,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
version: "3" | |
services: | |
apache: &apacheConfig | |
build: . | |
volumes: | |
- ./:/var/www/html:cached | |
- ./docker/php-apache/php.ini:/usr/local/etc/php/php.ini | |
- ./docker/php-apache/ssl-local:/etc/httpd/ssl | |
working_dir: /var/www/html | |
ports: |
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
; path to your php_xdebug extension file | |
; download from https://xdebug.org/wizard.php | |
zend_extension="c:\xampp-php7\php\ext\php_xdebug-2.4.0-7.0-vc14.dll" | |
; disables profiler globally | |
xdebug.profiler_enable = 0 | |
; allows enabling it selectively with request parameter "XDEBUG_PROFILE" | |
xdebug.profiler_enable_trigger = 1 | |
; directory to output profiler files to | |
xdebug.profiler_output_dir = "C:\xampp-php7\tmp" | |
; profiler file name (with request uri and timestamp) |
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
# based on https://susi.dev/dev-env-2020#5-use-systemd-hack-to-use-snap-optional-be-careful | |
# in windows | |
& 'C:\Program Files\VcXsrv\vcxsrv.exe' :0 -multiwindow -wgl -ac -silent-dup-error | |
# add firewall rule | |
netsh advfirewall firewall add rule name="XServer" dir=in program="C:\program files\vcxsrv\vcxsrv.exe" protocol=TCP localport=6000 action=allow profile=private remoteip=localsubnet | |
# in ubuntu | |
sudo apt-get update && sudo apt-get install -yqq daemonize dbus-user-session fontconfig |
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 | |
/* my day code */ | |
foreach ($minuteOfMyLife as $now => $whereAmI) { | |
if ($whereAmI == 'atHome') { | |
look_after_Honza(); | |
} elseif ($whereAmI == 'atWork') { | |
code(); | |
} else { | |
ride_my_bike(); | |
} |
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 | |
$tables_views = array_merge((array) $_POST["tables"], (array) $_POST["views"]); | |
if ($tables_views && !$error && !$_POST["search"]) { | |
$result = true; | |
$message = ""; | |
if ($jush == "sql" && $_POST["tables"] && count($_POST["tables"]) > 1 && ($_POST["drop"] || $_POST["truncate"] || $_POST["copy"])) { | |
queries("SET foreign_key_checks = 0"); // allows to truncate or drop several tables at once | |
} |
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 | |
# usage: rebase-to-moved.sh my-branch | |
# will create tag backup of current branch and rebase it on a moved directory | |
if [ -n "$(git status --porcelain)" ]; then | |
echo "You need to have clean working copy" | |
exit 1 | |
fi; | |
git checkout $1 |
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
Windows Registry Editor Version 5.00 | |
[HKEY_CLASSES_ROOT\Directory\shell\PHP Storm] | |
@="Open in &PHP Storm" | |
"icon"="\"C:\\bin\\PhpStorm.cmd\"" | |
[HKEY_CLASSES_ROOT\Directory\shell\PHP Storm\command] | |
@="\"C:\\bin\\PhpStorm.cmd\" \"%1\"" |
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
Required cygwin packages: | |
* tesseract-ocr | |
* ghostscript | |
* imagemagick | |
usr/bin/convert.exe -density 400 input.pdf -depth 8 output.tiff | |
tesseract -l eng -psm 1 output.tiff output_textfile |
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
{ | |
"repositories": [ | |
{ | |
"type": "path", | |
"url": "/path/to/project" | |
} | |
], | |
} |
NewerOlder