Skip to content

Instantly share code, notes, and snippets.

View pedromazala's full-sized avatar
🥋

Pedro Mázala pedromazala

🥋
View GitHub Profile
@pedromazala
pedromazala / Program.cs
Last active March 8, 2019 13:03
EngZap Example C# .Net
using System;
using System.Collections.Generic;
using System.IO;
using System.Net.Http;
using System.Net.Http.Headers;
namespace TetsteCSharp
class Program
{
static void Main(string[] args)
@geovanisouza92
geovanisouza92 / builder.ts
Last active April 3, 2019 11:49
A builder type where build() only appears after correct initalization
interface Buildable<T> {
build(): T;
}
type HasSawThickness = { sawThickness: number };
type HasDirection = { direction: "horizontal" | "vertical" };
type HasWidth = { width: number };
type HasHeight = { height: number };
type HasPhase = { phase: number };
@chadrien
chadrien / README.md
Last active August 24, 2025 21:28
Debug PHP in Docker with PHPStorm and Xdebug

Debug your PHP in Docker with Intellij/PHPStorm and Xdebug

  1. For your local dev, create a Dockerfile that is based on your production image and simply install xdebug into it. Exemple:
FROM php:5

RUN yes | pecl install xdebug \
&amp;&amp; echo "zend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)" &gt; /usr/local/etc/php/conf.d/xdebug.ini \
@ricardobarantini
ricardobarantini / estados.php
Last active April 9, 2025 22:54
Array com nome e siglas de estados Brasileiros para select do Codeigniter
$estadosBrasileiros = array(
'AC'=>'Acre',
'AL'=>'Alagoas',
'AP'=>'Amapá',
'AM'=>'Amazonas',
'BA'=>'Bahia',
'CE'=>'Ceará',
'DF'=>'Distrito Federal',
'ES'=>'Espírito Santo',
'GO'=>'Goiás',