Skip to content

Instantly share code, notes, and snippets.

View janbuecker's full-sized avatar

Jan Bücker janbuecker

View GitHub Profile
# j.buecker in ~/web/development on git:master ✖︎ [22:11:06]
→ vendor/bin/roave-no-leaks --configuration vendor/shopware/platform/phpunit.xml.dist
PHPUnit 8.0.4 by Sebastian Bergmann and contributors.
Random seed: 1553375476
Testing
............................................................. 61 / 5980 ( 1%)
............................................................. 122 / 5980 ( 2%)
............................................................. 183 / 5980 ( 3%)
@janbuecker
janbuecker / Dockerfile
Created August 27, 2018 10:35
Composer from multistage
FROM composer as composer
FROM php:7.2-fpm
COPY --from=composer /usr/bin/composer /usr/local/bin/composer
<?php
require 'vendor/autoload.php';
$ms = microtime(true);
$marshaler = new \Aws\DynamoDb\Marshaler();
$client = new \Aws\DynamoDb\DynamoDbClient([
'region' => 'eu-central-1',
'version' => 'latest',
'scheme' => 'http', // is recommended for lower latency because of SSL handshake
@janbuecker
janbuecker / file.php
Created August 14, 2017 06:14
Using Shopware outside of the project
<?php
require __DIR__ . '/../autoload.php';
$kernel = new \Shopware\Kernel('production', false);
$kernel->boot();
$kernel->getContainer();
// access the container
$kernel->getContainer()->get('...');
@janbuecker
janbuecker / compare_folders.sh
Created December 6, 2016 11:15
compare_folders.sh
// Usage: compare_folder <dir1> <dir2>
//
// Output:
//
// $ compare_folder dir1 dir2
//
// Changes in permissions
// drwxr-xr-x/update | drwxr-xr-x/update_original
// -rwxrwxr-x/console | -rw-r--r--/console
// -rwxrwxr-x/clear_cache.sh | -rw-r--r--/clear_cache.sh