Fonte: https://www.fontsquirrel.com/fonts/vt323
$ pip install pillow python-slugify
$ python pybr_certs.py nomes.txt
Fork do https://github.com/GabrielRF/EstudeiEmHarvardBot
| export APYB_COFRE_PATH=/caminho/do/repositorio | |
| function apyb-pull() { | |
| # Obtém o caminho do repositório local da variável de ambiente | |
| local repo=${APYB_COFRE_PATH:?Erro: o caminho do repositório não foi definido na variável de ambiente APYB_COFRE_PATH} | |
| [[ -d "$repo" ]] || { echo "Erro: o caminho do repositório não existe."; return 1; } | |
| cd "$repo" | |
| # Verifica se há arquivos não commitados. Atenção para não perder dados em caso de conflito. | |
| [[ -z $(git status --porcelain) ]] || { echo "Erro: há arquivos não commitados no repositório local."; return 1; } |
| import sys | |
| import toml | |
| from slugify import slugify | |
| def load_config_file(): | |
| try: | |
| path = sys.argv[1] | |
| except IndexError: |
| import discord | |
| from discord.ext import commands | |
| from decouple import config | |
| DISCORD_TOKEN = config("DISCORD_TOKEN") | |
| bot = commands.Bot(command_prefix="pyne!", intents=discord.Intents.default()) |
| function cut_and_concat () | |
| { | |
| SOURCE=$PWD/$1 | |
| OUTPUT=$PWD/$2 | |
| OPENING=$PWD/$3 | |
| START_AT=$4 | |
| END_AT=$5 | |
| TIMESTAMP=$(date +"%Y%m%d%H%M%S") |
Fonte: https://www.fontsquirrel.com/fonts/vt323
$ pip install pillow python-slugify
$ python pybr_certs.py nomes.txt
Fork do https://github.com/GabrielRF/EstudeiEmHarvardBot
| import asyncio | |
| import sys | |
| from pathlib import Path | |
| import discord | |
| from PIL import Image | |
| def gerar_imagem(): | |
| imagens = [ |
| # Código usado na palestra "Async que se faz - asyncio na prática" | |
| # no TDC 2018 em Florianópolis | |
| # Creative Commons Attribution 4.0 International license <https://creativecommons.org/licenses/by/4.0/> | |
| import asyncio | |
| import random | |
| from time import sleep | |
| from utils import UPDATE_AVG, async_request, timeit |
| # Código usado na palestra "Async que se faz - asyncio na prática" | |
| # no TDC 2018 em Florianópolis | |
| # Creative Commons Attribution 4.0 International license <https://creativecommons.org/licenses/by/4.0/> | |
| # requirements: termcolor | |
| import random | |
| import asyncio | |
| from asyncio import sleep as async_sleep | |
| from time import time, sleep as sync_sleep |
| # Código usado na palestra "Async que se faz - asyncio na prática" | |
| # no TDC 2018 em Florianópolis | |
| # Creative Commons Attribution 4.0 International license <https://creativecommons.org/licenses/by/4.0/> | |
| import random | |
| from time import sleep | |
| from utils import UPDATE_AVG, sync_request |
| def hello_world(): | |
| print('hello world') | |
| hello_world() | |
| if __name__ == '__main__': | |
| print('dentro do if') | |
| hello_world() |