feat(core): add port flag to dev and start#430
Open
fpasquet wants to merge 1 commit intoalpic-ai:mainfrom
Open
feat(core): add port flag to dev and start#430fpasquet wants to merge 1 commit intoalpic-ai:mainfrom
fpasquet wants to merge 1 commit intoalpic-ai:mainfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #417
Add port flag to dev and start.
Example usage:
or
Greptile Overview
Greptile Summary
This PR adds a
--port(-p) flag to bothskybridge devandskybridge startcommands, allowing users to specify a custom port instead of the hardcoded default of 3000.Key changes:
resolve-port.tsutility with port validation and resolution logic (flag → env → fallback)devandstartcommands to accept--portflag and pass resolved port viaPORTenvironment variableserver.ts,widgetsDevServer.ts, templateindex.ts, devtoolsindex.ts) to read port fromprocess.env.PORTThe implementation follows a clear precedence: CLI flag >
PORTenvironment variable > default (3000). All port parsing includes proper validation to ensure values are within valid port range (0-65535).Confidence Score: 5/5
process.env.PORT. The changes are backward compatible (defaults to 3000) and documentation is comprehensive.(3/5) Reply to the agent's comments like "Can you suggest a fix for this @greptileai?" or ask follow-up questions!