A bug was introduced in commit 1fc82b6, when word wrapping was
introduced. The script was ignoring the user provided message.
What made it hang waiting for user input.
The bug is fixed now. Who could imagine that just a pair of quote
marks could break the script like that...
A 'pokemonthink.sh' was created in the repository. And the install
script creates a 'pokemonthink' script in the bin folder.
The 'pokemonthink' script calls pokemonsay, but using the --think
option... That's all!
A heredoc was used in the install script to generate the uninstall
script. This was made because they share important variables, like
'$install_path'.
If someone, for example, changes the '$install_path' in the install
script, but not in the uninstall script. The latter would be brokken.
So I think this was the safest way to keep things right, even if
changes are made.
Before this, the instalation path was '~/.config/pokemonsay', but I
don't think it was the best place to install, since there should be
only configuration files in there.
The new install path is '~/.pokemonsay/' which seems like a better
aproach.
In order to use 'pokemonsay', I need it installed somewhere. I think
a simple script is enough for that.
The install script copies the essential files to the '.config' folder
in 'home', and creates a script in the '~/bin' directory that will
run 'pokemonsay'.
I wonder if it could have been done in any better way.
I didn't like the script written in python. I feel like I didn't do
it quite right. The mess with pipes confuses me. It is so much
simpler to handle pipes using shell script, in my opnion.
The shell script version of 'pokemonsay' is tiny if compared to the
python version. And it does the same thing.
The python script is there to act as a 'cowsay' version but for
pokemon. It uses 'cowsay' internally, calling a subprocess to
handle cowsay.
The script doesn't accept many arguments (actually none), that's
something that can be improved. But it does display a nice result.
The script will mirror the pokemon images so that they will be
looking to the right. And it will crop the image in order to
remove all the whitespace around the pokemon.