Skip to content

Instantly share code, notes, and snippets.

🐙
PLING

felipekm felipekm

🐙
PLING
Block or report user

Report or block felipekm

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@felipekm
felipekm / react-hook.js
Created Dec 2, 2019
The simplest React Hook
View react-hook.js
import React, { useState } from 'react';
function ComponentExample() {
const [ state, setState ] = useState({ counter:0 });
const addToCounter = () => {
const newCounterValue = state.counter + 1;
setState({ counter: newCounterValue });
}
View gist:ebe9823c99000fbaf5ed35dd62b11bff
import React, { useState } from 'react';
function Example() {
const [state, setState] = useState({counter:0});
const add1ToCounter = () => {
const newCounterValue = state.counter + 1;
setState({ counter: newCounterValue});
}
return (
@felipekm
felipekm / startec2.py
Created Nov 18, 2019
start ec2 instance python
View startec2.py
import boto3
# defines ec2
ec2 = boto3.resource('ec2')
# lambda handler
def lambda_handler(event, context):
# builds an array filter to get EC2 instances with TAG `LIGAR`
arrOffInstancesFilter = [
@felipekm
felipekm / readme.md
Last active Oct 30, 2019
readme.md boilerplate
View readme.md

Project name

GitHub repo size GitHub contributors GitHub stars GitHub forks Twitter Follow

Project name is a <utility/tool/feature> that allows <insert_target_audience> to do <action/task_it_does>.

View nginx_load_balancer.conf
http {
upstream api {
server api.example.com:5000;
server api.example.com:5001;
server api.example.com:5002;
}
server {
listen 80;
@felipekm
felipekm / protonmail-dark.css
Created Aug 22, 2019
Prontonmail Dark Theme
View protonmail-dark.css
@charset "UTF-8";/*!
* Custom Theme for ProtonMail v3.16.0
* http://amdelamar.com/pm-theme/
* SPDX-License-Identifier: MIT
*/:root{--theme1:#66669a;--theme2:#fefefe;--theme3:#222224;--theme4:#36384e;--theme5:#9397cd;--theme6:#48486c;--theme7:#35373e;--red:#cc9393;--red-light:#ec6446;--yellow:#dfdf19;--yellow-light:#e7d360;--green:#a6cc93;--green-light:#89bc70;--blue:#bce8f1;--blue-light:#93b9cc;--white:#FFF;--black:#000}#exiting{background-color:var(--theme3);color:var(--theme2)}#exiting .spinner.large .spinner1,#exiting .spinner.large .spinner2,#exiting .spinner.large .spinner3{background-color:var(--theme1)}.spinner.large .spinner1,.spinner.large .spinner2,.spinner.large .spinner3{background-color:var(--theme3)}.spinner1,.spinner2,.spinner3{background-color:var(--theme1)}.proton-embedded:after{background:url(/assets/img/icons/broken-img.png) 5px 50% no-repeat var(--theme3);border-color:var(--theme2) var(--theme4) var(--theme4) var(--theme2)}html.protonmail body{background:var(--theme2)}html.protonmail body.
@felipekm
felipekm / politica_restricoes_servico_EPP_registrobr.md
Last active Aug 20, 2019
Politica e restricoes do servico EPP no Registro.BR
View politica_restricoes_servico_EPP_registrobr.md

Politica e restricoes do servico EPP no Registro.BR - especificacoes tecnicas NICBR-EPP-2008-1

Aviso

Este documento descreve as mensagens e codigos de erro enviadas pelo servidor EPP do Registro.br para clientes EPP via o comando Poll, as restricoes de alguns campos do EPP para o servidor do Registro.br e codigos de erro e mensagens do servidor EPP do Registro.br.

Conteúdo

@felipekm
felipekm / remote_md
Created Jun 25, 2019
git - create local branch from existing remote branch
View remote_md
1. git remote add <remote_name> <repo_url>
2. git fetch <remote_name>
3. git checkout -b <new_branch_name> <remote_name>/<remote_branch_name>
@felipekm
felipekm / install_deps.sh
Created Jun 24, 2019
'npm install', getting node-gyp rebuild errors
View install_deps.sh
apt-get install build-essential libkrb5-dev -y
@felipekm
felipekm / github_emoji_codes.md
Created May 29, 2019
All Github emoji codes
View github_emoji_codes.md

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
You can’t perform that action at this time.