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 | |
## display notification "Battery has disconnected with less than % battery" with title "Battery Alarm" | |
function debug() { | |
logger "$1" | |
echo "$1" | |
} | |
debug "CRONTAB | Battery Alarm Service Started" |
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 stop $(docker ps -aq) && \ | |
docker rm $(docker ps -aq) && \ | |
docker system prune -a && \ | |
docker volume rm $(docker volume ls -qf dangling=true) && \ | |
docker network prune |
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 file is part of Composer. | |
* | |
* (c) Nils Adermann <naderman@naderman.de> | |
* Jordi Boggiano <j.boggiano@seld.be> | |
* | |
* For the full copyright and license information, please view the LICENSE | |
* file that was distributed with this source code. |
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 | |
declare(strict_types=1); | |
use SysvSharedMemory; | |
class GracefulShutdown | |
{ | |
public const KEY = 666; |
The MockeryExpectations
trait provides a convenient method to assert Mockery expectations in PHPUnit tests. It is particularly useful when working with Mockery for mocking and stubbing objects.
To use the MockeryExpectations
trait in your PHPUnit test class, follow these steps:
- Include the trait in your test class:
This simple PHP command allows you to list all loaded PHP extensions along with their versions. It utilizes the ReflectionExtension
class to provide detailed information about each extension.
php -r '$all = get_loaded_extensions(); foreach($all as $i) { $ext = new ReflectionExtension($i); $ver = $ext->getVersion(); echo "$i - $ver" . PHP_EOL;}'
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 -d memory_limit=-1 vendor/bin/php-cs-fixer fix ./ --rules=native_function_invocation --allow-risky=yes | |
php -d memory_limit=-1 vendor/bin/php-cs-fixer fix ./vendor --rules=native_function_invocation --allow-risky=yes |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>JBZoo - Mermaid Graph</title> | |
<script src="https://code.jquery.com/jquery-3.4.1.slim.min.js"></script> | |
<script type="module"> | |
import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.esm.min.mjs'; | |
</script> | |
</head> |
NewerOlder