imgo is a simple, command-line image processing tool written in Go. It allows you to convert images between different formats (e.g., PNG, JPG, WebP) and compress images efficiently, all from the command line.
imgo is designed for developers and users who need to quickly convert or compress images directly from the command line. It’s simple, fast, and can be used in scripts or automation tools.
Currently, it supports:
- Converting images between common formats (PNG, JPG, WebP, etc.)
- Compressing images to reduce their file size.
- Convert images between multiple formats (PNG, JPG, WebP, etc.)
- Compress images with customizable quality
- Support for more image formats (future plans)
- Batch processing for multiple images (future plans)
Before you get started, make sure you have the following installed:
- Go (v1.16 or later): You can install Go from the official site.
- Make: If you don't have
make
installed, you can install it by following the instructions for your system. (It’s available by default on most UNIX-like systems).
To get started, clone the repository:
git clone https://github.com/wesleybertipaglia/imgo.git
Navigate to the project folder:
cd imgo
To build the binary, you can use the Makefile. This will handle the building process for you:
make build
This will create a binary file named imgo.
To run imgo from anywhere, you can install it globally:
make install
This will move the imgo binary to /usr/local/bin or another location in your system’s PATH.
Once the binary is installed, you can use the imgo commands from any folder.
For example, to convert an image:
imgo convert -i input.jpg -t png -o ./output
To compress an image:
imgo compress -i input.jpg -r 80
make dev - Runs the application with 'go run main.go'
make build - Builds the binary executable
make clean - Removes the built binary
make install - Installs the binary globally
make start - Runs the build
make fmt - Formats the Go code
make lint - Lint the Go code
Contributions are welcome! If you have any suggestions or improvements, please open an issue or a pull request.
This project is licensed under the MIT License. See the LICENSE file for more details.