pg-export - pg to git converter
Export structure of database to object files for control version system
structure of result directories
casts:
...
data:
schema1:
table1.sql
schema2:
...
extensions:
...
publications:
...
schemas:
schema1:
aggregate:
...
domains:
...
functions:
...
operators:
...
sequences:
...
tables:
...
triggers:
...
types:
...
views:
...
schema2
...
installation
pip install pg-export
usage
usage: pg_export [--help] [--version] [--clean] [--ignore-version] [--echo-queries] [-h HOST] [-p PORT] [-U USER] [-W PASSWORD] [-j JOBS] [-z TIMEZONE] [-n SCHEMA] [-N EXCLUDE_SCHEMA] [-d DBNAME] [--skip-sequence-increment] [dbname] out_dir
Export structure of database to object files for control version system
positional arguments:
dbname source database name
out_dir directory for object files
options:
--help show this help message and exit
--version show program's version number and exit
--clean clean out_dir if not empty (env variable PG_EXPORT_AUTOCLEAN=true)
--ignore-version try exporting an unsupported server version
--echo-queries echo commands sent to server
-h HOST, --host HOST host for connect db (env variable PGHOST=<host>)
-p PORT, --port PORT port for connect db (env variable PGPORT=<port>)
-U USER, --user USER user for connect db (env variable PGUSER=<user>)
-W PASSWORD, --password PASSWORD
password for connect db (env variable PGPASSWORD=<password>)
-j JOBS, --jobs JOBS number of connections
-z TIMEZONE, --timezone TIMEZONE
timezone for constraints, partitions etc.
-n SCHEMA, --schema SCHEMA
dump the specified schema(s) only
-N EXCLUDE_SCHEMA, --exclude-schema EXCLUDE_SCHEMA
do NOT dump the specified schema(s)
-d DBNAME, --dbname DBNAME
source database name (env variable PGDATABASE=<dbname>)
--skip-sequence-increment
do not export sequences increment (env variable PG_EXPORT_SKIP_SEQUENCE_INCREMENT=true)
examples
pg_export -h 127.0.0.1 -p 5432 -U postgres -j 4 my_database /tmp/my_database_structure/
Metadata
Release files for pg-export 3.13.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pg_export-3.13.1.tar.gz | 32.0 kB | Without provenance | Details for pg_export-3.13.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pg_export-3.13.1-py3-none-any.whl | Python 3 | none | any | Details for pg_export-3.13.1-py3-none-any.whl |
Total release size: 86.3 kB
Release files / pg_export-3.13.1.tar.gz
| Download URL | pg_export-3.13.1.tar.gz |
|---|---|
| Size | 32.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
947fcfba1ed56a3801dce9c426a451bf682beccf4294b16ad3521ff0761dd9e0
|
|
BLAKE2b-256 checksum How to use checksums |
65f3a4e9acef25a6f2c757432a2089b6c376c1bc0c4c1380d7b0e9655b196e55
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.17
|
Release files / pg_export-3.13.1-py3-none-any.whl
| Download URL | pg_export-3.13.1-py3-none-any.whl |
|---|---|
| Size | 54.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3f32d9623ab4805e2aa7b9370775c6e3227e228968cce94224a0ce9f0238c23f
|
|
BLAKE2b-256 checksum How to use checksums |
b86a34eea9d234258cdda0339c825dc574fa8811cce12ef53325e49f2d7caeab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.17
|
Security for pg-export 3.13.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.