Description
What problem are you trying to solve?
The command devbox generate readme
ignores the order of the scripts and re-orders it in the readme file to alphabetical order. I use the order explicitly for the humans who read it, so they have a clue what to do first.
Example of the problem
Scripts
The devbox.json
with the scripts in a particular order:
{
"shell": {
"init_hook": [],
"scripts": {
"step-one": [
"echo \"step-one\""
],
"step-two": [
"echo \"step-two\""
],
"step-three": [
"echo \"step-three\""
],
"step-four": [
"echo \"step-four\""
]
}
}
}
Generated README.md
This is the generated readme file created with devbox generate readme
:
Scripts
Scripts are custom commands that can be run using this project's environment. This project has the following scripts:
(etc.)
What solution would you like?
The generated Markdown in the README.md
file should have the same order as in the devbox.json
file, like so:
Scripts
Scripts are custom commands that can be run using this project's environment. This project has the following scripts:
(etc.)
Alternatives you've considered
For now I prepend the script name with a number, but this is cumbersome for maintenance. Because when an extra step is requirement somewhere in between, the next script names also has to change. This is not great...
Example of alternative
{
"shell": {
"init_hook": [],
"scripts": {
"01-step-one": [
"echo \"step-one\""
],
"02-step-two": [
"echo \"step-two\""
],
"03-step-three": [
"echo \"step-three\""
],
"04-step-four": [
"echo \"step-four\""
]
}
}
}
Generated README.md
Scripts
Scripts are custom commands that can be run using this project's environment. This project has the following scripts:
(etc.)