masto-bridges/masto_git_bridge/main.py

11 lines
281 B
Python
Raw Normal View History

2022-11-08 03:13:35 +00:00
from typing import Optional
from masto_git_bridge.config import Config
from masto_git_bridge.repo import Repo
def post_last_commit(config:Optional[Config]=None):
if config is None:
config = Config()
repo = Repo(config.GIT_REPO)
last_commit = repo.last_commit