Closed paul-hammant closed 7 months ago
I like the suggestion for the create
description, however listing the number of files will be created will inevitably drift over time as we forget to update this. I'd rather not have to remember to maintain this. --dry-run
is interesting, what would it do, show a tree of files that would be created?
Yup tree of files. Maybe what I was trying to say was that superficially I couldn't tell which was more helloworld like of base and blank and lib.
@paul-hammant Would something like this make more sense?
create Creates a new project (multiple choice)
create-base Creates a new baseline Java application project with minimal commands (no dependencies)
create-blank Creates a new blank Java application project with standard commands (including JUnit tests)
create-lib Creates a new Java library project with minimal commands (no dependencies)
create-rife2 Creates a new RIFE2 web application project
Looks good. Observation (to this layman) "minimal commands" and "standard commands" remains undifferentiated. There's spare room in the create
line to have a read-more URL?
How about something like:
create Creates a new project (multiple choice)
create-base Creates a new baseline Java application project with no dependencies
create-blank Creates a new blank Java application project with JUnit tests and publishing
create-lib Creates a new Java library project with no dependencies
create-rife2 Creates a new RIFE2 web application project
The more I'm thinking about it, them more I think base
should be removed, as it only allows you to compile and run the application. Most people will need to be able to create a jar.
With that in mind, blank
should be renamed app
.
Furthermore, lib
should include standard commands (jar
, publish
, etc.)
So we'd be looking at something like:
create Creates a new project (multiple choice)
create-app Creates a new Java application project
create-lib Creates a new Java library project
create-rife2 Creates a new RIFE2 web application project
If we wanted to keep base
, then it should only have a basic build file, and no source code.
create-base Creates a basic project
This will make it a lot easier for people coming from Gradle or Maven.
how about
create hello-world-app|hello-world-lib | rife2-helloworld-webapp
# optional args:
# --with-Junit5 - to create tests too, and tasks for those
# --make-a-jar - to create a jar too and a task for that
You're making your own command syntax here and there is not requirement to get everything on one.
Later:
# optional args:
# --maven-central-publishing - to create a manifest are tasks to do publication
@paul-hammant That's starting to look a lot like Maven. I'd prefer to keep it as simple as possible.
True Maven-like would be when you have -Darg
going on to pass params to plugins ;)
I don't want to get rid of base
, it's the absolute minimum, no dependencies project bld can create. Some people will ask for that.
I don't want to get rid of
base
, it's the absolute minimum, no dependencies project bld can create. Some people will ask for that.
I agree, but it should not have any sources or tests, and true base
project.
There needs to be an example for the project bld not to fail on command execution. Without any sources, there's little point in creating a skeleton.
There needs to be an example for the project bld not to fail on command execution. Without any sources, there's little point in creating a skeleton.
That's how both Maven and Gradle do it.
Well, bld is proudly not Maven nor Gradle 😁
Well, bld is proudly not Maven nor Gradle 😁
Then it will be a base application with no dependencies, and as @paul-hammant suggested, it should just be:
Hello, bld!
Well it currently prints Hello World!
, that's all the app does. I don't agree that the test blueprint should be removed.
Well it currently prints
Hello World!
, that's all the app does. I don't agree that the test blueprint should be removed.
Yeah, makes no difference at this point, it's a blank application.
create Creates a new project (multiple choice)
create-base Creates the most basic Java project
create-blank Creates a new Java application project
create-lib Creates a new Java library project
create-rife2 Creates a new RIFE2 web application project
I might rename create-blank
to create-app
, but that means I have to change all docs also and I might not be feeling that right now.
I might rename
create-blank
tocreate-app
, but that means I have to change all docs also and I might not be feeling that right now.
I can do that.
I understand why you're not feeling it. I think you wanted the projects to match the Project
, BaseProject
and WebProject
structures. But as @paul-hammant pointed out, it's not obvious to noobs.
Well I like everything to be consistent, including the blueprint sources and so on. So I guess I'll go in and do that.
I would also keep blank
as a hidden option, for backward-compatibility.
Well I like everything to be consistent, including the blueprint sources and so on. So I guess I'll go in and do that.
That kinda hurts my feelings. =D
Sorry, that was not my intent.
Sorry, that was not my intent.
Dude, I was LOL'ing. It's not like I don't do the exact same thing with my code.
1.9.0 was updated with these changes
The "create" line would be even better if it suggested there would be an interactive prompt for base, blank, lib, etc.
Base and blank and lib might be better if they suggested roughly how many files that would be under git control at the end of the invocation. I say that cos I can't as a novice, guess which of
base
andblank
would make fewer source files.Maybe also a
--dry-run
option for create, so that could be made clear?