Commit graph

60 commits

Author SHA1 Message Date
Paul Gauthier
f8f2eb0f76 aider: Filtered out image links from long_description in setup.py.
# Context:
USER: pypi descriptions don't support markdown image links. filter out images before passing it
ASSISTANT: To filter out image links from the `long_description` in `setup.py`, you can use a regular expression to remove the lines containing image links. Here's the change you need to make in `setup.py`:

```python
setup.py
<<<<<<< ORIGINAL
with open("README.md", "r", encoding="utf-8") as f:
    long_description = f.read()
=======
import re

with open("README.md", "r", encoding="utf-8") as f:
    long_description = f.read()
    long_description = re.sub(r'\n!\[.*\]\(.*\)', '', long_description)
>>>>>>> UPDATED
```

This change imports the `re` module and uses the `re.sub()` function to remove lines containing image links from the `long_description`.
2023-06-07 16:59:35 -07:00
Paul Gauthier
ece1cdd557 aider: Updated the setup.py to use the README.md as the long description source.
# Context:
USER: update the `setup.py` to use README.md as the long description source
ASSISTANT: To update the `setup.py` to use the `README.md` as the long description source, follow these steps:

1. Read the contents of the `README.md` file and store it in a variable.
2. Add the `long_description` and `long_description_content_type` arguments to the `setup()` function.

Here's the updated `setup.py`:

```python
setup.py
<<<<<<< ORIGINAL
from setuptools import find_packages, setup

with open("requirements.txt") as f:
    requirements = f.read().splitlines()

setup(
    name="aider-chat",
    version="0.5.0",
    packages=find_packages(),
    install_requires=requirements,
    entry_points={
        "console_scripts": [
            "aider = aider.main:main",
        ],
    },
)
=======
from setuptools import find_packages, setup

with open("requirements.txt") as f:
    requirements = f.read().splitlines()

with open("README.md", "r", encoding="utf-8") as f:
    long_description = f.read()

setup(
    name="aider-chat",
    version="0.5.0",
    packages=find_packages(),
    install_requires=requirements,
    entry_points={
        "console_scripts": [
            "aider = aider.main:main",
        ],
    },
    long_description=long_description,
    long_description_content_type="text/markdown",
)
>>>>>>> UPDATED
```
2023-06-07 16:56:24 -07:00
Paul Gauthier
d65e782e80 Changed package name aider -> aider-chat 2023-06-07 16:43:46 -07:00
Paul Gauthier
85a14309ca bump version 2023-06-07 13:53:04 -07:00
Paul Gauthier
92cd2f3ce6 isort 2023-05-28 22:47:38 -07:00
Paul Gauthier
61c0892f58 bumped version 2023-05-25 08:28:57 -07:00
Paul Gauthier
981710ca16 Bumped version to 0.3.0 in setup.py. 2023-05-13 09:44:22 -07:00
Paul Gauthier
5490dc11d0 Updated version number to 0.2.0 in setup.py. 2023-05-11 23:26:22 -07:00
Paul Gauthier
2333e62b6a Add setup.py file that reads requirements.txt for dependencies and sets up CLI script.
# Context:
USER: make a setup.py for this project. it includes a cli script in main(). have setup.py read requirements.txt to get the install_requires
ASSISTANT: To create a `setup.py` file for this project, we'll use the `setuptools` package. We'll also read the `requirements.txt` file to get the `install_requires` dependencies. Here's the change:

```python
setup.py
<<<<<<< ORIGINAL

=======
from setuptools import setup, find_packages

with open("requirements.txt") as f:
    requirements = f.read().splitlines()

setup(
    name="aider",
    version="0.1.0",
    packages=find_packages(),
    install_requires=requirements,
    entry_points={
        "console_scripts": [
            "aider = aider.main:main",
        ],
    },
)
>>>>>>> UPDATED
```

This will create a `setup.py` file that reads the `requirements.txt` file for dependencies and sets up the CLI script for the `main()` function in `aider.main`.
2023-05-09 10:57:56 -07:00
Paul Gauthier
e32fb7c033 Initial commit: Added new files to the git repo: setup.py 2023-05-09 10:56:14 -07:00