Skip to content

Commit 83b8824

Browse files
committed
Modernize
- Remove gui because PySide only worked on 3.4. - Pin specific versions of dependencies. - Restructure folders. - Replace optparse with argparse. - Add type hints. - Add more explanation in comments. - Use namedtuples for readability. - Added different images. - Use the black linter.
1 parent 2453b06 commit 83b8824

File tree

14 files changed

+291
-649
lines changed

14 files changed

+291
-649
lines changed

Media/after.jpg

2.18 KB
Loading

Media/before.jpg

9.47 KB
Loading

Media/density.jpg

8.84 KB
Loading

Media/terminal.jpg

-346 KB
Loading

README.md

Lines changed: 17 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2,52 +2,42 @@
22

33
Makin some pictures
44

5-
Ascii py requires the use of Python 3.3 or greater because of [an addition made to the shutil ibrary](https://docs.python.org/3/library/shutil.html#querying-the-size-of-the-output-terminal).
6-
75
Install instructions
86
---
97

10-
Using pip:
8+
Using pip
9+
---
1110

12-
`python3 -m pip install ascii_py`
11+
```
12+
python3 -m pip install ascii_py
13+
```
1314

14-
Manually:
15+
From source
16+
---
1517

1618
```
1719
git clone https://github.com/profoak/ascii_py
1820
cd ascii_py
1921
python3 setup.py install
2022
```
2123

22-
If you want to use the gui component: `python3 setup_gui.py install`
23-
24-
This library requires the Pillow and colorama libraries. If you use the above install methods, these will automagically be installed.
25-
26-
`python3 -m pip install -U Pillow colorama`
27-
28-
To use the gui you need PySide
29-
30-
`python3 -m pip install -U PySide`
31-
32-
At the time of this commit PySide can only be installed on Python versions 2.6, 2.7, 3.3, 3.4. If you wish to use the GUI you must have installed versions 3.3 or 3.4. You can read more about it here https://github.com/PySide/pyside-setup/issues/53
33-
3424
Usage
3525
---
3626

3727
```
38-
Usage: ascii_py [options]
28+
usage: ascii_py [-h] [-o OUT] [-w WORDS] [-s STEP] [-d] [-t] input_file
3929
40-
Options:
30+
positional arguments:
31+
input_file Input file to convert from.
4132
33+
optional arguments:
4234
-h, --help show this help message and exit
43-
-o FILENAME, --out=FILENAME
44-
The filename you want your final image saved as
45-
-w WORDS, --words=WORDS
46-
Use words to create your image
47-
-s STEP, --step=STEP Choose the distance of your characters
48-
-d, --density Adding the flag converts the image based on visual
49-
density
50-
-t, --terminal Print ascii image to terminal
35+
-o OUT, --out OUT The filename you want your final image saved as.
36+
-w WORDS, --words WORDS
37+
Use words to create your image.
38+
-s STEP, --step STEP Choose the distance of your characters.
39+
-d, --density Adding the flag converts the image based on visual density.
40+
-t, --terminal Print ascii image to terminal.
5141
```
5242

5343
Example images

ascii_py/ascii.py

Lines changed: 0 additions & 189 deletions
This file was deleted.

0 commit comments

Comments
 (0)