-
Notifications
You must be signed in to change notification settings - Fork 21
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
Unified sections and Vim folds. #156
Comments
I suppose that What worries me is that this change would imply that the role state is reversible, which is almost never true. I think that 90% of current roles don't allow for a reversible state change, either because they don't yet track everything a'la |
There was no |
Related to: debops#156 Is currently based on development version of yaml2rst.
I would make a slight modification to the headers:
This way, without the additions in |
BTW, will the |
Sure. 😉 Covered by the regex:
I see your point. Although we control the build software so I am not sure if we need to take care of the "without the additions in yaml2rst" case. But if you prefer this then lets go with that. As long as we can agree on something 😄 |
@drybjed Redesigned and improved the format in https://github.com/debops/ansible-unattended_upgrades/blob/master/defaults/main.yml. This format meets all the requirements and has been approved. See: https://github.com/ypid/yaml2rst/blob/feature/yaml-fold-strip/docs/fold-markers.rst |
One thing that @drybjed changed was to go from # Main configuration [[[
# ------------------ to: # Main configuration [[[
# ---------------------- This has the advantage that in case we ever manage to get syntax highlighting for the embedded RST syntax working in Vim, it will not complain about sections being to short. I tried it but I am not sure if that is possible as the |
Ref: debops/docs#156 (comment) One thing that @drybjed changed was to go from ```YAML # Main configuration [[[ # ------------------ ``` to: ```YAML # Main configuration [[[ # ---------------------- ``` This has the advantage that in case we ever manage to get syntax highlighting for the embedded RST syntax working in Vim, it will not complain about sections being to short. I tried it but I am not sure if that is possible as the `# ` in the input for the syntax highlighting in Vim would need to be stipped out and then passed to the `rst` syntax highlighting. Ref: http://vim.wikia.com/wiki/Different_syntax_highlighting_within_regions_of_a_file#Extended_version
…roject. Related to: debops/docs#156
Related to: debops#3 Related to: debops/docs#156
Related to: debops#3 Related to: debops/docs#156
`--strip-regex` was intentionally limited to the RST part of the input to avoid problems. `--yaml-strip-regex` allows to mess with the YAML part of the input if needed. Related to: debops#3 Related to: debops/docs#156
Small inconvenience with the indented comments, yamllint complains about it in its default configuration:
|
Edit: Approved format: https://github.com/ypid/yaml2rst/blob/feature/yaml-fold-strip/examples/fold-markers-debops.yml
Edit: Reasoning docs: https://github.com/ypid/yaml2rst/blob/feature/yaml-fold-strip/docs/fold-markers.rst
Proposal for new unified sections and Vim folds format:
Edit: Initial proposal: https://github.com/ypid/ypid-ansible-common/blob/47b0c3fbc3a59b78d3505016928fc209694cea0b/template_role/defaults/main.yml
(has been redesigned by @drybjed, see #156 (comment))
Refer to: debops/yaml2rst#3 and https://github.com/htgoebel/yaml2rst/blob/develop/docs/fold-markers.rst for details.
The text was updated successfully, but these errors were encountered: