Skip to content

Commit 9d54508

Browse files
committed
Add documentation
1 parent c7464c5 commit 9d54508

File tree

3 files changed

+53
-1
lines changed

3 files changed

+53
-1
lines changed

README.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,36 @@
11
# genimg
22

33
genimg is a lightweight tool for generating random images at custom sizes. I often need placeholder images for specific dimensions, and while there are many options available, I wanted a simple, self-hosted solution—so I built this.
4+
5+
## Install
6+
7+
You can install genimg using `go install` command.
8+
9+
```
10+
go install github.com/enindu/genimg@latest
11+
```
12+
13+
## Usage
14+
15+
You can run genimg using the following syntax.
16+
17+
```
18+
genimg <command>:<subcommand> [arguments]
19+
genimg [flags]
20+
```
21+
22+
To display the version message:
23+
24+
```
25+
genimg -v # or "genimg --version"
26+
```
27+
28+
To display the help message:
29+
30+
```
31+
genimg -h # or "genimg --help"
32+
```
33+
34+
## License
35+
36+
This software is licensed under the [GNU General Public License v3.0](https://www.gnu.org/licenses/gpl-3.0.en.html). You can view the full license [here](https://github.com/enindu/genimg/blob/master/COPYING).

help.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@ Available commands:
3232
Available flags:
3333
3434
-v, --version # View version message.
35-
-h, --help # View help message.`
35+
-h, --help # View help message.
36+
37+
Use "genimg <command>:help" to see more information about commands.`
3638

3739
fmt.Fprintf(os.Stdout, "%s\n", message)
3840
}

main.go

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,23 @@
1414
// You should have received a copy of the GNU General Public License along with
1515
// this program. If not, see <https://www.gnu.org/licenses/>.
1616

17+
// genimg is a lightweight tool for generating random images at custom sizes.
18+
//
19+
// Usage:
20+
//
21+
// genimg <command>:<subcommand> [arguments]
22+
// genimg [flags]
23+
//
24+
// Available commands:
25+
//
26+
// source
27+
//
28+
// Available flags:
29+
//
30+
// -v, --version # View version message
31+
// -h, --help # View help message
32+
//
33+
// Use "genimg <command>:help" to see more information about commands.
1734
package main
1835

1936
import (

0 commit comments

Comments
 (0)