parse @message /Query_time: (?<queryTime>.*?) Lock_time: (<?lockTime>.*?) Rows_sent: (?<rowsSent>.*?) Rows_examined: (?<rowsExamined>.*?)\s(?<query>.*?)$/
| filter @message like /(?i)insert/
| sort queryTime desc
| limit 10
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"?> | |
<ruleset name="Laravel Standards"> | |
<description>The Laravel Coding Standards</description> | |
<rule ref="Generic.Classes.DuplicateClassName"/> | |
<rule ref="Generic.CodeAnalysis.EmptyStatement"/> | |
<rule ref="Generic.CodeAnalysis.ForLoopShouldBeWhileLoop"/> | |
<rule ref="Generic.CodeAnalysis.ForLoopWithTestFunctionCall"/> | |
<rule ref="Generic.CodeAnalysis.JumbledIncrementer"/> |
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 | |
STAGED_FILES=$(git diff --cached --name-only --diff-filter=ACM | grep ".php\{0,1\}$") | |
if [[ "$STAGED_FILES" = "" ]]; then | |
exit 0 | |
fi | |
PASS=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
<div id="demo"> | |
<input type="text" v-model="text"> text: {{text}} | |
<input type="file" v-model="file"> file: {{file}} | |
</div> | |
ar vue = new Vue({ | |
el: '#demo', | |
// default values |
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
$categories = [ | |
[ | |
'name' => 'cat1', | |
'children' => [ | |
[ | |
'name' => 'cat1', | |
'children' => [ | |
[ | |
'name'=>'subcat1', | |
'children'=> [] |
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
{ | |
"mobile_front_prime": { | |
"sizes": [ | |
[300, 250], | |
[320, 320], | |
[320, 160], | |
[320, 50], | |
"fluid" | |
], | |
"lazyLoad": false, |
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 | |
use App\Http\Traits\ActivityLog; | |
trait ActivityLog { | |
public function storeLog($message, $object) { | |
// Store $message and $object in database | |
SomeModel::create([ | |
'message' => $message, | |
'object_class' = get_class($object), | |
'user_id' => Auth::user()->id |
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
apply plugin: "com.android.application" | |
import com.android.build.OutputFile | |
/** | |
* The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets | |
* and bundleReleaseJsAndAssets). | |
* These basically call `react-native bundle` with the correct arguments during the Android build | |
* cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the | |
* bundle directly from the development server. Below you can see all the possible configurations |
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
# Commands to clean the local docker env | |
# Step1: stop all processes | |
docker stop $(docker ps -aq) | |
# Step2: remove all containers | |
docker rm $(docker ps -aq) | |
# Step3: remove all images | |
docker rmi $(docker images -aq) |