-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
22 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
# Helpers | ||
from . import utils, db | ||
from .db import DBConnection | ||
# API Interaction/Wrapper Classes | ||
from .instapost import InstaPost | ||
from .instapage import InstaPage, InstaUser, Hashtag | ||
from .instaclient import InstaClient, USER_AGENT | ||
from .tweetclient import TweetClient | ||
# User Interface Classes | ||
from .profile import Profile | ||
from .instatweet import InstaTweet | ||
|
||
__version__ = "v2.2.0" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
import os | ||
import re | ||
from pathlib import Path | ||
from setuptools import setup | ||
|
||
|
||
LONG_DESCRIPTION_SRC = 'README_PyPi.rst' | ||
|
||
|
||
|
@@ -11,27 +10,21 @@ def read(file): | |
return f.read() | ||
|
||
|
||
def get_pypi_desc(rst_file=LONG_DESCRIPTION_SRC): | ||
rst = read(rst_file) | ||
# Replace the "From the Docs..." rst admonition with a screenshot of it | ||
docs_admonition_regex = r'.. admonition:: From the Docs\.\.\.[\w\W]+https.+\n{3}' | ||
docs_admonition_img = ".. image:: {}".format( | ||
"https://user-images.githubusercontent.com/96394652/187158617-f45761ab-3aa9-472f-a6fb-a99cd0ce900c.png\n\n\n" | ||
) | ||
return re.sub( | ||
pattern=docs_admonition_regex, | ||
repl=docs_admonition_img, | ||
string=rst | ||
) | ||
# Parse version | ||
init = Path(__file__).parent.joinpath("InstaTweet", "__init__.py") | ||
for line in init.read_text().split("\n"): | ||
if line.startswith("__version__ ="): | ||
break | ||
version = line.split(" = ")[-1].strip('"') | ||
|
||
|
||
setup( | ||
name='insta-tweet', | ||
packages=['InstaTweet'], | ||
version='2.1.3', | ||
version=version, | ||
license='MIT', | ||
description='Automatically Repost Content From Instagram to Twitter', | ||
long_description=get_pypi_desc(LONG_DESCRIPTION_SRC), | ||
long_description=read(LONG_DESCRIPTION_SRC), | ||
long_description_content_type="text/x-rst; charset=UTF-8", | ||
author='Adam Korn', | ||
author_email='[email protected]', | ||
|