SHTK_GIT_CLONE(3)
SHTK_GIT_CLONE(3) Library Functions Manual SHTK_GIT_CLONE(3)

shtk_git_cloneChecks out a new working copy out of a Git repository

shtk_import git

shtk_git_clone repo branch directory

The shtk_git_clone function checks out a new working copy of the repository repo into directory using the given branch. The directory must not exist.

In general, you should resort to using the higher-level shtk_git_fetch(3) wrapper as it properly handles the case of already existing working copies.

shtk_git_clone https://example.com/repo.git master /usr/src

shtk_git_clone aborts execution with an error if the given directory already exists or if the Git clone operation fails.

shtk(3), shtk_git(3)

shtk_git_clone first appeared in shtk 1.8.

January 6, 2025 Debian