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
var Disclosure = function(el, options) { | |
el.isActive = false; | |
el.details = el.querySelectorAll('[data-details]'); | |
el.hide = function() { | |
for (var i = 0; i < el.details.length; i++) { | |
el.details[i].style.display = 'none'; | |
} | |
}; | |
el.show = function() { | |
for (var i = 0; i < el.details.length; i++) { |
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 App\Traits; | |
/** | |
* This Trait disabled the updated_at value for a model. | |
* Laravel doesn't provide an easy way to to this. | |
* The framework **alyways** tries to append the updated_at column | |
* when the `$timestamps` property is not set to false. | |
* See code here: https://github.com/illuminate/database/blob/5.4/Eloquent/Builder.php#L757-L760. |
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
exiftool -P -d '%Y-%m-%d' \ | |
'-filename<${FileModifyDate;}.%e' \ | |
'-filename<${GPSDateTime;}.%e' \ | |
'-filename<${MediaCreateDate;}.%e' \ | |
'-filename<${ModifyDate;}.%e' \ | |
'-filename<${DateTimeOriginal;}.%e' \ | |
"$1" |
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 | |
public function assertHasNotNullRecordForColumn($table, $column, $data = []) | |
{ | |
$result = \Illuminate\Support\Facades\DB::table($table) | |
->whereNotNull($column) | |
->where($data) | |
->count() > 0; | |
$message = sprintf( |
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
version: 2 | |
jobs: | |
php71: | |
docker: | |
- image: circleci/php:7.1 | |
steps: | |
- checkout | |
- composer install | |
- run: phpunit | |
php72: |
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 | |
return collect(Route::getRoutes()) | |
->reject(function ($item) { | |
return starts_with($item->uri, 'horizon'); | |
}) | |
->reject(function ($item) { | |
return starts_with($item->uri, 'nova'); | |
}) | |
->reject(function ($item) { |
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
on: push | |
name: Run phpunit testsuite | |
jobs: | |
phpunit: | |
runs-on: ubuntu-latest | |
# container: | |
# image: lorisleiva/laravel-docker:7.3 | |
steps: | |
- uses: actions/checkout@v1 |
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
name: Format PHP | |
on: | |
pull_request: | |
paths: | |
- '*.php' | |
jobs: | |
php-cs-fixer: | |
runs-on: ubuntu-latest |
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
let domains = Array.from($('.nav-item')[1].children[1].children); | |
let domainList = domains.map(function (item) { | |
return item.textContent.replace(/(\r\n|\n|\r)/gm, "").trim(); | |
}); | |
console.table(domainList); |
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
ssl_protocols SSLv2 SSLv3 TLSv1 TLSv1.2 TLSv1.3; | |
ssl_ciphers 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA'; |