Skip to content

Instantly share code, notes, and snippets.

View paramonovav's full-sized avatar
🏠
Working from home

Anton Paramonov paramonovav

🏠
Working from home
View GitHub Profile
@DarkGhostHunter
DarkGhostHunter / mago.toml
Created April 18, 2026 01:02
Mago configurationg for Laravel Projects
version = "1"
php-version = "8.5.0"
[source]
workspace = "."
paths = ["src/"]
includes = ["vendor/"]
excludes = []
[source.glob]
@nikspyratos
nikspyratos / mago.toml
Created February 6, 2026 19:57
Mago Pint parity
[formatter]
preset = "pint"
space-after-logical-not-unary-prefix-operator=true
space-within-grouping-parenthesis=false
inline-empty-control-braces=true
inline-empty-closure-braces=true
inline-empty-function-braces=true
inline-empty-method-braces=true
inline-empty-constructor-braces=true
inline-empty-classlike-braces=true
@eusonlito
eusonlito / 01-README.md
Last active September 18, 2026 17:03
SQLite optimization for Laravel

The SQLite optimizations must be carried out at two different times: once in a unique and permanent way for the database and another time for each connection that is made. Below are the configurations that should be made in each case.

Unique and Permanent Configurations

These configurations are set only once and affect the database persistently, meaning they do not need to be reconfigured each time a connection is established:

PRAGMA journal_mode = WAL;

Sets the database journal mode to "WAL" (Write-Ahead Logging), which improves performance in concurrent operations.

@lotyp
lotyp / README.md
Created April 23, 2024 15:03
PHPStan Level Badges

PHPStan Level 0 PHPStan Level 1 PHPStan Level 2 PHPStan Level 3 PHPStan Level 4 PHPStan Level 5 PHPStan Level 6 PHPStan Level 7 PHPStan Level 8 ![PHPStan

@paramonovav
paramonovav / !Как установить сфинкс.md
Created September 8, 2023 17:44 — forked from codedokode/!Как установить сфинкс.md
Как установить и настроить сфинкс.

Как установить и настроить сфинкс.

Скачиваем сфинкс (берем версию с MySQL и со стеммингом на 15 языков Win32 binaries w/MySQL+PgSQL+libstemmer+id64 support соответствующую битности твоей ОС), распаковываем например в d:\temp\s\

На этом установка sphinx завершена. В дебиане просто делаем sudo apt-get install sphinxsearch.

Создаем таблицы:

CREATE TABLE news 

(id INT(10) AUTO_INCREMENT PRIMARY KEY, topic INT(10) NOT NULL, header VARCHAR(200) NOT NULL,

@voronkovich
voronkovich / MacOS-MAMP-MailHog.md
Last active September 15, 2024 12:13
Установка MailHog для MAMP (MacOS)

Установка MailHog для MAMP (MacOS)

  1. Установить и запустить MailHog

     brew install mailhog
     brew services start mailhog
  2. Добавить настройки в файл /Applications/MAMP/bin/php/{PHP_VERSION}/conf/php.ini

@valorin
valorin / .env.example
Last active September 15, 2025 07:05
CSP Middleware - the simple CSP middleware I use across all of my projects.
# Add to your .env.example and .env files
CSP_ENABLED=true
CSP_REPORT_ONLY=true
@paramonovav
paramonovav / gist:0216ffc5dad470f1d54ea9b860ef9c66
Last active July 21, 2020 21:52
Оптимизация загрузчика Composer

Уровень 1: Генерация карты классов Как?

Есть несколько способов это сделать:

Добавить "optimize-autoloader": true в ваш composer.json; Выполнить install или update с флагом -o или --optimize-autoloader; Выполнить dump-autoload с флагом -o или --optimize; Что произойдет?

@arthursalvtr
arthursalvtr / add-custom-mail-driver-to-laravel.md
Last active July 11, 2025 08:01
Add Custom Mail Driver to Laravel

How to add custom Mail Driver to Laravel

Tested on Laravel 5.8

Within the source code of laravel 5.8 at this time of writing, we have this following

<?php

namespace Illuminate\Support;
@laravel-shift
laravel-shift / .php-cs-fixer.php
Last active August 7, 2026 09:17
PHP CS Fixer - Laravel Coding Style Ruleset
<?php
use PhpCsFixer\Config;
use PhpCsFixer\Finder;
$rules = [
'array_indentation' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => [
'default' => 'single_space',