1 Star 2 Fork 0

Sunfei / pokemonsay

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

pokemonsay

You should try pokemonsay!

pokemonsay is like cowsay but for pokémon only. It was inspired by ponysay (cowsay for ponies). Internally, pokemonsay still uses cowsay, so you need it installed too (cowsay... not ponysay).

Installation

Ubuntu

If you simply want to use pokemonsay, the only thing you need installed is cowsay. But you are probably interested in fortune as well, to provide random sayings to your pokémon. To install them both in Ubuntu, simply run:

$ sudo apt-get install fortune cowsay

If you want to rebuild everything in the repository, you will also need img2xterm. img2xterm is used to generate ".cow files" from the pokémon images. To install it you will need to build from source. The instructions are provided on their repository. And if you know an easier way, please tell me!

Keep in mind that pokemonsay will only work if you have cowsay installed and available in your $PATH. To install pokemonsay run these commands in a terminal window:

$ git clone http://github.com/possatti/pokemonsay
$ cd pokemonsay
$ ./install.sh

After the last command, you will have pokemonsay installed in you home folder in ~/.pokemonsay/. And an executable script will be created in ~/bin/pokemonsay, so that you can have pokemonsay in your $PATH too.

It may be necessary to logout and login back again to have pokemonsay in you $PATH. This is specially true if you have never had a ~/bin/ folder before. Your operating system will have it added to you $PATH automatically after the ~/bin/ folder is created... I hope.

OS X

You can install pokemonsay through Homebrew. It is pretty straightforward:

$ brew tap possatti/possatti
$ brew install pokemonsay

Docker

There's an interesting fork by @xaviervia that allows you to run pokemonsay on Docker. Check out xaviervia/docker-pokemonsay.

Usage

Now that you've installed pokemonsay, you can make it work like so:

$ pokemonsay Hello World

To have a random pokémon saying some random thing to you, use fortune:

$ fortune | pokemonsay

And if you really like it, you can add the command above to the end of your ~/.bashrc file (or equivalent). So you will have a random pokémon speaking to you whenever you open a new terminal window! :D

You get a cowthink-like version too. Try it:

$ pokemonthink --pokemon Charmander "Should I wear some clothes?"

Uninstall

Just in case you hate Pokémon and you've installed pokemonsay "by mistake"... Humpf! You can uninstall it by running:

$ sh $HOME/.pokemonsay/uninstall.sh

Building the whole thing

In order to use pokemonsay you don't need to build anything because everything is built already within the repository. But if you want to download the whole images again or make some change in the process, here is how it's done:

# Download pokémon images from Bulbapedia... Thanks bulbapedia!
$ ./scrap_data.sh

# Manipulate the downloaded images, to make the pokémon look
# to the right, and trim the useless space around them.
$ ./fix_images.sh

# Use 'img2xterm' to generate .cow files (for 'cowsay').
$ ./make_cows.sh

And there it is. Now install it with install.sh and you are done.

Special Thanks

A special thanks to my friend Lucas Coutinho Oliveira (@lucascsoliveira) who helped me with some Pokémon wisdom. Thanks buddy!

NOTICE

Please notice I don't own Pokémon or anything related to it. Pokémon is property of The Pokémon Company.

The MIT License (MIT) Copyright (c) 2015 Lucas Possatti Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

Forked from https://github.com/possatti/pokemonsay 展开 收起
Shell
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/sunfei2021/pokemonsay.git
git@gitee.com:sunfei2021/pokemonsay.git
sunfei2021
pokemonsay
pokemonsay
master

搜索帮助