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

Are the complex templates read from local.toml overwritten the global one by default? #174

Open
ulic-youthlic opened this issue Jun 19, 2024 · 2 comments
Labels

Comments

@ulic-youthlic
Copy link

Environment

If applicable, provide the following details:

  • OS: Windows11 23H2
  • Dotter version: 0.13.1

The question

If I have a part of the complex template configuration in global.toml that is public and I just want to change the target of this template, can i write all the configuration in global.toml and just the following in the local.toml?

[my_package.files.my_template]
target = "path/to/local/file"

i had a try, but seems the new blank template in local.toml will cover the global one, and result is a blank template.

@ulic-youthlic ulic-youthlic changed the title Are the complex templates read from local.toml and global.toml overwritten by default? Are the complex templates read from local.toml overwritten the global one by default? Jun 19, 2024
@SuperCuber
Copy link
Owner

Could you also send the global.toml file? To see what you're trying to override.
If you have other properties for the complex template in the global.toml you will need to re-specify them in the local.toml
The assumption you don't does make sense but it doesn't work that way currently :(

@ulic-youthlic
Copy link
Author

Thanks for the reply,
I already know what you mean. As for why I did that, I can give you an example: I need to append a line to the profile to make my configuration take effect, so I used a complex. i wrote this template inside global.toml. However, the location of the profile is different on different machines, so I need to override the template's target attribute, which I put in local.toml. This is my usage scenario. If you ask me why I don't just add the profile to the repo, I'll tell you that PowerShell config needs some of the local part as well.
thx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants