Skip to content

Instantly share code, notes, and snippets.

View rodrigogiraoserrao's full-sized avatar
🐍

Rodrigo Girão Serrão rodrigogiraoserrao

🐍
View GitHub Profile
@SubOptimal
SubOptimal / README.md
Last active September 22, 2024 14:58
create perspective screenshot

On Twitter, Will McGuan posted a perspective screenshot.

This gist provides few basic steps, using ImageMagick, to produce some similar looking.

Following steps were processed.

  • starting with a screenshot of the Rich CLI help in a terminal

image

@dmfigol
dmfigol / asyncio_loop_in_thread.py
Last active November 14, 2024 08:52
Python asyncio event loop in a separate thread
"""
This gist shows how to run asyncio loop in a separate thread.
It could be useful if you want to mix sync and async code together.
Python 3.7+
"""
import asyncio
from datetime import datetime
from threading import Thread
from typing import Tuple, List, Iterable