Skip to content

Instantly share code, notes, and snippets.

View patrickmaciel's full-sized avatar
🙏
Jesus is coming!

Patrick Maciel patrickmaciel

🙏
Jesus is coming!
View GitHub Profile
@ibrunotome
ibrunotome / laravel-ddd-approach.md
Last active August 25, 2023 23:25
A Domain Driven Design (DDD) approach to the Laravel Framework
/app
├── /Application
|  ├── /Exceptions
|  ├── /Middlewares
|  ├── /Providers
|  ├── /Requests
├── /Domain
|  ├── /MyDomainA
| | ├── /Contracts
@noelbundick
noelbundick / LICENSE
Last active March 30, 2025 13:12
Exclude WSL installations from Windows Defender realtime protection
MIT License
Copyright (c) 2018 Noel Bundick
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
"controller_mappings"
{
"version" "3"
"title" "GW2 Total Control by CoryOp v1"
"description" "#SettingsController_AutosaveDescription"
"creator" "76561198141443709"
"controller_type" "controller_steamcontroller_gordon"
"group"
{
"id" "0"
@patrickmaciel
patrickmaciel / index.php
Last active December 20, 2018 11:18
Compare arrays multidimensional #php
<?php
function array_diff_assoc_recursive($array1, $array2) {
$difference=array();
foreach($array1 as $key => $value) {
if( is_array($value) ) {
if( !isset($array2[$key]) || !is_array($array2[$key]) ) {
$difference[$key] = $value;
} else {
$new_diff = array_diff_assoc_recursive($value, $array2[$key]);
@vluzrmos
vluzrmos / phpstorm.cmder.md
Last active September 13, 2021 03:30
Configurar o Laragon CMDER dentro do PHPSTORM

1- Adicionar a variável de ambiente CMDER_ROOT com o caminho para C:\laragon\bin\cmder (local do cmder no computador)

2- Abrir o phpstorm, ir em File (Menu) > Settings > Tools > Terminal e alterar o caminho padrão "cmd.exe" para:

"cmd.exe" /k ""%CMDER_ROOT%\vendor\init.bat""

3- Pode acontecer de a variável CMDER_ROOT não estar pronta, você pode precisar reiniciar sua máquina.

@skynet
skynet / upgrade-php7.sh
Created December 29, 2018 03:52 — forked from heathdutton/upgrade-php7.sh
Upgrade PHP to 7.3 on Amazon Linux (specifically for Elastic Beanstalk but should work elsewhere)
#!/usr/bin/env bash
# Upgrade an Amazon Linux EC2 to PHP 7.3
#
# Last tested w/ PHP 7.2 AWS Linux version 2.8.5
#
# Must be ran as sudo:
# sudo bash upgrade-php7.sh
#
# Can be added to ./.ebextensions/20_php.config like so:
# container_commands:

Live Reload (Lavarel no VSCode → Chrome)

Isso permite que a aba com o laravel no navegador seja automaticamente atualizada a cada arquivo modificado no projeto. Ou seja, cada vez que você editar um arquivo no Visual Code, ao salvar esse arquivo o resultado será refletido automaticamente na aba do chrome.

Instale os seguintes itens

Configuração no Google Chrome

@andrebrait
andrebrait / keychron_linux.md
Last active May 9, 2025 03:09
Keychron keyboards on Linux + Bluetooth fixes

Here is the best setup (I think so :D) for K-series Keychron keyboards on Linux.

Note: many newer Keychron keyboards use QMK as firmware and most tips here do not apply to them. Maybe the ones related to Bluetooth can be useful, but everything related to Apple's keyboard module (hid_apple) on Linux, won't work. As far as I know, all QMK-based boards use the hid_generic module instead. Examples of QMK-based boards are: Q, Q-Pro, V, K-Pro, etc.

Most of these commands have been tested on Ubuntu 20.04 and should also work on most Debian-based distributions. If a command happens not to work for you, take a look in the comment section.

Make Fn + F-keys work (NOT FOR QMK-BASED BOARDS)

Older Keychron keyboards (those not based on QMK) use the hid_apple driver on Linux, even in the Windows/Android mode, both in Bluetooth and Wired modes.

@the-codinator
the-codinator / bash-stuff.sh
Last active September 25, 2023 18:37
Some good to have configs for bash (or zsh) for your terminal
###################
##### SOURCES #####
###################
##### Aliases #####
## Git
export GH_HOST=github.com
function clone { [[ -z "$1" ]] && echo "Error: Missing repo name parameter" && return 2; local git_org=$(basename $(pwd)); echo "Cloning [$git_org/$1] ..."; git clone "git@$GH_HOST:$git_org/$1.git"; }
@patrickmaciel
patrickmaciel / configuracoes.md
Created April 18, 2021 00:30
Laragon + Mailhog