Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix package structure #5

Merged
merged 3 commits into from
Oct 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM python:3-alpine
WORKDIR /app

COPY requirements.txt /app/requirements.txt
COPY ./hype /app
COPY ./hype /app/hype

RUN pip install -r requirements.txt

Expand All @@ -14,4 +14,4 @@ RUN mkdir -p /app/secrets/

COPY ./config/* /app/config/

ENTRYPOINT ["python", "/app/main.py"]
ENTRYPOINT ["python", "-m", "hype"]
File renamed without changes.
7 changes: 7 additions & 0 deletions hype/__main__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from .config import Config
from .hype import Hype

bot = Hype(Config())
bot.login()
bot.update_profile()
bot.start()
3 changes: 2 additions & 1 deletion hype/config.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import logging
from typing import List

import yaml
import logging


class BotAccount:
Expand Down
8 changes: 5 additions & 3 deletions hype/hype.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
import logging
import os.path
import time

import schedule
import logging
from mastodon import Mastodon
from config import Config
import os.path

from .config import Config


class Hype:
Expand Down
7 changes: 0 additions & 7 deletions hype/main.py

This file was deleted.