diff --git a/.gitignore b/.gitignore index 12b43b0..a464544 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ lolcat.o censor.o +lolcat +censor diff --git a/Makefile b/Makefile index 9ce889d..c751508 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ CC ?= gcc CFLAGS ?= -std=c11 -Wall -Wextra -O3 -Wno-sign-compare LIBS := -lm -DESTDIR ?= /usr/local/bin +PREFIX ?= /usr/local all: lolcat censor @@ -16,14 +16,14 @@ xterm256lut.h: xterm256lut_gen.py python $< > $@ lolcat: lolcat.c xterm256lut.h - $(CC) $(CFLAGS) -o $@ $< $(LIBS) + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LIBS) censor: censor.c - $(CC) $(CFLAGS) -o $@ $< $(LIBS) + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LIBS) install: lolcat censor - install lolcat $(DESTDIR)/lolcat - install censor $(DESTDIR)/censor + install lolcat $(DESTDIR)$(PREFIX)/bin/lolcat + install censor $(DESTDIR)$(PREFIX)/bin/censor clean: rm -f lolcat censor diff --git a/PKGBUILD b/PKGBUILD index 5c2652e..baec990 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Ricardo (XenGi) Band pkgname=c-lolcat -pkgver=v1.3 +pkgver=v1.5 pkgrel=1 pkgdesc="High-performance implementation of lolcat" arch=('i686' 'x86_64') diff --git a/README.md b/README.md index f2d4af9..602a390 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,10 @@ # What? -![](https://raw.githubusercontent.com/jaseg/lolcat/master/LOLCat-Rainbow.jpg) +![](./LOLCat-Rainbow.jpg) ## Screenshot -![](https://raw.githubusercontent.com/jaseg/lolcat/master/screenshot.png) +![](./screenshot.png) ![](./sl.gif) @@ -44,6 +44,8 @@ $ make lolcat ### Others +Note: Debian users may need the `python-is-python3` package. + ```bash $ make && sudo make install ``` diff --git a/autotools/configure.ac b/autotools/configure.ac index 8b9871b..28f5d08 100644 --- a/autotools/configure.ac +++ b/autotools/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ([2.69]) -AC_INIT([lolcat], [1.3], [jaseg ]) +AC_INIT([lolcat], [1.5], [jaseg ]) AC_CONFIG_SRCDIR([../lolcat.c]) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_AUX_DIR([autoscripts]) diff --git a/do_release.sh b/do_release.sh new file mode 100755 index 0000000..4d437e8 --- /dev/null +++ b/do_release.sh @@ -0,0 +1,31 @@ +#!/bin/sh + +set -e + +if [ $# -lt 1 ]; then + echo "do_release.sh must be called with a version number as its first argument." + exit 1 +fi + +if [ -n "$(git status --porcelain|grep -v '^??')" ]; then + echo "do_release.sh must be called from a clean working directory." + exit 2 +fi + +VER="$1" + +if echo "$VER" | grep -v '^[0-9]\+\.[0-9]\+$'; then + echo "do_release.sh must be called with a version number formatted like "1.23" as its first argument, with no leading \"v\"." + exit 1 +fi + +echo "Updating files for version v$VER" + +sed -i "/L\"lolcat version [0-9.]\+, (c) [0-9]\+ jaseg\\\\n\"/s/version [0-9.]\+/version $VER/" lolcat.c +sed -i "s/^pkgver=v[0-9.]\+/pkgver=v$VER/" PKGBUILD +sed -i "/^AC_INIT/s/\[[0-9.]\+\]/[$VER]/" autotools/configure.ac +git add lolcat.c PKGBUILD autotools/configure.ac +git commit -m 'Bump version to v$VER' +git tag "v$VER" +echo "Success." +