Live data from Hacker News

Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

github.com

11–20 of 29 posts

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#11
post #3

Looks nice, any plans to add variables and prompts? I'd recommend adding at the very beginning of the README a short yaml sample. That's the first thing I wanted to look at, but I had to get some understanding and then I found the scaffolder-config repo.

Indeed. Updated the README.

Variables are an interesting idea. I will consider in that in the future.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#12
Unpopular opinion: If such a tool is useful for you, you are doing something wrong. There is maybe a valid exception for use cases that intentionally create projects that require manual work (university and other trainings), but generally if you spend time by creating the same folder structure over and over again, you're probably working at the wrong level of abstraction. (And if you are creating so many micro services: please stop!)

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#13
post #10

There is nothing wrong with creating your own type of wheel, but wouldn’t Yeoman achieve the same result?

Yeoman seems to aim towards web applications, scaffolder seems to aim for more generic type of application.

At a glance what makes that painfully obvious is that scoffolder is one binary, while Yeoman is... Well, first it depends on node+npm, then `yo` seems depend on more than 1000 packages.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#14
post #12

Unpopular opinion: If such a tool is useful for you, you are doing something wrong. There is maybe a valid exception for use cases that intentionally create projects that require manual work (university and other trainings), but generally if you spend time by creating the same folder structure over and over again, you're probably working at the wrong level of abstraction. (And if you are creating so many micro servic…

Or, you just happen to create a lot of directories that are similar? Nothing wrong with that.

I don't think your opinion is "unpopular" but more making unfair assumptions about situations you imagine others to use it, while there is more situations a tool like this could be useful for.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#15
post #12

Unpopular opinion: If such a tool is useful for you, you are doing something wrong. There is maybe a valid exception for use cases that intentionally create projects that require manual work (university and other trainings), but generally if you spend time by creating the same folder structure over and over again, you're probably working at the wrong level of abstraction. (And if you are creating so many micro servic…

I don't agree. Setting up a brand new project always requires boilerplate code. Either you waste time manually filling in all that boilerplate, or you just create everything from scratch with a helper command.

Microsoft recognized this need by updating its .NET CLI to create projects based on project templates. I know for a fact that at least one FANG has a couple of internal tools to create projects and CICD infrastructure from scratch using project templates.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#17
post #10

There is nothing wrong with creating your own type of wheel, but wouldn’t Yeoman achieve the same result?

Of course I'll be biased towards my tool in one or another way, but Scaffolder is much more lightweight and relatively easier to get started with, and as someone else mentioned, it's only a single binary, which adds up to lightweight point.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#18
I wish people would stop needlessly using yaml or claiming it to be a simple format. Show me your yaml spec compliant parser that you wrote in a day.

The number of times I had to think "That would not have happened with a JSON file." ... But I guess the debate is so well known on HN, that I don't need to go into it now.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#19

I wish people would stop needlessly using yaml or claiming it to be a simple format. Show me your yaml spec compliant parser that you wrote in a day. The number of times I had to think "That would not have happened with a JSON file." ... But I guess the debate is so well known on HN, that I don't need to go into it now.

I wish people would stop seeing the world so black or white.

JSON is not the the be-all and end-all of formats. All formats have their drawbacks, and there is not one format that is THE BEST for absolutely everything.

The author never claimed that YAML is simple, or whatever. But what I can see, is why'd they use YAML instead of JSON for this specific project.

The first thing that comes to mind is multiline strings, as files typically have multiple lines. How'd you do that with JSON? "fn main {\nprintln!(\"Hello\")\n}"? Looks super fun to edit.

Re: Show HN: Scaffolder, CLI tool to generate project structure, taken from YAML

#20

This is nice ! I like that you have kept the polyglot world in mind. You should consider adding: 1) configurability in terms of name ( a templating engine might help ) 2) generate functional build files

And probably keep the project language agnostic, by letting the user specify the content of functional build files.
Post reply on HN