Thanks to visit codestin.com
Credit goes to github.com

Skip to content

andradehenrique/snap-forge

Repository files navigation

SnapForge

Snap Forge is a versatile image and video processing toolkit designed to simplify common tasks like resizing, watermarking, and converting images to WebP format. Now with Docker support!

Features

  • Add watermark to image: Overlays an image as a watermark.
  • Convert to WebP: Converts images to WebP format, optimizing size without losing quality.
  • Resize images: Resize with custom dimensions.
  • Complete processing: A single script that runs all the above operations in sequence.
  • Add watermark to video: Overlays an video as a watermark.
  • Extract thumbnail of video: Generate a thumbnail in webp of video.

Repository Structure

  • watermark.sh: Adds a watermark to images.
  • convert-to-webp.sh: Converts images to WebP format.
  • crop.sh: Resizes images, creating thumbnails.
  • process-images.sh: Runs all three operations in sequence.
  • video-watermark.sh: Adds a watermark to videos and creates a thumbnail in webp.

Requirements

  • Linux or macOS with Bash installed or Docker.
  • CLI tools: imagemagick, libwebp, ffmpeg.

Usage without docker

  1. Add watermark to image:
./src/watermark.sh path/to/image/folder path/to/watermark.png
  1. Convert to WebP:
./src/convert-to-webp.sh path/to/image/folder
  1. Resize image:
./src/crop.sh path/to/image/folder widthxheight
  1. Complete processing:
./src/process-images.sh path/to/image/folder path/to/watermark.png widthxheight
  1. Add watermark to video:
./src/video-watermark.sh path/to/video/folder path/to/watermark.png

Usage docker

  1. Add watermark to image:
./run-image-watermark.sh path/to/image/folder path/to/watermark.png
  1. Convert to WebP:
./run-convert-to-webp.sh path/to/image/folder
  1. Resize image:
./run-crop.sh path/to/image/folder widthxheight
  1. Complete processing:
./run-process-images.sh path/to/image/folder path/to/watermark.png widthxheight
  1. Add watermark to video:
./run-video-watermark.sh path/to/video/folder path/to/watermark.png

Contributing

Contributions are welcome! Feel free to open issues and submit pull requests.

  1. Fork the repository.
  2. Create a new branch:
git checkout -b my-new-feature
  1. Make your changes and commit:
git commit -m "Add new feature X"
  1. Push to the branch:
git push origin my-new-feature
  1. Open a Pull Request!

License

This project is licensed under the MIT License - see the LICENSE file for details.


Feel free to adapt and improve! If you need help or have questions, open an issue! 🚀

About

Forge your images with one command

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages