Skip to content

Instantly share code, notes, and snippets.

View wadson-pereira's full-sized avatar
🏠
Working from home

Wadson wadson-pereira

🏠
Working from home
View GitHub Profile
@wadson-pereira
wadson-pereira / nginx.conf
Created August 8, 2024 01:17 — forked from weapp/nginx.conf
Return common errors as json in Nginx
error_page 500 /500.html;
location /500.html{
return 500 '{"error": {"status_code": 500,"status": "Internal Server Error"}}';
}
error_page 502 /502.html;
location /502.html{
return 502 '{"error": {"status_code": 502,"status": "Bad Gateway"}}';
}
@wadson-pereira
wadson-pereira / teste-foda.md
Created June 5, 2024 01:49 — forked from danielhe4rt/teste-foda.md
Teste Técnico: Crie seu Discord!

Teste Tecnico: Desenvolvimento de uma Aplicação de Chat em Tempo Real com PHP e Laravel (ou qualquer outra lang)

Introdução

Neste desafio, você será responsável por desenvolver uma aplicação de chat em tempo real utilizando PHP e o framework Laravel. A aplicação deve oferecer funcionalidades básicas similares às encontradas em plataformas de chat como o Discord. O foco principal é a criação de um backend robusto e escalável, utilizando as abstrações e boas práticas do Laravel.

Requisitos do Projeto

Funcionalidades Principais

@wadson-pereira
wadson-pereira / gist:fd32c4b6315f93377968bafdc424dc70
Created March 26, 2021 12:21 — forked from jesseobrien/gist:7418983
Bind parameters into the SQL query for Laravel ORM
<?php
class MyModel extends Eloquent {
public function getSql()
{
$builder = $this->getBuilder();
$sql = $builder->toSql();
foreach($builder->getBindings() as $binding)
{
@wadson-pereira
wadson-pereira / installing-node-with-nvm.md
Created August 12, 2020 18:57 — forked from d2s/installing-node-with-nvm.md
Installing Node.js to Linux & macOS & WSL with nvm

Installing Node.js with nvm to Linux & macOS & WSL

A quick guide on how to setup Node.js development environment.

Install nvm for managing Node.js versions

nvm allows installing several versions of Node.js to the same system. Sometimes applications require a certain versions of Node.js to work. Having the flexibility of using specific versions can help.

  1. Open new Terminal window.
" Specify a directory for plugins
call plug#begin('~/.vim/plugged')
Plug 'neoclide/coc.nvim', {'branch': 'release'}
Plug 'scrooloose/nerdtree'
"Plug 'tsony-tsonev/nerdtree-git-plugin'
Plug 'Xuyuanp/nerdtree-git-plugin'
Plug 'tiagofumo/vim-nerdtree-syntax-highlight'
Plug 'ryanoasis/vim-devicons'
Plug 'airblade/vim-gitgutter'
{
"suggest.noselect": false,
"coc.preferences.formatOnSaveFiletypes": [
"javascript",
"typescript",
"typescriptreact",
"json",
"javascriptreact",
"typescript.tsx",
"graphql"
{
"suggest.noselect": false,
"coc.preferences.formatOnSaveFiletypes": [
"javascript",
"typescript",
"typescriptreact",
"json",
"javascriptreact",
"typescript.tsx",
"graphql"

#Introduction If you're a php developer on ubuntu, there comes the time where you have to install/reinstall your system. I did it already a few times and i decided to write down the steps for a typical web developer stack with php. This is for a developer machine and not for a live environment!

I hope it helps you too!

fyi @mheiniger and me started with an installer here: https://github.com/mheiniger/webdev-setup

https://dl.acm.org/citation.cfm?id=3136876 (criptografia)
@wadson-pereira
wadson-pereira / Emissores.txt
Last active January 24, 2018 02:42
Órgãos Emissores de RG
ABNC – Academia Brasileira de Neurocirurgia
CGPI/DUREX/DPF – Coordenação Geral de Polícia de Imigração da Polícia Federal
CGPI – Coordenação-Geral de Privilégios e Imunidades
CGPMAF – Coordenadoria Geral de Polícia Marítima, Aeronáutica e de Fronteiras
CNIG – Conselho Nacional de Imigração
CNT - Carteira Nacional de Habilitação
COREN – Conselho Regional de Enfermagem
CORECON - Conselho Regional de Economia
CRA – Conselho Regional de Administração
CRAS – Conselho Regional de Assistentes Sociais