jacebrowning / jacebrowning/gitman
Lock command removes comments from configuration file
- Dominant language
- Python
- Stars
- 225
- Forks
- 36
- Avg merge
- 15h 47m
- Merged PRs (30d)
- 8
Description
A given gitman.yml like:
```yaml
location: demo
sources:
# gitman sources part 1
- name: gitman_1
repo: https://github.com/jacebrowning/gitman-demo
rev: example-branch
# ---------------------------------------------------
# Here some more documentation about the dependencies
# ---------------------------------------------------
# gitman sources part 2
- name: gitman_2
repo: https://github.com/jacebrowning/gitman-demo
rev: example-tag
```
will be transformed after a lock operation to:
```yml
location: demo
sources:
- name: gitman_1
type: git
repo: https://github.com/jacebrowning/gitman-demo
sparse_paths:
-
rev: example-branch
link:
scripts:
-
- name: gitman_2
type: git
repo: https://github.com/jacebrowning/gitman-demo
sparse_paths:
-
rev: example-tag
link:
scripts:
-
sources_locked:
- name: gitman_1
type: git
repo: https://github.com/jacebrowning/gitman-demo
sparse_paths:
-
rev: 1de84ca1d315f81b035cd7b0ecf87ca2025cdacd
link:
scripts:
-
- name: gitman_2
type: git
repo: https://github.com/jacebrowning/gitman-demo
sparse_paths:
-
rev: 7bd138fe7359561a8c2ff9d195dff238794ccc04
link:
scripts:
-
```
Unfortunately, most importantly the comments are removed and secondly the structure of the gitman.yml will be changed.
In this matter, all available but unused parameters for an source entry will be added.
I see the benefit to keep the comments and also not to spoil the gitman.yml with unused settings (at least for the `sources` section.
Maybe it is an approach to seperate the `source_locked` section in a seperate file.
Contributor guide
Assessment
This issue has not been assessed yet.