Skip to content
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

tljh-config set with a list as value #549

Open
jtpio opened this issue Apr 17, 2020 · 0 comments
Open

tljh-config set with a list as value #549

jtpio opened this issue Apr 17, 2020 · 0 comments
Labels
enhancement New feature or request needs-documentation Issue that can be solved with documentation

Comments

@jtpio
Copy link
Contributor

jtpio commented Apr 17, 2020

At the moment the docs mention:

If what you want is only to change the property’s value, you should use set and overwrite it with the desired value.

However this only applies to single properties, like a string or a number.

Would it make sense if tljh-config set could also be used to set a list (and potentially a dict too) as a value?

It sounds like it would be useful for example when managing the list of admin users. For now it's possible to control the list of admins with tljh-config add-item users.admin foo, but multiple calls to this command will add multiple entries to the list:

users:
  admin:
  - foo
  - foo

Then calling tljh-config remove-item users.admin foo will only remove one item at a time if there are duplicates.

It would be nice if tljh-config set users.admin ['foo', 'bar'] (or something similar like tljh-config set users.admin foo,bar) could override the list in one go.

What do you think?

Thanks!

Relates to

@consideRatio consideRatio added enhancement New feature or request needs-documentation Issue that can be solved with documentation labels Oct 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request needs-documentation Issue that can be solved with documentation
Projects
None yet
Development

No branches or pull requests

2 participants