Docs / Bring your code
Moving from GitHub or GitLab
This guide is one path from a project on GitHub (or GitLab) to the same project on Dash Forge, with its code, issues, pull requests, releases and labels, and your collaborators. It links the other guides in the order you need them, and says plainly what Forge doesn't do yet.
You don't have to move everything at once. Most projects start as a mirror, where GitHub stays the home and Forge follows it, and cut over later, or never. Both are covered.
Start here: the mirror wizard
Open forge.dashhq.org/mirror (or New → Mirror a GitHub repo). It asks whether you maintain the repository on GitHub, then offers two ways:
- Automatic sync, for people with write access on GitHub. Sign in here and create or reuse a Forge repository. Set up the GitHub Action now, or leave it for later. Its storage, runner key and workflow steps are optional.
- From the command line, for anyone who may copy the source. The wizard fills in commands for dg on your computer, with a repo name and spending cap you can change. You need dg, git-remote-dash, the GitHub CLI signed in, and a funded identity. The page signs nothing.
The setup wizard guide walks through both ways. Automatic setup resumes from this identity's saved browser answers; command-line settings resume from the page address. No key is saved. The wizard's workflow builds the Action's tools on the runner from the commit the site runs, which can be ahead of the latest release, so the first run takes several extra minutes.
The rest of this guide covers the command-line path: private repositories, GitLab, a one-off import with no Action, and cutting over.
- What moves and what doesn't
- Pick where the code is stored
- Get and fund an identity
- Import the repository
- Keep it in sync
- Cut over, or stay on both
- Invite collaborators
- CI
- What it costs
- GitHub features with no Forge equivalent
Replace every <…> placeholder with your own value. Forge runs on testnet, where Dash is free (Which network).
1. What moves and what doesn't
| On GitHub | On Forge | How |
|---|---|---|
| Branches, tags, full history | Branches, tags, full history (commit ids unchanged) | forge-import, or plain git push |
| Issues and their comments | Issues at the same numbers, with comments, labels and open/closed state | forge-import |
| Pull requests | PRs at the same numbers: title, body, base, head commit, state (open, closed, merged, draft), labels, comments, reviews. The head of each open PR as refs/mirror/pull/<n>/head | forge-import |
| Releases | Tag, title and notes. Each asset is recorded by its GitHub URL and SHA-256; the file is not copied | forge-import |
| Labels | Label definitions, and each item's labels | forge-import |
| Collaborators | Writers and maintainers, by Dash identity | dg collab add (§7) |
| Branch protection, required reviews | Protected branches (enforced by Dash Platform and Forge apps) and a branch policy (enforced by Forge apps) | dg repo protect, dg repo policy |
| Webhooks | GitHub-shaped webhooks, delivered by a relay you run | dg webhook add (§8) |
Imported items are written by your identity and name their GitHub author (how). Some things are not imported: see Not mirrored and §10.
Public by default. Everything you import is published on Dash Platform, permanently, and can't be deleted: issues and PRs by design, packs because others depend on them. Import only what you are happy to publish forever. GitLab's members-only content is refused unless you pass --include-members-only, and internal comments and confidential issues are never imported (GitLab guide). The importer creates public repositories. To import into a private one, create it first with dg repo create --private <name> and pass --repo <name>. Its releases are then sealed: their tags, names, notes, source links and asset lists are encrypted, and each asset the importer can download is encrypted and stored on your own storage (the storage policy you set for the packs), so a private import with releases needs storage of your own. Storage still shows each asset's exact size, which can identify the public release it mirrors. Label definitions are left out unless you pass --include-label-definitions (Private repositories).
2. Pick where the code is stored
Forge hosts nothing. Pack bytes (the git objects) go to storage you choose, and only small signed records go on Platform. Decide this before you import: the import pushes the whole history, and storing it on Platform is priced per byte and permanent (Platform or your own bucket).
| Option | Good for | Guide |
|---|---|---|
| Cloudflare R2 | most projects: no egress fees, a free tier | R2 |
| Backblaze B2, AWS S3, Storj | an account you already have | B2, S3, Storj |
| A NAS at home | no storage bill; needs a second copy for when it's off | Home NAS |
| IPFS (kubo, a pinning service) | content addressing, many readers | IPFS |
| Dash Platform | tiny repositories; no account needed | nothing to set up |
Set it up and make it your global default:
dg storage add # asks for each value, stores the secret in your keychain, tests it
dg storage test <profile> # every row OK, including "browser CORS"
dg storage use <profile> --global # two places for anything you care about: dg storage use r2-main,nas --global--global matters: forge-import pushes through git-remote-dash, which reads the global dash.storage. A repository can override it later with its own dg storage use (without --global), run inside that clone.
3. Get and fund an identity
A Dash identity is your account. You create it yourself by locking some Dash. Nobody issues it, and Forge never creates or funds one for you.
dg auth newdg shows a 12-word recovery phrase (write it down), then a deposit address. Fund it from any Dash wallet; on testnet, use the Dash testnet faucet or faucet.thepasta.org. How much you need depends on the repository: forge-import --dry-run in the next step tells you. Quick start §2–3 has the details, and Identity and keys covers backups and top-ups.
4. Import the repository
Install the importer (quick start §1 installs dg and git-remote-dash from a source clone), and sign in to GitHub so it can read issues, PRs and releases:
# From the source clone of the quick start. Or the install script fetches it from the latest
# release (DASH_FORGE_BINARIES="dg git-remote-dash forge-import", see INSTALL.md).
cargo install --locked --path crates/forge-import
gh auth loginThe standalone forge-import does not read dg's saved identity or network, so give it both. dg import <owner>/<repo> is the same engine with dg's defaults, if you prefer.
export DASH_FORGE_KEY=keychain:dash-forge/testnet/<your identity id> # the key dg auth stored(If dg auth status says the key is in a passphrase-encrypted file, use that file's path instead, and set DASH_FORGE_PASSPHRASE. forge-import is built to run unattended, so it never asks for the passphrase, even in a terminal.)
Price it first. A dry run reads everything and writes nothing:
forge-import alice/project --network testnet --dry-rungithub.com/alice/project → dash://5NGj…/project (testnet)
would write: 26 ref updates · 2 packs (794.4 KiB) · 1 issues · 36 PRs · 205 comments · 81 reviews · 32 events · 0 releases · 9 labels
estimate: 0.436514 DASH (dry run: nothing written)Try a few items, then look at the result on the web:
forge-import alice/project --network testnet --limit 5 --max-spend 0.1 --yes --i-have-the-rightsThen import everything, with a cap a little above the estimate and a state file for later runs:
forge-import alice/project --network testnet \
--max-spend 0.5 --state ./project.sync.json --yes --i-have-the-rights --summary-json ./import.json--i-have-the-rights says you may publish what you are importing: a real run needs it (or a "y" at a terminal), and prints the licence the source reports first. --yes only confirms the cost. A dry run needs neither.
--max-spend is a hard cap: the importer refuses to start above it and stops before the write that would cross it; a re-run with a higher cap finishes the job without writing anything twice. The GitHub mirror guide lists every flag and how a run ends. For GitLab, name the project as gitlab.com/<group>/<project> with a GITLAB_TOKEN (GitLab guide).
Check it. A commit id is a hash of the commit and all its history, so equal tips mean identical history:
git ls-remote dash://<your id>/project refs/heads/main
git ls-remote https://github.com/alice/project refs/heads/main # the same id
dg pr list <your id>/project --state all
dg storage status <your id>/project # every copy of every pack answersThen open https://forge.dashhq.org/<your id>/project. Run dg storage advertise <your id>/project once, so readers and the web app know where the packs live.
5. Keep it in sync
While GitHub is still where work happens, let Forge follow it with the Forge Mirror Action: the same importer, run from GitHub Actions on every push, issue, PR and release and on a daily schedule, under a per-run cost cap. The mirror wizard sets it up from the browser. To set it up by hand, see Mirror a GitHub repository §2. Its CI secret is a limited key, never your identity file:
dg auth export --new-key --master dash-identity-<id>.json \
--budget 0.5 --expires 365d --format dfk1 --reveal-secrets -o runner.dfk1For GitLab, use the CI template.
6. Cut over, or stay on both
Stay on both (dual-home)
Keep GitHub as the place people push and file issues, and keep the Mirror Action running. Forge then holds a copy nobody can take down, and readers can use either. This is the right choice while contributors, CI and integrations still live on GitHub.
In your own checkout, add Forge as a second remote so you can read from it:
git remote add forge dash://<your id>/project
git fetch forgeOnly one side should take writes. If people push to both, the mirror will overwrite Forge's branches with GitHub's on its next run.
Cut over
When Forge becomes the home:
- Stop the mirror. Delete the workflow file (or disable it in the Actions tab), then run one last
forge-importso the final issues and comments are there. - Freeze GitHub. Archive the GitHub repository (Settings → Archive this repository), or at least protect every branch, so nothing lands there that Forge won't see. Put the new address at the top of the README:
> This project moved to Dash Forge: https://forge.dashhq.org/<your id>/project > Clone: `git clone dash://<your id>/project` (needs [git-remote-dash](https://github.com/PastaPastaPasta/dash-forge/blob/master/docs/INSTALL.md)) - Point your checkout at Forge:
git remote rename origin github git remote add origin dash://<your id>/project git fetch origin git branch -u origin/main main git push # plain git from now on - Tell contributors how to get set up: install
dgandgit-remote-dash,dg auth new, thendg repo clone <your id>/project. Reading and cloning need no identity; pushing, issues and reviews do.
A DPNS username makes addresses readable: dg auth name register <label>, then dash://<label>/project and forge.dashhq.org/<label>/project work everywhere. Names of 3–19 characters made only of a–z, 0, 1 and - are contested and refused, so pick one with another digit or longer than 19 characters (for example alice-project2); see Identity and keys.
7. Invite collaborators
Each collaborator needs their own Dash identity (dg auth new) and sends you its id (dg auth status shows it). Then:
dg collab add <your id>/project <their identity id> --role writer # or --role maintainer
dg collab list <your id>/project| GitHub role | Forge role |
|---|---|
| Write | writer |
| Maintain / Admin | maintainer |
| Triage, Read | none needed: anyone can open issues and PRs, comment and review |
Collaborating says what each role can do. Only the repository's owner can add or remove members, and consensus enforces it.
A collaborator then clones and pushes with plain git. If your storage is a bucket, they need write access to it too: give them their own key for the same bucket, which they add with dg storage add and dg storage use. Or they can push to a bucket of their own. Readers find every pack through its on-chain manifest, wherever it is stored.
dg repo clone <your id>/project && cd project
git switch -c fix-typo && git commit -am "Fix a typo"
git push -u origin fix-typo
dg pr create <your id>/project --body "Fixes the README"To replace GitHub's branch protection:
dg repo protect defaults <your id>/project # only maintainers move main and tags (Platform enforces it; new repositories start this way)
dg repo policy set <your id>/project --required-approvals 1 # Forge apps hold the merge until approved8. CI
What exists today, and what doesn't:
- Webhooks: yes. GitHub-shaped webhooks, delivered by a relay you run, so a CI system that takes GitHub webhooks can build from Forge (Webhooks and CI).
- Showing check results: yes. A
checkRundocument records a named check on a commit (queued, in progress, completed; success or failure).dg pr checksand the web's PR page show them, the relay delivers them ascheck_runwebhooks, and a branch policy can require them (dg repo policy set … --require-checks true). - Writing check results: yes, with
dg ci.dg ci runner newgives a runner identity a key that can only post check runs and enrols it in the repository.dg ci report <owner>/<repo> --sha <commit> --name build --status completed --conclusion successwrites a check run from any CI, with an optional log and artifacts stored in your own storage. See CI and check runs. - A runner: one you run yourself. Forge hosts no CI.
forge-runnerruns a repository's.forge/workflows/*.yml(GitHub Actions syntax) with nektos/act in Docker, onpushandpull_request, and reports each job as a check run. Your.github/workflowsfiles do nothing on Forge until you copy them to.forge/workflows. It has noscheduleorworkflow_dispatchtriggers (what it does not do).
What people do today:
- Keep CI on GitHub while dual-homed (§6). The check action reports each GitHub Actions job as a Forge check run on the same commit.
- After a cut-over, run
forge-runner, or point a CI system that takes webhooks (Jenkins, Buildkite, Woodpecker, your own) at a relay, have it clone withgit clone dash://…, and report back withdg ci report.
9. What it costs
Forge takes nothing. You pay Platform fees from your identity's credits, and your storage provider's bill. What things cost has every measured figure, including a first mirror run, a push to your own storage and a push to Platform. For a migration:
- The import costs what
forge-import --dry-runsays. Most of it is one document per issue, PR, comment and review. - Later pushes cost the per-push figure in Costs for where your packs live.
- A Mirror Action re-run with nothing new costs nothing.
For example, the dry run of a repository with about 800 KiB of packs, 36 PRs, 205 comments and 81 reviews, with packs on the owner's own storage, was priced at 0.44 DASH. Almost all of that was the discussion history; the git part was 0.02 DASH. The same packs on Platform would have added about 0.27 DASH (see Costs).
10. GitHub features with no Forge equivalent
| GitHub | On Forge | What to do instead |
|---|---|---|
| Actions (CI/CD runners) | No hosted runners; a runner you host yourself (forge-runner) | See §8 |
| Discussions | None | Issues with a discussion label |
| Wiki | None | A docs/ folder in the repository; the web app renders Markdown |
| GitHub Pages | None: Forge serves no user content | Serve the site from your own bucket and domain (R2 and S3 host static sites) |
| Packages (npm, containers) | None | Publish to the usual registries, or attach build outputs to a release (dg release create --asset) |
| Projects / boards | None | Labels, and dg issue list --label … --assignee … filters |
| Milestones | Supported (dg milestone, and Issues → Milestones on the web), but the importer does not bring them over | Re-create the ones you need (Milestones) and set them with dg issue milestone |
| Issue and PR templates | Supported on the web: Markdown templates, YAML issue forms and config.yml from .github/ISSUE_TEMPLATE/ (or .gitlab/issue_templates/), and pull_request_template.md / PULL_REQUEST_TEMPLATE/ (or GitLab's merge request templates). A form's assignees are not applied, and dg does not read templates | Nothing: they are read from the repository (Issue and PR templates) |
| Reactions | None: each one would be a paid document | A comment, or a review approval |
| Verified commits | Supported for Ed25519 SSH and Ed25519/ECDSA OpenPGP keys you publish on your profile; RSA keys don't fit | dg profile key add (Signed commits) |
| Assignees | Not imported; you can assign on Forge (dg issue assign) | Re-assign open items after the import |
| CODEOWNERS | Read from the base branch; new PRs ask the owners for review (Code owners). Teams and e-mail owners are not asked, and @login is read as a DPNS name. "Require review from code owners" is a branch rule: dg repo policy set --require-code-owners true, or Settings → Branches (Requiring a code owner's approval) | Name people by DPNS name or identity id |
| Organizations and teams | Repositories belong to one identity; members are per repository | A shared maintainer identity, or add each person to each repository |
| Transferring a repository | Not possible: the owner is fixed | Create a repository under the new owner and push to it (history is unchanged) |
| Deleting a repository, issue or PR | Not possible: they are permanent | Archive the repository (dg repo archive), close issues and PRs |
| Git LFS | Not supported | Keep large binaries out of git; attach them to releases, which go to your storage |
https:// clone URLs, shallow clones | dash:// only (needs git-remote-dash); no --depth (E205) | git clone --filter=blob:none for a light clone; the web app offers a zip of any branch |
| Email notifications | None: there is no server to send them | The web app's Notifications, or a webhook to your own notifier |
| Code search | Within one repository, in the web app: built in your browser from the repository's files, the default branch only for a large repository (Search the code). No search across repositories: that needs an indexer, and Forge runs none | git grep in a clone |
| Secret scanning, Dependabot | None | Run those tools locally or in your own CI |
| Private repositories in the web app | The web app reads private repositories and writes their issues, PRs and reviews, but can't merge PRs or commit to branches in them yet | Use dg for those |
The FAQ has more on what Forge is and isn't.
This page is docs/guides/moving-from-github.md from the Dash Forge repository, as of this build. View or edit it on GitHub