diff --git a/Makefile b/Makefile index 737b82e6..ceb58b97 100644 --- a/Makefile +++ b/Makefile @@ -24,9 +24,9 @@ install: all mkdir -p "$(DESTDIR)/usr/share/licenses/ponysay/" install "COPYING" "$(DESTDIR)/usr/share/licenses/ponysay/COPYING" - mkdir -p "$(DESTDIR)/usr/share/man/man1" - install "manpage.1" "$(DESTDIR)/usr/share/man/man1/ponysay.1" - ln -sf "ponysay.1" "$(DESTDIR)/usr/share/man/man1/ponythink.1" + mkdir -p "$(DESTDIR)/usr/share/man/man6" + install "manpage.6" "$(DESTDIR)/usr/share/man/man6/ponysay.6" + ln -sf "ponysay.6" "$(DESTDIR)/usr/share/man/man6/ponythink.6" mkdir -p "$(DESTDIR)/usr/share/man/es/man6" install "manpage.es.1" "$(DESTDIR)/usr/share/man/es/man6/ponysay.6" @@ -41,9 +41,11 @@ uninstall: unlink "$(DESTDIR)/usr/share/zsh/site-functions/_ponysay"; unlink "$(DESTDIR)/usr/share/licenses/ponysay/COPYING" unlink "$(DESTDIR)/usr/share/bash-completion/completions/ponysay" - unlink "$(DESTDIR)/usr/share/man/man1/ponysay.1" - unlink "$(DESTDIR)/usr/share/man/man1/ponythink.1" + unlink "$(DESTDIR)/usr/share/man/man6/ponysay.6" + unlink "$(DESTDIR)/usr/share/man/man6/ponythink.6" unlink "$(DESTDIR)/usr/share/man/es/man6/ponysay.6" unlink "$(DESTDIR)/usr/share/man/es/man6/ponythink.6" + +>>>>>>> upstream/master clean: - rm -r "ponysaytruncater" + rm -f "ponysaytruncater" diff --git a/manpage.1 b/manpage.6 similarity index 83% rename from manpage.1 rename to manpage.6 index e35603ff..e25a560b 100644 --- a/manpage.1 +++ b/manpage.6 @@ -2,7 +2,7 @@ .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) -.TH PONYSAY SECTION "July 4, 2012" +.TH PONYSAY 6 "July 12, 2012" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: @@ -80,30 +80,17 @@ want to truncate the output on the height even if you are not running \fIponysay Bugs can be reported in <\fBhttps://github.com/erkin/ponysay/issues\fP>. .SH SEE ALSO .BR cowsay (1), -.BR fortune (1). +.BR fortune (6). .br .SH AUTHOR ponysay was written by Erkin Batu Altunbaş -with contributions from Mattias Andrée, Sven-Hendrik Haase, Jan Alexander Steffens &a. -.\" See file CREDITS for full list +with major contributions from Mattias Andrée, Sven-Hendrik Haase, Jan Alexander Steffens et al. +.\" See file CREDITS for full list. .PP This manual page was written by Louis Taylor for the Debian project (and may be used by others), and edited by Mattias Andrée . .br -.SH COPYRIGHT -DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE -.br -Version 2, December 2004 .PP -Copyright (C) 2012 Erkin Batu Altunbaş -.PP -Everyone is permitted to copy and distribute verbatim or modified -copies of this license document, and changing it is allowed as long -as the name is changed. -.PP -DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE -.br -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION -.PP -0. You just DO WHAT THE FUCK YOU WANT TO. +This program is licensed under WTFPL. +.\" See file COPYING to see the license. diff --git a/ponysay b/ponysay index e50b0b1d..7ec7943a 100755 --- a/ponysay +++ b/ponysay @@ -1,13 +1,13 @@ #!/usr/bin/env bash -version=0.9 -SYSTEMPONIES=/usr/share/ponysay/ponies +version=0.10 +SYSTEMPONIES="/usr/share/ponysay/ponies" HOMEPONIES="${HOME}/.ponysay/ponies" pony="*" -wrap= +wrap="" if [ "$TERM" = "linux" ]; then - SYSTEMPONIES=/usr/share/ponysay/ttyponies + SYSTEMPONIES="/usr/share/ponysay/ttyponies" HOMEPONIES="${HOME}/.ponysay/ttyponies" fi @@ -43,7 +43,7 @@ Options: -f[name] Select a pony (either a file name or a pony name.) -W[column] The screen column where the message should be wrapped. -See man ponysay(1) for more information. +See man ponysay(6) for more information. EOF } @@ -66,7 +66,7 @@ say() { if [ "$PONYSAY_FULL_WIDTH" = 'no' ] || [ "$PONYSAY_FULL_WIDTH" = 'n' ] || [ "$PONYSAY_FULL_WIDTH" = '0' ]; then cat else - WIDTH=$((stty size <&2 || echo 0 0) | cut -d ' ' -f 2) + WIDTH=`(stty size <&2 || echo 0 0) | cut -d ' ' -f 2` ponysaytruncater $WIDTH 2>/dev/null || ${HOME}/.local/bin/ponysaytruncater $WIDTH 2>/dev/null || ./ponysaytruncater $WIDTH 2>/dev/null || @@ -79,7 +79,7 @@ say() { if [ "$PONYSAY_SHELL_LINES" = "" ]; then PONYSAY_SHELL_LINES=2 fi - head --lines=$(( $(stty size <&2 | cut -d ' ' -f 1) - $PONYSAY_SHELL_LINES )) + head --lines=$(( `stty size <&2 | cut -d ' ' -f 1` - $PONYSAY_SHELL_LINES )) } if [ "$TERM" = "linux" ] || [ "$PONYSAY_TRUNCATE_HEIGHT" = 'yes' ] || [ "$PONYSAY_TRUNCATE_HEIGHT" = 'y' ] || [ "$PONYSAY_TRUNCATE_HEIGHT" = '1' ]; then @@ -106,7 +106,7 @@ do done shift $((OPTIND - 1)) -if ! hash $cmd &>/dev/null; then +hash $cmd &>/dev/null; if [ $? -ne 0 ]; then cat >&2 <