Skip to content
forked from codeliveroil/img

Terminal/Command-line image viewer

License

Notifications You must be signed in to change notification settings

scramble-suit/img

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

img - Command-line image viewer

A command line tool to view images (PNG, GIF, JPEG) right on the terminal. img comes in handy in the following scenarios:

  • to view images over SSH and VPN connections (where it's cumbersome to grab images and view them on the host machine)
  • can be used to generate splash screens for Linux logins (e.g. motd)
  • you never have to leave the terminal if you are working with image generation code
  • just for fun!

Supported OSes: macOS, Linux

Installation

Download the latest release for your operating system in the releases page, unzip and use the binary (img) or run install.sh.

Usage

img -help

Examples:

img car.png
img -w logo.sh logo.gif
img -l 2 wheel.gif

Demo

GIF:

GIF demo

JPEG/PNG:

Static image demo

Library API for GO

img := viz.Image{
	Filename:  "input.gif",
	LoopCount: 2,
}

// Read the image
if err := img.Init(); err != nil {
	//handle error
}

// Render the image
if err := img.Draw(&viz.StdoutCanvas{}); err != nil {
	//handle error
}

Compile from source

go get github.com/codeliveroil/img
make

About

Terminal/Command-line image viewer

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 92.1%
  • Shell 7.7%
  • Makefile 0.2%