FIX: Adapt deduplicate sed command for OS X.

The sed command of BSD / OS X doesn't like { command } blocks in a single expression. So move the (dynamic) deduplicate sed command(s) to the end, and use a label to access them. This also makes the entire sed script somewhat easier to understand.
This commit is contained in:
Ingo Karkat
2012-01-23 11:05:12 +01:00
parent 880d829e8e
commit 25e6d7ae24
2 changed files with 20 additions and 12 deletions

View File

@@ -82,9 +82,9 @@ EOF
cat > todo.txt <<EOF
normal task
a bold action
a bold task
something else
a bold action
a bold task
something more
EOF
test_todo_session 'deduplicate with non-printable duplicates' <<EOF
@@ -92,7 +92,7 @@ test_todo_session 'deduplicate with non-printable duplicates' <<EOF
TODO: 1 duplicate task(s) removed
>>> todo.sh -p ls
2 a bold action
2 a bold task
1 normal task
3 something else
5 something more