-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use full yaml as input format #40
Comments
That isn't necessary, yaml has other drawbacks with escaping apostrophes et c. For multi-line, it's on the backlog, see: kown7#20 IIRC it's already a feature if you're using the LatexJinja2 output for exactly this reason. |
Hello @AMNeumann, |
Please be clear here! You are referring to a personal branch of the tool. |
I've already found the place in the code that I need to look at and thanks to the good architecture, implementing a yaml front end should not be too hard. I've got some hours this weekend and I'll try. |
Yes; I just wanted to point out that keeping the newlines in the output will break a lot of tests. I've tried. |
Maybe we could implement an input format switch in the config that would allow the tests to run and older projects to still compile without conversion. We could then build yaml output and use rmtoo itself for conversion. That would probably be the easiest and imho cleanest way to do this. We could start out with the txt format as default with a deprecation warning and later switch to yaml as default. On a side note, we could also build json input without much difficulty once yaml output works. |
Is your intention/use-case to have one yaml/json/toml file or many small ones? |
In a first step, I'm happy with many small ones similar to the current situation. Extending this to fewer files, e.g. one per topic wouldn't be hard at all, especially with yaml. |
I'd also assume: let's start simple - one file per requirement / input. The original idea was, to support different storage 'backends' like the original text files or - which I thought about but never implemented - a DB backend. It should be possible to add new text formats quite easily (of course this was never done before). |
I personally don't like database backends because with text files you can easily keep track of the evolution of requirements using a dedicated, user-selected versioning system. Also, a database backend necessarily means a user interface of some sort. This is one of the things I like best about rmtoo: I can edit my requirements over a shaky ssh connection using my favourite editor vim. |
Yes - using plain files is one use case - which is implemented and used (and I don't want to change this). |
The input format is already very similar to yaml, so I think it would be nice to simply use yaml as the input format.
The background for my suggestion is that I want to include pseudocode listings in a Topic (using the listings package), so it would be nice if newlines were retained from the Text field to the LaTeX output.
One of the downsides of course is that lists of the form
now need to be written differently:
or in list structure:
but especially the latter seems rather desirable.
I'm open to support you with a pull request, but I first wanted to run the idea by you. I could also implement a converter for "old style" files to yaml if necessary.
The text was updated successfully, but these errors were encountered: