Skip to content

Instantly share code, notes, and snippets.

View eder-projetos-dev's full-sized avatar

Éder Luís Britto Garcia eder-projetos-dev

View GitHub Profile
@eder-projetos-dev
eder-projetos-dev / simple_sign_in_and_sign_out.py
Created May 17, 2023 19:28 — forked from daGrevis/simple_sign_in_and_sign_out.py
Python - Simple sign in and sign out in Python's Flask
from flask import Flask, session, escape, request, redirect, url_for
from os import urandom
app = Flask(__name__)
app.debug = True
app.secret_key = urandom(24)
@app.route('/')
@eder-projetos-dev
eder-projetos-dev / coinmarketcap-python.md
Last active March 4, 2023 20:47 — forked from SrNightmare09/coinmarketcap-api.md
Python - Using Coinmarketcap API

Using Coinmarketcap API with Python

This is a Gist for anyone looking to learn everything about retrieving cryptocurrency data from Coinmarketcap.com. A handful of information is provided here - Getting started, how to get the API key, what problems I faced, the API limitations and many others...

@eder-projetos-dev
eder-projetos-dev / test_html.py
Last active February 10, 2023 12:45 — forked from marcoscastro/test_html.py
Python - Gerando arquivo HTML5 com acentuação correta no Linux e no Windows
import datetime as dt
agora = dt.datetime.now()
data = agora.strftime("%d-%m-%Y")
hora = agora.strftime("%H:%M")
codigo_html = f'''
<!DOCTYPE html>
<html>
<head>
@eder-projetos-dev
eder-projetos-dev / exemplo_decorator.py
Last active February 26, 2023 21:07 — forked from marcoscastro/exemplo_decorator.py
Python - Exemplo simples de decorator
def maiuscula(funcao):
def wrapper(texto): # função que modifica
return funcao(texto.upper()) # transforma pra maiúscula
return wrapper # retorna a função modificadora
@maiuscula
def imprimir_mensagem(nome):
print(f"Olá {nome}, \nSeja bem vindo!")