Summary
servejss does not pass --git to the underlying JSS server, so git HTTP backend support is never enabled. Running git push against a servejss instance fails with fatal: repository not found.
Details
JSS has built-in git HTTP backend support (git clone, git push over HTTP) enabled via --git. However, jsserve/bin/jsserve.js:
- Does not expose a
--git / --no-git CLI option
- Does not include
--git in the jssArgs array passed to JSS
Since JSS defaults to git: false (options.git ?? false in server.js), git support is always off when using servejss.
Expected behavior
servejss should enable --git by default and expose --git / --no-git CLI flags so users can control it.
Steps to reproduce
npx servejss@latest --port 4445
# In another terminal:
git remote add x http://localhost:4445/myrepo/
git push x main
# fatal: repository 'http://localhost:4445/myrepo/' not found
Proposed fix
In bin/jsserve.js:
- Add CLI option:
.option('--git', 'Enable git HTTP backend (default: true)') and .option('--no-git', 'Disable git HTTP backend')
- Pass to JSS args:
if (options.git !== false) { jssArgs.push('--git'); }
Summary
servejssdoes not pass--gitto the underlying JSS server, so git HTTP backend support is never enabled. Runninggit pushagainst a servejss instance fails withfatal: repository not found.Details
JSS has built-in git HTTP backend support (
git clone,git pushover HTTP) enabled via--git. However,jsserve/bin/jsserve.js:--git/--no-gitCLI option--gitin thejssArgsarray passed to JSSSince JSS defaults to
git: false(options.git ?? falseinserver.js), git support is always off when using servejss.Expected behavior
servejssshould enable--gitby default and expose--git/--no-gitCLI flags so users can control it.Steps to reproduce
Proposed fix
In
bin/jsserve.js:.option('--git', 'Enable git HTTP backend (default: true)')and.option('--no-git', 'Disable git HTTP backend')if (options.git !== false) { jssArgs.push('--git'); }