Récupère les infos d'un projets sur une forge Gitlab

get_proj_gitlab(url, token_env, project_id, nivdeep = c("base"))

Arguments

url

string. adresse de la forge gitlab avec protocole (ex: https://gitlab.com)

token_env

string. nom de la variable d'environnement contenant le token gitlab

project_id

integer. identifiant du repo sur la forge

nivdeep

string vector. c("base", "ci","gest"). niveau d'information de l'output. ajoute des requetes Api. Defaut c("base") base => colonnes (id,name,path,path_with_namespace,web_url,pathgroup...) ci => ajoute colonnes (cicd, sched) gest => ajoute colonnes (storage_size, pushed_at, contributors, topics)

Value

data.frame

Examples

# Working only if Env Var "GITBOARD_FORGE_TOKEN" is defined
get_proj_gitlab(
  url = "https://gitlab-forge.din.developpement-durable.gouv.fr",
  token_env = "GITBOARD_FORGE_TOKEN",
  project_id = 21638,
  nivdeep = c("base","gest","ci"))
#>      id   name   path  path_with_namespace
#> 1 21638 Siclop siclop dreal-pdl/csd/siclop
#>                                                                       web_url
#> 1 https://gitlab-forge.din.developpement-durable.gouv.fr/dreal-pdl/csd/siclop
#>       pathgroup description default_branch visibility          updated_at
#> 1 dreal-pdl/csd                       main     public 2025-09-11 12:08:38
#>   topics           pushed_at storage_size      contributors cicd sched
#> 1        2025-09-11 12:08:34        13294 1318,59,1318,2830 TRUE  TRUE