Skip to content

Instantly share code, notes, and snippets.

@marcuspmd
marcuspmd / doc.api
Created January 19, 2021 16:23
doc.api
/**
* @api {GET} /cep/{cep} 1 - Consultar Cep
* @apiHeader {String} Token Autenticação via token.
* @apiName Consulta
* @apiVersion 1.0.0
* @apiGroup Cep
*
*
* @apiParam (Consulta) {String{11}} cep Cep para buscar o endereço, sem nenhuma formatação.
* @apiSampleRequest https://link/api/cep/
@marcuspmd
marcuspmd / git-update-fork.sh
Created July 24, 2017 23:17 — forked from rdeavila/git-update-fork.sh
Git: como atualizar um fork com as mudanças do original?
#!/bin/bash
# Adicione um novo remote; pode chamá-lo de "upstream":
git remote add upstream https://github.com/usuario/projeto.git
# Obtenha todos os branches deste novo remote,
# como o upstream/master por exemplo:
git fetch upstream
@marcuspmd
marcuspmd / robot.js
Created December 7, 2012 13:58
MarcusP
var Robot = function(robot){
robot.turnLeft(robot.angle % 90);
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
if (robot.parentId) {
robot.ahead(1);
robot.turnGunRight(1);
}
else {