Project

nyancat

0.01
No commit activity in last 3 years
No release in over 3 years
A Ruby port of Kevin Lange's nyancat
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

 Project Readme

Ruby port of Nyancat CLI

A Ruby port of the original nyancat CLI by Kevin Lange. Currently only supports xterm 256-color compatible terminals, likely doesn't work on Windows and lacks any finese or optimisation.

$ gem install nyancat
$ nyancat

For options, see --help

$ nyancat --help
Usage: nyancat [options]
-s, --silent                     Don't play audio
-f, --flavour FLAVOUR            Available flavours: original
-n, --notime                     Don't show the time nyaned
-l, --listen [PORT]              Run telnet server on PORT (default 21)
-t, --timeout SECONDS            Timeout after SECONDS

Audio

Very basic audio support is provided by using mpg123. You'll need mpg123 installed and in your $PATH for audio to work.

Telnet server

If run with -l or --listen and an optional port argument, a simple socket server will be started. The server will render a loop of the 'original' animation to connected clients using ANSI escaped text until any input from the client is received, upon which the connection is closed. The server does not currently implement the telnet protocol and simply spews ANSI text to the client. A proper telnet implementation is planned for the future.

Clients can connect to the server with a telnet client, though only xterm 256-color compatible terminals are supported.

$ telnet nyan.andatche.com 23

Licenses, References, etc.

The original source of the Nyancat animation is prguitarman.

Original video: http://www.youtube.com/watch?v=QH2-TGUlwu4 Original Song: http://momolabo.lolipop.jp/nyancatsong/Nyan/

The code provided here is provided under the terms of the NCSA license.