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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Specify port without fallback? #11

Closed
lazarljubenovic opened this issue Apr 12, 2019 · 3 comments
Closed

Specify port without fallback? #11

lazarljubenovic opened this issue Apr 12, 2019 · 3 comments

Comments

@lazarljubenovic
Copy link

I appreciate the simplicity of the command without too many flags, but I change the port much often than I change the fallback file. In fact, I've never changed the fallback file 馃槄

Would love to see --port so I can do yarn servor dist --port 3001 instead of yarn servor dist dist/index.html 3001.

@lukejacksonn
Copy link
Owner

Fair point. Positional arguments are a pain especially when it comes to adding more arguments. Do you know of a nice clean way to parse these kind of flags? Keeping in mind this lib is currently dependency free (and I'd kinda like it to remain that way)!

@lazarljubenovic
Copy link
Author

Maybe we could guess that an integer number is a port?

@lukejacksonn
Copy link
Owner

That sounds a little brittle (for example what if someone had a project called 123). I'd prefer a flag than making guesses, I just never found a very clean way of extracting them out of the command 馃

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

Successfully merging a pull request may close this issue.

2 participants