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

Onboarding wizard feedback #578

Open
trevor-e opened this issue Oct 2, 2024 · 4 comments
Open

Onboarding wizard feedback #578

trevor-e opened this issue Oct 2, 2024 · 4 comments

Comments

@trevor-e
Copy link

trevor-e commented Oct 2, 2024

Hey, been following along and am excited for this project. I gave it a spin on and had some feedback for the onboarding/new project process, figured it made sense to group it all here.

  1. Compared to other frameworks, it was a bit unexpected that we clone a template repo, run a command, and then it spits out a new sub-repo. It took me a second to realize what was happening. I figure there are eventual plans to do this fully within a CLI, just wanted to point out my confusion.
  2. Enter your package name: package name is such an overloaded term I thought it was asking for a bundle ID. Maybe it could be phrased as "Swift Package name" to be unambiguous.
  3. Some of the console output seemed distracting, like it just printed out ~/dev/hummingbird-template a few times.
  4. It would be great if the console output used colors to separate some of the information.
  5. Enter the folder created and run 'swift run' to build and run your server. coupled with my confusion earlier about how this creates a sub-directory with the scaffolded project, I was thinking "what folder"? Could it explicitly tell me which folder to open?
  6. Then open 'localhost:8080' on your web browser. I don't think the CLI needs to say this since swift run already outputs this too.
  7. When I run swift run it actually outputs [HummingbirdCore] Server started and listening on 127.0.0.1:8080, it would be nice if it said localhost:8080 for consistency. VSCode also seems to stumble trying to CMD+click opening 127.0.0.1:8080 into the browser so it would probably work better with localhost like other frameworks use.

Other than that everything worked! Excited to follow along.

@adam-fowler
Copy link
Member

Hey, been following along and am excited for this project. I gave it a spin on and had some feedback for the onboarding/new project process, figured it made sense to group it all here.

  1. Compared to other frameworks, it was a bit unexpected that we clone a template repo, run a command, and then it spits out a new sub-repo. It took me a second to realize what was happening. I figure there are eventual plans to do this fully within a CLI, just wanted to point out my confusion.

If you run the configure.sh command without any parameters it should edit the template in place. I have to play with this a little to get it right.

  1. Enter your package name: package name is such an overloaded term I thought it was asking for a bundle ID. Maybe it could be phrased as "Swift Package name" to be unambiguous.

Fair point

  1. Some of the console output seemed distracting, like it just printed out ~/dev/hummingbird-template a few times.

Yes this could be cleaned up

  1. It would be great if the console output used colors to separate some of the information.

👍

  1. Enter the folder created and run 'swift run' to build and run your server. coupled with my confusion earlier about how this creates a sub-directory with the scaffolded project, I was thinking "what folder"? Could it explicitly tell me which folder to open?

👍

  1. Then open 'localhost:8080' on your web browser. I don't think the CLI needs to say this since swift run already outputs this too.

The two addresses being printed out are different addresses. When I say open localhost:8080 that is the address your web client should open as that is where the server is running.

The address being printed out when you run the server is the address the server is listening on. Because you are running both client and server on the same machine they happen to be the same. But the server could also be listening on 0.0.0.0:8080, which indicates it will accept clients from any address.

  1. When I run swift run it actually outputs [HummingbirdCore] Server started and listening on 127.0.0.1:8080, it would be nice if it said localhost:8080 for consistency. VSCode also seems to stumble trying to CMD+click opening 127.0.0.1:8080 into the browser so it would probably work better with localhost like other frameworks use.

Using a host name for your listen address has performance impacts and should not be encouraged.

Other than that everything worked! Excited to follow along.

Thank you for taking your time to put your thoughts down. Hopefully we can get this right over time.

@trevor-e
Copy link
Author

trevor-e commented Oct 3, 2024

1: You're right, looking through my shell history I aborted the first configure and then tried again by adding the package name but can't remember why. 😅

6: I think at least formatting the address as http://localhost:8080 will make it CMD+Clickable in the terminal.

7: That makes sense. In my head I was comparing against Ktor which outputs:

2024-10-03 10:15:30.034 [main] INFO  Application - Application started in 0.329 seconds.
2024-10-03 10:15:30.139 [main] INFO  Application - Responding at http://localhost:8080

Thank you for taking your time to put your thoughts down. Hopefully we can get this right over time.

No problem! If you turn any of these suggestions into Issues I'm happy to take a stab at some of them while I play around with this some more.

@adam-fowler
Copy link
Member

  1. Tidied up output text, to hopefully make it clearer what is happening
  2. Fixed
  3. Fixed
  4. Not implemented yet, not sure colours really help but did add spaces to separate sections
  5. Edited text to include folder name, unless you are already in the folder

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

No branches or pull requests

3 participants