Skip to content

Support a local directory as the source repo (offline) - #20

Open
raoulbia-ai wants to merge 1 commit into
stuinfla:mainfrom
raoulbia-ai:feat/local-dir-source
Open

raoulbia-ai wants to merge 1 commit into
stuinfla:mainfrom
raoulbia-ai:feat/local-dir-source

Conversation

@raoulbia-ai

Copy link
Copy Markdown

Part 1 of 3 for #19 (local, offline runs).

Accept an absolute path to an already-checked-out working tree as the source argument. parseRepoUrl maps it (parent dir = owner, last path segment = name), and clone-repo copies the tree into the build dir — skipping .git, node_modules, and build/cache cruft — instead of git-cloning a URL.

  • Same downstream contract: a real working tree at clonePath, a default branch, reachable: true.
  • The INV-21 source-identity pin still applies to local sources.
  • No network, no credentials.

Lets the pipeline run against repos with no reachable clone URL (private/internal hosts, air-gapped machines, or a folder you already have locally).

Tests: tests/local-source.test.mjs (5, node:test). Independent of the other two PRs for #19.

An absolute path to an already-checked-out working tree is now a valid
source argument. parseRepoUrl maps it (parent dir = owner, last path
segment = name) and clone-repo copies the tree into the build dir —
skipping .git, node_modules and build/cache cruft — instead of
git-cloning a URL. Same downstream contract (real working tree at
clonePath, a default branch, reachable: true), and the INV-21
source-identity pin still applies. No network, no credentials.

This lets the pipeline run against repos with no reachable clone URL
(private/internal hosts, air-gapped machines, or a folder you already
have locally).
@netlify

netlify Bot commented Sep 14, 2026

Copy link
Copy Markdown

👷 Deploy request for explainmyrepo pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit da2df33

This branch has not been deployed

No deployments
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 this pull request may close these issues.

1 participant