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

[ENHANCEMENT] Merge template into a single directory #34

Open
mtfishman opened this issue Dec 6, 2024 · 2 comments
Open

[ENHANCEMENT] Merge template into a single directory #34

mtfishman opened this issue Dec 6, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@mtfishman
Copy link
Member

Currently, the template is split into multiple directories in templates so parts can be selected when generating or updating packages, which is the design of PkgSkeleton.generate which we are calling out to. Instead, I think it would be better to merge them into a single template, and allow specifying a list of folders or files of that template to include or ignore when generating or updating packages.

An issue is that it may require invasive changes to PkgSkeleton.generate or rewriting a lot of that package here, which isn't ideal. However, we could still use PkgSkeleton.generate by creating temporary directories out of the selected folders and files so it still matches the folder structure expected by PkgSkeleton.generate.

@mtfishman mtfishman added the enhancement New feature or request label Dec 6, 2024
@lkdvos
Copy link
Collaborator

lkdvos commented Dec 6, 2024

An alternative option might be to have a single template, with some syntax to enable/disable certain parts of files, similar to how {PACKAGENAME} gets replaced with the correct package name. As a tentative example:

some part of the readme 
...
```{IF EXAMPLES}
## Examples

examples go here
```

@mtfishman
Copy link
Member Author

That's an interesting idea, that is similar to JuliaFormatter's syntax for disabling formatting of certain codeblocks: https://domluna.github.io/JuliaFormatter.jl/stable/#Turn-off/on-formatting.

I think probably we want both, since we want better control over which folders and files get included or ignored, and additionally we want fine-grained control over whether or not certain parts of files get included or ignored.

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

No branches or pull requests

2 participants