pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/time/todotxt
Module Name: pkgsrc
Committed By: leot
Date: Wed Apr 25 15:23:55 UTC 2018
Modified Files:
pkgsrc/time/todotxt: Makefile PLIST distinfo
Added Files:
pkgsrc/time/todotxt/patches: patch-tests_test-lib.sh
Log Message:
todotxt: Update time/todotxt to 2.11.0
pkgsrc changes:
- Add support for the test suite (this needs gmake as a test tool dependency)
- Fix the shebang of test shell script with REPLACE_BASH and also add a
SUBST to fix a shebang in the middle of scripts (needed in shell script part
of the test suite).
REPLACE_INTERPRETER only adjust the shebang in the first line of the file.
- Add patches/patch-tests_test-lib.sh to just use `date -r' in non-GNU and
non-macOS lands. By default the current date is used and then the test will
definitely fails. While there are no guarantees that the date(1) available on
the system supports `-r' option it is probably better to try using it (indeed
this make all the date tests happy on NetBSD and probably also on FreeBSD and
OpenBSD according a quick skim of their date(1) man pages).
- Also install USAGE.md document (it is referenced by README.md).
Changes:
## [2.11.0] - 2018-03-26
### Added
- Added support for `$XDG_CONFIG_HOME` config file/actions location
- Created [CODE_OF_CONDUCT.md](/CODE_OF_CONDUCT.md) ([#217])
- Created [CHANGELOG.md](/CHANGELOG.md) ([#218])
### Changed
- Updated `add` command to accept lowercase priority ([#230])
- Clean tests and version file in Makefile. Don't ignore errors in tests.
- Updated [README.md](/README.md) ([#219])
- Update Downloads links to point at the Releases page ([#228])
- Set the executable bit when preparing releases ([#156])
### Fixes
- Update links to use https
- Suppress todo.sh error messages when invoked during completion ([#8])
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/time/todotxt/Makefile \
pkgsrc/time/todotxt/PLIST pkgsrc/time/todotxt/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/time/todotxt/patches/patch-tests_test-lib.sh
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/time/todotxt/Makefile
diff -u pkgsrc/time/todotxt/Makefile:1.1 pkgsrc/time/todotxt/Makefile:1.2
--- pkgsrc/time/todotxt/Makefile:1.1 Tue Dec 19 11:39:50 2017
+++ pkgsrc/time/todotxt/Makefile Wed Apr 25 15:23:55 2018
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.1 2017/12/19 11:39:50 leot Exp $
+# $NetBSD: Makefile,v 1.2 2018/04/25 15:23:55 leot Exp $
-DISTNAME= todotxt-2.10
+DISTNAME= todotxt-2.11.0
CATEGORIES= time
MASTER_SITES= ${MASTER_SITE_GITHUB:=todotxt/}
GITHUB_PROJECT= todo.txt-cli
@@ -11,7 +11,7 @@ HOMEPAGE= http://todotxt.org/
COMMENT= Simple and extensible shell script for managing your todo.txt file
LICENSE= gnu-gpl-v3
-USE_TOOLS+= bash:run gsed:run
+USE_TOOLS+= bash:run gmake:test gsed:run
SUBST_CLASSES+= todosh
SUBST_STAGE.todosh= pre-configure
@@ -27,7 +27,16 @@ SUBST_MESSAGE.todocfg= Adjusting TOOL_DI
SUBST_FILES.todocfg+= todo.cfg
SUBST_SED.todocfg+= -e '/^export TODO_DIR/ s,=.*,=$$HOME/.todo,'
-REPLACE_BASH= todo.sh
+# XXX: REPLACE_BASH only affect the `#!' on the first line, so we need to
+# XXX: manually adjust the other in the middle of the shell script.
+SUBST_CLASSES+= shebang
+SUBST_STAGE.shebang= pre-configure
+SUBST_MESSAGE.shebang= Replace hardcoded /bin/bash in the middle of scripts
+SUBST_FILES.shebang+= tests/actions-test-lib.sh
+SUBST_SED.shebang+= -e '2,$$s;!/bin/bash;!${BASH};'
+
+REPLACE_BASH+= todo.sh
+REPLACE_BASH+= tests/*.sh
USE_LANGUAGES= # none
@@ -40,12 +49,15 @@ PKG_SYSCONFSUBDIR= todotxt
CONF_FILES= ${EGDIR}/todo.cfg \
${PKG_SYSCONFDIR}/todo.cfg
+TEST_TARGET= test
+
INSTALLATION_DIRS= bin ${DOCDIR} ${EGDIR}
do-install:
${INSTALL_SCRIPT} ${WRKSRC}/todo.sh ${DESTDIR}${PREFIX}/bin
${INSTALL_DATA} ${WRKSRC}/todo.cfg ${DESTDIR}${EGDIR}
${INSTALL_DATA} ${WRKSRC}/todo_completion ${DESTDIR}${EGDIR}
- ${INSTALL_DATA} ${WRKSRC}/README.textile ${DESTDIR}${DOCDIR}
+ ${INSTALL_DATA} ${WRKSRC}/README.md ${DESTDIR}${DOCDIR}
+ ${INSTALL_DATA} ${WRKSRC}/USAGE.md ${DESTDIR}${DOCDIR}
.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/time/todotxt/PLIST
diff -u pkgsrc/time/todotxt/PLIST:1.1 pkgsrc/time/todotxt/PLIST:1.2
--- pkgsrc/time/todotxt/PLIST:1.1 Tue Dec 19 11:39:50 2017
+++ pkgsrc/time/todotxt/PLIST Wed Apr 25 15:23:55 2018
@@ -1,5 +1,6 @@
-@comment $NetBSD: PLIST,v 1.1 2017/12/19 11:39:50 leot Exp $
+@comment $NetBSD: PLIST,v 1.2 2018/04/25 15:23:55 leot Exp $
bin/todo.sh
-share/doc/todotxt/README.textile
+share/doc/todotxt/README.md
+share/doc/todotxt/USAGE.md
share/examples/todotxt/todo.cfg
share/examples/todotxt/todo_completion
Index: pkgsrc/time/todotxt/distinfo
diff -u pkgsrc/time/todotxt/distinfo:1.1 pkgsrc/time/todotxt/distinfo:1.2
--- pkgsrc/time/todotxt/distinfo:1.1 Tue Dec 19 11:39:50 2017
+++ pkgsrc/time/todotxt/distinfo Wed Apr 25 15:23:55 2018
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.1 2017/12/19 11:39:50 leot Exp $
+$NetBSD: distinfo,v 1.2 2018/04/25 15:23:55 leot Exp $
-SHA1 (todotxt-2.10.tar.gz) = 1cff257c4f45acb302246f51f1acaf00832e5e2e
-RMD160 (todotxt-2.10.tar.gz) = 9d3304d8d118f393b6c96c1411049b60ec2de34c
-SHA512 (todotxt-2.10.tar.gz) = b14d9d13948836d971f72b941770e8e2c59d171d35f074205900619c5c3efd7ca0a482887046c1865890afb6595fe27c69677c54ea5824163d291e16fa5329d3
-Size (todotxt-2.10.tar.gz) = 56509 bytes
+SHA1 (todotxt-2.11.0.tar.gz) = 07d177189de1009add10919939449dd7e4aa4adc
+RMD160 (todotxt-2.11.0.tar.gz) = a7903af5ce3c325a2d5a7fd74aa48f31ebabacd8
+SHA512 (todotxt-2.11.0.tar.gz) = 5500ed1aa10eceaaa3e5116605eed4f4228337fdc0f2ceaa5b889753a60576918c0953adbfbf80c40008d6dfdf854e8a538103bfed4d1015aa1c5a9876c2e47c
+Size (todotxt-2.11.0.tar.gz) = 712455 bytes
+SHA1 (patch-tests_test-lib.sh) = 8ebfce7cbe8c4a4f051a7f7bbbe9034e04264b5a
Added files:
Index: pkgsrc/time/todotxt/patches/patch-tests_test-lib.sh
diff -u /dev/null pkgsrc/time/todotxt/patches/patch-tests_test-lib.sh:1.1
--- /dev/null Wed Apr 25 15:23:55 2018
+++ pkgsrc/time/todotxt/patches/patch-tests_test-lib.sh Wed Apr 25 15:23:55 2018
@@ -0,0 +1,24 @@
+$NetBSD: patch-tests_test-lib.sh,v 1.1 2018/04/25 15:23:55 leot Exp $
+
+Instead of unconditionally use today date try to use `date -r'. According a
+quick skim of NetBSD, FreeBSD and OpenBSD date(1) man pages, all of them should
+support that.
+
+--- tests/test-lib.sh.orig 2018-04-25 14:30:34.714587570 +0000
++++ tests/test-lib.sh
+@@ -535,7 +535,14 @@ test_init_todo () {
+ ;;
+ *)
+ echo "WARNING: Current date executable not recognized"
+- echo "So today date will be used, expect false negative tests..."
++ echo "'date -r' will be used, expect false negative tests"
++ echo "if date(1) on your system does not support -r"
++ echo "option!"
++ cat > bin/date <<-EOF
++ #!/bin/sh
++ exec "$TODO_TEST_REAL_DATE" -r \$TODO_TEST_TIME \$@
++ EOF
++ chmod 755 bin/date
+ ;;
+ esac
+
Home |
Main Index |
Thread Index |
Old Index