Pagina aceasta nu e tradusă încă în Română, așa că e afișată în English.

Guide

What the customer does

In Site settings → Git sync, the customer clicks Connect GitHub or Connect GitLab (only the ones you set up are shown).

GitHub asks them to sign in and to install your platform's GitHub App on their account or organisation; GitLab asks them to sign in and allow JustDocs. Then they pick the repository, the branch (usually main), an optional folder for docs inside a project's own repository, and whether pushes go live straight away or arrive as drafts (the default). Each version of a site can be connected to its own branch.

  • A repository with docs (Mintlify docs.json, GitBook SUMMARY.md, or plain folders of Markdown) is shown for review, like a zip import, and comes in as drafts. An empty repository gets the site's pages with the next publish.
  • A push brings changed files in as drafts: changed pages are updated, new files become pages, renamed files keep their pages, deleted files archive their pages. Images become site files.
  • Each publish goes to the repository as one commit, with the release title and notes as its message and the publisher as its author. Only pages changed in JustDocs are written; a file nobody edited in JustDocs is never rewritten.
  • A page changed in both places keeps the editor's draft; the repository's version is saved in the page's history and the editor offers "Use GitHub's version" or "Keep mine".
  • API pages made from an OpenAPI file stay in JustDocs and aren't written to the repository.

Site settings → Git sync shows what waits, the last syncs and their outcome, and a Sync now button.

GitHub and GitLab differ in one way. GitHub works through your platform's GitHub App: repository access uses GitHub's one-hour tokens, made when needed and never stored. GitLab has no apps of that kind, so a connection works as the person who connected it; their GitLab sign-in is kept encrypted with the connection and renewed as it expires. JustDocs adds a webhook to the project for pushes, which needs the Maintainer role; without it, pushes come in once an hour and with Sync now.

Before you start: the scheduler must run (pushes are applied and releases sent by a job that runs every minute), and your install must be reachable from the internet over HTTPS, because GitHub sends push notices to https://your-domain.example/__git/github and GitLab to /__git/gitlab. An install they can't reach still connects and publishes; changes then come in with Sync now and once an hour.