Conan Package Registry
To work with the Conan registry, you need to get a GitFlic transport token. Instructions for obtaining a token can be found on the page.
The {domain_gitflic} attribute is found in the documentation below The domain must be specified in its place, depending on the version of GitFlic used.:
- for the SaaS version
registry.gitflic.ru - for Self-hosted
localhost:8080
The domain and port for the self-hosted version may vary.
Configuring the Conan Registry
To work, you need to add the registry to the list of remote sources.
The value of the url attribute depends on the access level:
| Level | URL |
|---|---|
| Project | http(s)://<domain_gitflic>/project/{ownerAlias}/{projectAlias}/package/-/conan |
| Company | http(s)://<domain_gitflic>/company/{companyAlias}/package/-/conan |
| Instance | http(s)://<domain_gitflic>/registry/package/-/conan |
| Variable in the URL | Description |
|---|---|
projectAlias |
Project alias |
companyAlias |
Company's alias |
ownerAlias |
Alias of the project owner |
Example of use for a project:
``
conan remote add {remote_name} http(s)://
Usage example for a company:
``
conan remote add {remote_name} http(s)://<domain_gitflic>/company/{companyAlias}/package/-/conan
You must log in to the source using the command:
conan remote login {remote_name}
Working with the registry
Downloading the package
To install the package as a dependency, add to the requires block of the file conanfile.py or conanfile.txt the required package with the specified version, then execute in the directory containing the dependency file.
conan install -r {remote_name}
To install the package itself, run the command:
conan install --require {package_name}/{package_version} -r {remote_name}
Package search
Using conan, you can view the list of sources where the required package is available.
conan search {package_name}
Package publication
In the directory with the configured file conanfile.py run the command to build the package:
conan create
To publish the compiled package, use the command:
conan upload {package_name} -r {remote_name}
The --only-recipe flag is used to upload only the recipe
Package Removal
To delete a package, use the command
conan remove {package_name}
Automatic translation!
This page has been automatically translated. The text may contain inaccuracies.