Skip to main content

Save data from GitLab to a SQLite database.

Project description

gitlab-to-sqlite

License

Save data from GitLab to a SQLite database.

Attribution

The overall structure and CLI is taken from https://github.com/dogsheep/github-to-sqlite/.

How to install

$ pip install gitlab-to-sqlite

Authentication

Create a GitLab personal access token: https://gitlab.com/-/profile/personal_access_tokens

Run this command and paste in your new token:

$ gitlab-to-sqlite auth

This will create a file called auth.json in your current directory containing the required value. To save the file at a different path or filename, use the --auth=myauth.json option.

As an alternative to using an auth.json file you can add your access token to an environment variable called GITLAB_TOKEN.

Using custom gitlab instance

When running auth you may specify an optional --host parameter pointing to a custom instance.

$ gitlab-to-sqlite auth --host gitlab.internal

Fetching projects

The projects command retrieves a single project.

$ gitlab-to-sqlite projects gitlab.db group/project-name

Fetching pipelines

The pipelines command retrieves updated or created pipelines with their corresponding jobs.

$ gitlab-to-sqlite pipelines gitlab.db group/project-name

This command can be run regularly. Based on the most recent created or updated pipeline it only fetches changes that happened afterwards.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gitlab-to-sqlite-0.1.tar.gz (10.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gitlab_to_sqlite-0.1-py3-none-any.whl (11.0 kB view details)

Uploaded Python 3

File details

Details for the file gitlab-to-sqlite-0.1.tar.gz.

File metadata

  • Download URL: gitlab-to-sqlite-0.1.tar.gz
  • Upload date:
  • Size: 10.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for gitlab-to-sqlite-0.1.tar.gz
Algorithm Hash digest
SHA256 6ed4ca7c836c5b7f66d6de82bc8a2e4c11fa0bbfb709e7c54a4ab89f4eaf70ff
MD5 894f9e4643045efead1c744ea201eb48
BLAKE2b-256 03cfe272ff9175b0a953f89a61a7b7ebcb4d7f4dac5db68d19e68c48bc4e04fb

See more details on using hashes here.

File details

Details for the file gitlab_to_sqlite-0.1-py3-none-any.whl.

File metadata

  • Download URL: gitlab_to_sqlite-0.1-py3-none-any.whl
  • Upload date:
  • Size: 11.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for gitlab_to_sqlite-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3177eceabedd6253fa056748c7b08f3ea53d07bdb76b6cbb7c4e26a63a6942bb
MD5 4f92f0738a268a9a89cf2fcae6fce325
BLAKE2b-256 6be785278a795f4c7977fe91c8b431415799657dcfc303c3456fb353266e6a63

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page