taskwarrior/test/tw-2581.t
2021-08-21 01:06:55 -04:00

14 lines
484 B
Bash
Executable file

#!/usr/bin/env bash
# Test setting configuration variable with a trailing comment works
. bash_tap_tw.sh
# Add configuration variable with a trailing comment into taskrc
echo 'weekstart=Monday # Europe standard' >> taskrc
cat taskrc
# Use config the change the value to "Sunday"
task config weekstart Sunday
# Ensure the comment was preserved and value changed
cat taskrc | grep weekstart=Sunday
[[ `cat taskrc | grep weekstart=Sunday` == 'weekstart=Sunday # Europe standard' ]]