Skip to content

Commit 09b86eb

Browse files
committed
fix: english syntax
1 parent f22b595 commit 09b86eb

File tree

3 files changed

+35
-20
lines changed

3 files changed

+35
-20
lines changed

README.md

Lines changed: 31 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,23 @@
1-
# Convert2ASCII
1+
# Convert2Ascii
22

33
Convert Image/Video to ASCII art.
44

55

6+
## Intro
7+
8+
convert2ascii provides two executable commands:
9+
10+
* image2ascii: transform picture to ascii art and display in terminal.
11+
* video2ascii: transform video to ascii art, you can save or play it in terminal.
12+
13+
It also provides classes as a gem:
14+
15+
* Convert2Ascii::Image2Ascii
16+
* Convert2Ascii::Video2Ascii
17+
18+
you can use it in your code and make your own ascii art !
19+
20+
621
## Test pass
722

823
* MacOS 15.2 ✅
@@ -20,57 +35,57 @@ Convert Image/Video to ASCII art.
2035

2136
## Prerequisites
2237

23-
* Ruby3+
38+
* Ruby 3+
2439
* ImageMagick ([Download here](https://imagemagick.org/script/download.php))
2540
* ffmpeg ([Download here](https://www.ffmpeg.org/))
2641

2742
# How to use
2843

29-
## Try in docker
44+
## Try in Docker
3045

3146
`$ docker run -it -v $(pwd):/app mark24code/convert2ascii bash -c "cd /app && exec bash"`
3247

33-
> `$(pwd)` can change to your local path, here use you working path.
48+
> `$(pwd)` can be changed to your local path. Here, use your working path.
3449
3550

3651
## Install
3752

38-
`gem install convert2ascii`
53+
`$ gem install convert2ascii`
3954

4055

41-
## Executable command
56+
## Executable commands
4257

4358
### image2ascii
4459

45-
Make image to ascii art in your terminal.
60+
Convert an image to ascii art.
4661

4762
```bash
4863
image2ascii -h
4964
Usage: image2ascii [options]
50-
--version verison
65+
--version version
5166
-i, --image=URI image uri (required)
5267
-w, --width=WIDTH image width (integer)
53-
-s, --style=STYLE ascii style: ['color'| 'text']
54-
-b, --block ascii color style use BLOCK or not [ true | false ]
68+
-s, --style=STYLE ascii style: 'color'/'text'
69+
-b, --block ascii color style use BLOCK or not true/false
5570
```
5671

5772
### video2ascii
5873

59-
Make image to ascii art in your terminal.
74+
Convert a video to ascii art.
6075

6176
```bash
6277
Usage: video2ascii [options]
6378

64-
* default will generate and play without save.
65-
* -p will just play ascii frames dir, and ignore -i, -o others options. --loop will play loop
79+
* By default, it will generate and play without saving.
80+
* The -p option will just play the ascii frames within the directory, and ignore -i, -o other options. --loop will play loop
6681
* -i,-o will just generate and output frames and ignore others options
67-
--version verison
82+
--version version
6883
-i, --input=URI video uri (required)
6984
-w, --width=WIDTH video width (integer)
7085
-s, --style=STYLE ascii style: ['color'| 'text']
7186
-b, --block ascii color style use BLOCK or not [ true | false ]
72-
-o, --ouput=OUTPUT save ascii frame to output dirname
73-
-p, --play_dir=PLAY_DIRNAME input ascii frames dirname to play
87+
-o, --ouput=OUTPUT save ascii frames to the output directory
88+
-p, --play_dir=PLAY_DIRNAME input the ascii frames directory to play
7489
--loop
7590
```
7691

exe/image2ascii

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ options = {}
77
OptionParser.new do |parser|
88
parser.banner = "Usage: image2ascii [options]"
99

10-
parser.on("--version", "verison") do |v|
10+
parser.on("--version", "version") do |v|
1111
puts "convert2ascii/image2ascii: v#{::Convert2Ascii::VERSION}"
1212
puts "author: Mark24"
1313
puts "mail: mark.zhangyoung@gmail.com"

exe/video2ascii

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ Usage: video2ascii [options]
4545
* -p will just play ascii frames dir, and ignore -i, -o others options. --loop will play loop
4646
* -i,-o will just generate and output frames and ignore others options
4747
DOC
48-
parser.on("--version", "verison") do |v|
48+
parser.on("--version", "version") do |v|
4949
puts "convert2ascii/video2ascii: v#{::Convert2Ascii::VERSION}"
5050
puts "author: Mark24"
5151
puts "mail: mark.zhangyoung@gmail.com"
@@ -82,11 +82,11 @@ DOC
8282
options[:color_block] = color_block || false
8383
end
8484

85-
parser.on("-o", "--ouput=OUTPUT", "save ascii frame to output dirname") do |output|
85+
parser.on("-o", "--ouput=OUTPUT", "save ascii frames to the output directory") do |output|
8686
options[:output] = output
8787
end
8888

89-
parser.on("-p", "--play_dir=PLAY_DIRNAME", "input ascii frames dirname to play") do |play_dir|
89+
parser.on("-p", "--play_dir=PLAY_DIRNAME", "input the ascii frames directory to play") do |play_dir|
9090
options[:play_dir] = play_dir
9191
end
9292

0 commit comments

Comments
 (0)