Skip to content

Instantly share code, notes, and snippets.

View henryavila's full-sized avatar
💭
Knowledge is power

Henry Ávila henryavila

💭
Knowledge is power
View GitHub Profile
@Krato
Krato / Laravel Nova snippets.md
Last active November 25, 2020 23:02
A set of snippets I use in Laravel Nova

A set of snippets I use in Laravel Nova

Snippets

Vue,js devtools (Only with manual installation)

cd ./nova 
yarn
mv webpack.mix.js.dist webpack.mix.js
@ricardoaugusto
ricardoaugusto / customize-laravel-notification-email.md
Last active October 16, 2019 20:16
Customize Laravel 5.6 notification email
  1. Run php artisan make:notification MyResetPassword to create a Notification Class MyResetPassword at app/Notifications
  2. add use App\Notifications\MyResetPassword; to the User model
  3. Add this method to User model:
public function sendPasswordResetNotification($token)
{
    $this->notify(new MyResetPassword($token));
}
@Danga1963
Danga1963 / WRP IPTV.m3u
Last active February 28, 2025 13:38
WRP IPTV.m3u
#EXTM3U
#EXTINF:-1 tvg-id="" tvg-name="BigBrotherBrasil 2018" tvg-logo="http://bbb2018.net/wp-content/uploads/2017/08/bbb-2018.png" group-title="VARIEDADES",BigBrotherBrasil 2018
http://painel.iptvmove.com:25461/live/danga07/1963/1116.m3u8
#EXTINF:-1 tvg-id="" tvg-name="BigBrotherBrasil 2018 [Alter]" tvg-logo="http://bbb2018.net/wp-content/uploads/2017/08/bbb-2018.png" group-title="VARIEDADES",BigBrotherBrasil 2018 [Alter]
http://painel.iptvmove.com:25461/live/danga07/1963/3128.m3u8
#EXTINF:-1 tvg-id="A&E [Brazil]" tvg-name="A&E" tvg-logo="http://i.imgur.com/7NKeRuh.png" group-title="DOCUMENTARIOS",A&E
http://painel.iptvmove.com:25461/live/danga07/1963/1354.m3u8
#EXTINF:-1 tvg-id="" tvg-name="ALL Sports HD" tvg-logo="https://i0.wp.com/www.simpletvbrasil.tv/cliente/logo/4366c67d4d4be3381abe034e7c15b80e.png" group-title="CANAIS ESPORTE",ALL Sports HD
http://painel.iptvmove.com:25461/live/danga07/1963/1215.m3u8
#EXTINF:-1 tvg-id="" tvg-name="AMC" tvg-logo="http://i.imgur.com/JYislkb.png" group-title="FILMES/SERI
@joaorobertopb
joaorobertopb / .php_cs.dist
Last active December 17, 2022 15:37
Esse é um exemplo de configuração do php-cs-fixer que foi construído usando a predefinição Laravel do StyleCI.
<?php
$header = <<<'EOF'
Esse arquivo faz parte de <Empresa/Projeto>
(c) Nome Autor <e-mail>
Lorem ipsum ...
EOF;
@JordanDalton
JordanDalton / Employee.php
Created September 23, 2017 21:29
Here's an example of what do to if you desire to use Laravel's updateExistingPivot() while getting your attributes mutated through a pivot model.
<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
class Employee extends Model
{
/**
@dannygsmith
dannygsmith / valet-plus-destroy
Last active July 18, 2023 09:07
Remove valet-plus - reboot required
#!/usr/bin/env bash
#styles
VP_NONE='\033[00m'
VP_RED='\033[01;31m'
VP_GREEN='\033[01;32m'
VP_YELLOW='\033[01;33m'
VP_PURPLE='\033[01;35m'
VP_CYAN='\033[01;36m'
VP_WHITE='\033[01;37m'
@rafael-neri
rafael-neri / validar_cpf.php
Last active March 6, 2025 11:02
Validar CPF em PHP (Completo)
<?php
function validaCPF($cpf) {
// Extrai somente os números
$cpf = preg_replace( '/[^0-9]/is', '', $cpf );
// Verifica se foi informado todos os digitos corretamente
if (strlen($cpf) != 11) {
return false;
@cvan
cvan / HOWTO.md
Last active January 10, 2025 03:08
get all URLs of all network requests made on a web page from the Chrome Dev Tools (from an exported HAR)

Setup

Using Homebrew on Mac OS X:

brew install jq

Add these aliases to your profile (e.g., ~/.zshrc, ~/.bashrc, ~/.profile, etc.):

alias hurlp='pbpaste | jq ".log.entries" | tee >(jq --raw-output "[.[] | .request.url] | sort | unique | .[]")'

alias hurld='pbpaste | jq ".log.entries" | jq --raw-output "[.[] | .request.url] | sort | unique | .[]" | harurls | tee >(xargs -n 1 curl -O $1)'

@danb-humaan
danb-humaan / UuidModel.php
Created December 3, 2015 10:07
Trait for implementing UUIDs in Laravel models
<?php
namespace App\Traits;
use Rhumsaa\Uuid\Uuid;
use Illuminate\Database\Eloquent\ModelNotFoundException;
/**
* Trait UuidModel
* @package App\Traits
@JeffreyWay
JeffreyWay / .vimrc
Last active November 1, 2024 18:35
My .vimrc file
set nocompatible " Disable vi-compatibility
set t_Co=256
colorscheme xoria256
set guifont=menlo\ for\ powerline:h16
set guioptions-=T " Removes top toolbar
set guioptions-=r " Removes right hand scroll bar
set go-=L " Removes left hand scroll bar
set linespace=15