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 August 27, 2024 06:23
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 September 5, 2024 18:28
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