Repository: fniessink/next-action

Issue:
Add `--reference` to standard configuration file

Discussion:

Patch:
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7db5eed..d3ce3c0 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
 The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
 and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
 
+## [Unrelease]
+
+### Fixed
+
+- Include reference parameter into standard configuration file. Fixes #98.
+
 ## [0.16.0] - 2018-06-03
 
 ### Added
diff --git a/next_action/arguments/config.py b/next_action/arguments/config.py
index 243e787..6c6acdc 100644
--- a/next_action/arguments/config.py
+++ b/next_action/arguments/config.py
@@ -29,7 +29,8 @@ def read_config_file(filename: str, default_filename: str, error: Callable[[str]
 def write_config_file() -> None:
     """ Generate a configuration file on standard out. """
     intro = "# Configuration file for Next-action. Edit the settings below as you like.\n"
-    config = yaml.dump(dict(file="~/todo.txt", number=1, style="default"), default_flow_style=False)
+    config = yaml.dump(dict(file="~/todo.txt", number=1, reference="multiple", style="default"),
+                       default_flow_style=False)
     sys.stdout.write(intro + config)
 
 


Test patch:
diff --git a/tests/unittests/arguments/test_config.py b/tests/unittests/arguments/test_config.py
index fcdf588..8eb5728 100644
--- a/tests/unittests/arguments/test_config.py
+++ b/tests/unittests/arguments/test_config.py
@@ -99,7 +99,7 @@ class ConfigFileTest(ConfigTestCase):
         """ Test that a config file can be written to stdout. """
         self.assertRaises(SystemExit, parse_arguments)
         expected = "# Configuration file for Next-action. Edit the settings below as you like.\n"
-        expected += "file: ~/todo.txt\nnumber: 1\nstyle: default\n"
+        expected += "file: ~/todo.txt\nnumber: 1\nreference: multiple\nstyle: default\n"
         self.assertEqual([call(expected)], mock_stdout_write.call_args_list)