Sign inSign up

bitoffdev/gifterm

By bitoffdev

•Updated over 7 years ago

Image
0

244

bitoffdev/gifterm repository overview

⁠GifTerm

This project runs a server that allows you to render any GIF⁠ in a terminal emulator using shell commands such as curl or wget.

This project was originally created for Big Red Hacks in the Fall of 2018.

⁠Setup

Before continuing, make sure you have Python 3 and Pip installed.

⁠Optional: Use Virtual Python Environment

I recommend using virtualenv⁠. This can save you from a lot of headaches if you have multiple python projects with many dependencies on the same computer.

Run the following command in your favorite shell to install virtualenv:

python3 -m pip install --user virtualenv

Now, run the following commands in the root directory of this repository to create and enter the virtual python environment:

virtualenv -p python3 env
source env/bin/activate

Now, you can proceed with the next step. You can get out of the virtual python environment at anytime by running deactivate.

⁠Importing img2txt submodule

This repo uses the img2txt⁠ submodule. Once you have cloned this repo, run the following to import the img2txt git repo:

git submodule init
git submodule update
⁠Installing the dependencies with pip
python3 -m pip install -r requirements.txt

⁠Running the server

Once you are setup, run the following in the root directory of this repository:

python3 -m gifterm

This will start a Flask⁠ server on port 5000 of your computer.

⁠Client usage

Using curl

curl localhost:5000

Using wget

wget -qO- localhost:5000

⁠Docker

If you are familiar with Docker, there is an image in this repository. You can build and run the Docker image with the following 2 commands:

docker build -t gifterm:latest .
docker run -tip 5000:5000 gifterm

⁠Example GIFs

Tag summary

Content type

Image

Digest

Size

55.5 MB

Last updated

over 7 years ago

docker pull bitoffdev/gifterm