NovoProgramação ao vivo: um link para o candidato, uma sandbox partilhada por todos.Vê ↓
KendorDocs

How to import a Git repository as a challenge

For owners and editors ·

Este artigo ainda não está traduzido, por isso aparece em inglês.

Paste a GitHub, GitLab, Bitbucket or self-hosted repository link into a screen or live coding interview, choose Check, then add it as a challenge.

To use a repository as a challenge, paste its link into the repository field of a coding screen or a live coding interview, choose Check to preview what Kendor will import, then choose Add challenge. Kendor copies the files, sets up how the project runs, and opens the new challenge in the editor so you can review it.

Before you start

  • You need the Owner or Editor role. Viewers can't add challenges.
  • Public repositories on github.com, gitlab.com and bitbucket.org work straight away. Private repositories and your own Git servers need a token first: see Import a private repository.

The repository field appears in two places:

  • Coding screens. Open Screens, open or create a screen, and go to the Challenges section. When the screen has no challenges yet, the field fills the section. Once it has one, the field sits under the list as Paste a repository URL to add a challenge, so you can add more.
  • Live coding interviews. Open Live coding and choose New live coding interview. The field is in the Code section. A live coding interview holds one challenge, so the field only shows while it is empty.

You can paste the link the way your Git host shows it. All of these work:

Form Example
Repository page https://github.com/acme/rate-limiter
Without https:// gitlab.com/acme/rate-limiter
HTTPS clone URL https://bitbucket.org/acme/rate-limiter.git
SSH clone URL git@github.com:acme/rate-limiter.git
Branch or folder page https://github.com/acme/platform/tree/main/services/api
GitHub shorthand acme/rate-limiter or acme/rate-limiter@v2

The shorthand only works for github.com. The part after @ is a branch, tag or commit; without it, Kendor uses the default branch. To import a single branch or folder, paste its page link, as described in Import one folder or branch.

A link to a single file, such as GitHub's /blob/ pages, isn't accepted. Use the repository, branch or folder link instead.

Supported Git hosts

Host Needs a token
github.com Only for private repositories
gitlab.com Only for private repositories
bitbucket.org (Bitbucket Cloud) Only for private repositories
GitHub Enterprise Server Always: the server must be added first
GitLab self-managed Always: the server must be added first
Gitea or Forgejo Always: the server must be added first

GitLab subgroups work, for example https://gitlab.com/acme/backend/payments. Bitbucket Data Center (the self-hosted Bitbucket) isn't supported.

If you paste a link to a server your organization hasn't added, the check stops with a message that the host isn't connected, and a Connect it in Integrations settings link.

What the check shows

Check is a dry run that changes nothing. The result shows:

  • the host, owner, repository, folder and the branch or commit it resolved to
  • the number of files and their total size
  • whether the project has a run setup (see below)
  • the language Kendor detected, such as detected Node.js 22

Below that you can adjust the challenge before adding it:

  • Title, suggested from the repository or folder name
  • Language, the main language and version, plus any extra languages the project uses
  • Databases, when the project needs PostgreSQL or Valkey
  • How it runs, a summary of the services Kendor will start

If you change the link, choose Re-check before adding.

How Kendor sets up the project

Every challenge runs from a kendor.yaml file that says how to install and start the project. During the check Kendor looks for one at the root of what you import:

  • kendor.yaml found: the repository's own file is used as it is. The language version comes from the file, so it can't be changed in the language picker.
  • run setup detected — review it in the editor: there is no kendor.yaml, so Kendor writes one from what it finds, such as package.json, go.mod, pyproject.toml, composer.json or Cargo.toml. Repositories with one project per folder get one service per folder. The new challenge opens with the detected setup ready for you to review.
  • no kendor.yaml — configure the runtime in the editor: Kendor couldn't tell how the project starts. Candidates get a terminal until you set it up.

See the kendor.yaml reference for the file format.

What gets imported

Kendor copies the files, not the Git history. It leaves out dependency and build folders, including node_modules, vendor, .git, dist, build, target, .venv and __pycache__, so candidates install dependencies fresh.

The import has these limits, counted after those folders are left out:

Limit Value
Files 5,000
Total size 50 MB
Largest single file 5 MB
Download from the host 80 MB

A repository over the file limit fails with a suggestion to import a subfolder instead.

Tip. If you see a rate-limit message, wait a few minutes, or have an owner add a token for that host, which raises the limit.

After you add the challenge

Add challenge creates the challenge and opens it in the editor, where you can check that it runs and write the brief. The challenge keeps a fixed copy of the files: later pushes to the repository don't change it. See Snapshots and updates.

Este artigo foi útil?