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
# clone sorce repo | |
git clone git://example.com/${sorce_repo}.git && cd ${sorce_repo} | |
# delete remote | |
git remote rm origin | |
# remove all unnecessary files and directories | |
git rm -r ... | |
# if you need to move directories just move them now |
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 | |
search="$1" | |
replace="$2" | |
target_dir="$3" | |
[ -n "$search" ] || \ | |
{ echo "search is empty"; exit 1; } | |
[ -n "$replace" ] || \ | |
{ echo "replace is empty"; exit 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
sqlplus64 user/pass@//host/db |
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
Ctrl + a – go to the start of the command line | |
Ctrl + e – go to the end of the command line | |
Ctrl + k – delete from cursor to the end of the command line | |
Ctrl + u – delete from cursor to the start of the command line | |
Ctrl + w – delete from cursor to start of word (i.e. delete backwards one word) | |
Ctrl + y – paste word or text that was cut using one of the deletion shortcuts (such as the one above) after the cursor | |
Ctrl + xx – move between start of command line and current cursor position (and back again) | |
Alt + b – move backward one word (or go to start of word the cursor is currently on) | |
Alt + f – move forward one word (or go to end of word the cursor is currently on) | |
Alt + d – delete to end of word starting at cursor (whole word if cursor is at the beginning of word) |
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
Show hidden characters
{ | |
"phpcs_php_path": "/usr/bin/php", | |
"phpcs_executable_path": "/usr/bin/phpcs", | |
"phpmd_executable_path": "/usr/bin/phpmd", | |
"php_cs_fixer_executable_path": "/usr/local/bin/php-cs-fixer", | |
"php_cs_fixer_on_save": true | |
} |
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
RewriteEngine On | |
RewriteRule ^/servicestatus$ /servicestatus.php [L] | |
RewriteCond %{REQUEST_FILENAME} -s [OR] | |
RewriteCond %{REQUEST_FILENAME} -l [OR] | |
RewriteCond %{REQUEST_FILENAME} -d | |
RewriteRule ^.*$ - [NC,L] | |
RewriteRule ^.*$ index.php [NC,L] |
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
RewriteCond %{THE_REQUEST} ^GET\ /elb-health-check [NC] | |
RewriteRule ^ - [R=200] | |
RewriteCond %{THE_REQUEST} ^GET\ /route53-health-check [NC] | |
RewriteRule ^ - [R=200] |
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
docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' container-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
<?php | |
namespace Controller; | |
use Symfony\Component\HttpFoundation\Request; | |
class FooController | |
{ | |
public function doSomething(Request $request, AwesomeService $service) | |
{ |
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 | |
public function createCollection(QueryBuilder $qb, array $args, Callable $createLinkFunc) | |
{ | |
// ... | |
$pager = new Pagerfanta(new DoctrineORMAdapter($qb)); | |
} |
OlderNewer