{"id":20896203,"url":"https://github.com/waitingsong/gitlab-var-helper","last_synced_at":"2026-04-17T03:04:30.239Z","repository":{"id":57251309,"uuid":"218184630","full_name":"waitingsong/gitlab-var-helper","owner":"waitingsong","description":"Batch set gitlab CI/CD variables with toml","archived":false,"fork":false,"pushed_at":"2020-12-08T08:51:26.000Z","size":232,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-12-31T21:14:50.909Z","etag":null,"topics":["cd","ci","environment","gitlab","group-level","project-level","runner","variables"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/waitingsong.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-10-29T02:10:03.000Z","updated_at":"2020-12-08T08:51:29.000Z","dependencies_parsed_at":"2022-08-24T17:01:25.399Z","dependency_job_id":null,"html_url":"https://github.com/waitingsong/gitlab-var-helper","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/waitingsong/gitlab-var-helper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waitingsong%2Fgitlab-var-helper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waitingsong%2Fgitlab-var-helper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waitingsong%2Fgitlab-var-helper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waitingsong%2Fgitlab-var-helper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/waitingsong","download_url":"https://codeload.github.com/waitingsong/gitlab-var-helper/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waitingsong%2Fgitlab-var-helper/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31913078,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-16T18:22:33.417Z","status":"online","status_checked_at":"2026-04-17T02:00:06.879Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cd","ci","environment","gitlab","group-level","project-level","runner","variables"],"created_at":"2024-11-18T10:34:14.315Z","updated_at":"2026-04-17T03:04:30.211Z","avatar_url":"https://github.com/waitingsong.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# [gitlab-var-helper](https://waitingsong.github.io/gitlab-var-helper/)\n\nCreate and update [GitLab CI/CD environment variables] from settings file in `toml` format,\nbased on [gitlab-variable-helper]\n\n\n[![GitHub tag](https://img.shields.io/github/tag/waitingsong/gitlab-var-helper.svg)]()\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n![](https://img.shields.io/badge/lang-TypeScript-blue.svg)\n[![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg)](https://conventionalcommits.org)\n[![lerna](https://img.shields.io/badge/maintained%20with-lerna-cc00ff.svg)](https://lernajs.io/)\n\n\n## Installation\n\n```sh\nnpm i gitlab-var-helper\n# cli\nnpm i -g gitlab-var-helper-cli\n```\n\n\n## Usage\n\n### Generate token\n\n1. Open page\n  ```\n  https://git.your.com/profile/personal_access_tokens\n  ```\n2. Create `Personal Access Tokens` with `Scopes`\n  - `api` \n  - `read_repository`\n  - `write_repository`\n3. Remember the generated `token`\n  ```\n  Upw_foooooooooooo\n  ```\n\n\n### Create settings file\n\n```toml\n# settings.toml\ntitle = \"gitlab var settints\"\nhost = \"https://git.your.com\"\ntoken = \"Upw_foooooooooooo\"\n\n# groups ids\ngids = [ 13 ]\n\n# project ids\npids = [ 76, 77 ]\n\n# gVars.0 provides default values for groups in gids \n[gVars.0.publicVars]\n  VAR_PUB = 1024\n  VAR_DUP_PUB = 1024\n\n[gVars.0.protectedVars]\n  VAR_HIDE = 1024\n  VAR_HIDE2 = 1024\n\n[gVars.13.publicVars]\n  VAR_PUB = 'abcd'\n[gVars.13.protectedVars]\n  VAR_HIDE = 'def'\n  VAR_DUP_PUB = 2048\n\n# pVars.0 provides default values for Projects in pids\n[pVars.0.publicVars]\n  VAR_PUB = 1024\n[pVars.0.protectedVars]\n  VAR_HIDE = 1024\n\n[pVars.77.publicVars]\n  VAR_PUB = 2048\n  VAR_77_PUB = 2048\n[pVars.77.protectedVars]\n  VAR_77_HIDE = 2048\n\n```\n\n### Calling with package\n\n```ts\nimport { loadFiles } from 'gitlab-var-helper'\n\nconst paths = [ './settings.toml' ]\nloadFiless(paths)\n```\n\n### Calling by cli\n\n```sh\n# log error\ngitlab-var-helper load -f ./settings.toml\ngitlab-var-helper load -f ./settings.toml -f ./other.toml\n# log info\ngitlab-var-helper load -f settings.toml --logLevel info\n\ngitlab-var-helper load -f settings.toml --ignoreCert\n```\n\n\n## Packages\n\n| Package                   | Version                | Dependencies                 | DevDependencies                |\n| ------------------------- | ---------------------- | ---------------------------- | ------------------------------ |\n| [`gitlab-var-helper`]     | [![main-svg]][main-ch] | [![main-d-svg]][main-d-link] | [![main-dd-svg]][main-dd-link] |\n| [`gitlab-var-helper-cli`] | [![cli-svg]][cli-ch]   | [![cli-d-svg]][cli-d-link]   | [![cli-dd-svg]][cli-dd-link]   |\n\n\n## License\n[MIT](LICENSE)\n\n\n### Languages\n- [English](README.md)\n- [中文](README.zh-CN.md)\n\n\n[`gitlab-var-helper`]: https://github.com/waitingsong/gitlab-var-helper/tree/master/packages/gitlab-var-helper\n[main-svg]: https://img.shields.io/npm/v/gitlab-var-helper.svg?maxAge=86400\n[main-ch]: https://github.com/waitingsong/gitlab-var-helper/tree/master/packages/gitlab-var-helper/CHANGELOG.md\n[main-d-svg]: https://david-dm.org/waitingsong/gitlab-var-helper.svg?path=packages/gitlab-var-helper\n[main-d-link]: https://david-dm.org/waitingsong/gitlab-var-helper.svg?path=packages/gitlab-var-helper\n[main-dd-svg]: https://david-dm.org/waitingsong/gitlab-var-helper/dev-status.svg?path=packages/gitlab-var-helper\n[main-dd-link]: https://david-dm.org/waitingsong/gitlab-var-helper?path=packages/gitlab-var-helper#info=devDependencies\n\n\n[`gitlab-var-helper-cli`]: https://github.com/waitingsong/gitlab-var-helper/tree/master/packages/gitlab-var-helper-cli\n[cli-svg]: https://img.shields.io/npm/v/gitlab-var-helper-cli.svg?maxAge=86400\n[cli-ch]: https://github.com/waitingsong/gitlab-var-helper/tree/master/packages/gitlab-var-helper-cli/CHANGELOG.md\n[cli-d-svg]: https://david-dm.org/waitingsong/gitlab-var-helper.svg?path=packages/gitlab-var-helper-cli\n[cli-d-link]: https://david-dm.org/waitingsong/gitlab-var-helper.svg?path=packages/gitlab-var-helper-cli\n[cli-dd-svg]: https://david-dm.org/waitingsong/gitlab-var-helper/dev-status.svg?path=packages/gitlab-var-helper-cli\n[cli-dd-link]: https://david-dm.org/waitingsong/gitlab-var-helper?path=packages/gitlab-var-helper-cli#info=devDependencies\n\n\n[GitLab CI/CD environment variables]: https://docs.gitlab.com/ee/ci/variables/README.html#gitlab-cicd-environment-variables\n[gitlab-variable-helper]: https://github.com/soulteary/gitlab-variable-helper\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaitingsong%2Fgitlab-var-helper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwaitingsong%2Fgitlab-var-helper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaitingsong%2Fgitlab-var-helper/lists"}