pum 1.1.14__tar.gz → 1.1.15__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pum-1.1.14/pum.egg-info → pum-1.1.15}/PKG-INFO +1 -1
- {pum-1.1.14 → pum-1.1.15/pum.egg-info}/PKG-INFO +1 -1
- pum-1.1.15/pum.egg-info/SOURCES.txt +33 -0
- {pum-1.1.14 → pum-1.1.15}/pyproject.toml +2 -2
- pum-1.1.14/.ci/setup_db.sh +0 -17
- pum-1.1.14/.github/dependabot.yml +0 -20
- pum-1.1.14/.github/workflows/deploy-to-pypi.yml +0 -41
- pum-1.1.14/.github/workflows/docs.yml +0 -65
- pum-1.1.14/.github/workflows/tests.yml +0 -72
- pum-1.1.14/.github/workflows/wheel.yml +0 -42
- pum-1.1.14/.github/workflows/windows-tests.yml +0 -71
- pum-1.1.14/.gitignore +0 -13
- pum-1.1.14/.pre-commit-config.yaml +0 -39
- pum-1.1.14/docs/docs/api/changelog.md +0 -1
- pum-1.1.14/docs/docs/api/dump_format.md +0 -1
- pum-1.1.14/docs/docs/api/dumper.md +0 -1
- pum-1.1.14/docs/docs/api/exceptions.md +0 -2
- pum-1.1.14/docs/docs/api/hook_base.md +0 -2
- pum-1.1.14/docs/docs/api/hook_handler.md +0 -2
- pum-1.1.14/docs/docs/api/parameter_definition.md +0 -1
- pum-1.1.14/docs/docs/api/parameter_type.md +0 -1
- pum-1.1.14/docs/docs/api/permission.md +0 -1
- pum-1.1.14/docs/docs/api/permission_type.md +0 -1
- pum-1.1.14/docs/docs/api/pum_config.md +0 -1
- pum-1.1.14/docs/docs/api/role.md +0 -1
- pum-1.1.14/docs/docs/api/role_manager.md +0 -1
- pum-1.1.14/docs/docs/api/schema_migrations.md +0 -1
- pum-1.1.14/docs/docs/api/sql_content.md +0 -2
- pum-1.1.14/docs/docs/api/upgrader.md +0 -1
- pum-1.1.14/docs/docs/assets/images/favicon.ico +0 -0
- pum-1.1.14/docs/docs/assets/images/pum-darkmode.png +0 -0
- pum-1.1.14/docs/docs/assets/images/pum.png +0 -0
- pum-1.1.14/docs/docs/cli/baseline.md +0 -6
- pum-1.1.14/docs/docs/cli/check.md +0 -14
- pum-1.1.14/docs/docs/cli/dump.md +0 -11
- pum-1.1.14/docs/docs/cli/info.md +0 -4
- pum-1.1.14/docs/docs/cli/install.md +0 -10
- pum-1.1.14/docs/docs/cli/restore.md +0 -10
- pum-1.1.14/docs/docs/cli/role.md +0 -8
- pum-1.1.14/docs/docs/cli/upgrade.md +0 -8
- pum-1.1.14/docs/docs/cli.md +0 -25
- pum-1.1.14/docs/docs/configuration/config_model.md +0 -5
- pum-1.1.14/docs/docs/configuration/configuration.md +0 -26
- pum-1.1.14/docs/docs/configuration/demo_data_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/dependency_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/hook_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/migration_hooks_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/parameter_definition_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/permission_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/pum_model.md +0 -3
- pum-1.1.14/docs/docs/configuration/role_model.md +0 -3
- pum-1.1.14/docs/docs/getting_started.md +0 -56
- pum-1.1.14/docs/docs/hooks.md +0 -108
- pum-1.1.14/docs/docs/index.md +0 -20
- pum-1.1.14/docs/docs/roles.md +0 -70
- pum-1.1.14/docs/mkdocs.yml +0 -113
- pum-1.1.14/docs/requirements.txt +0 -5
- pum-1.1.14/docs/update_cli_docs.py +0 -52
- pum-1.1.14/pum/conf/pum_config_example.yaml +0 -19
- pum-1.1.14/pum.egg-info/SOURCES.txt +0 -154
- pum-1.1.14/scripts/run_postgis.sh +0 -21
- pum-1.1.14/test/__init__.py +0 -0
- pum-1.1.14/test/data/complex_files_content/changelogs/1.2.3/complex_files_content.sql +0 -61
- pum-1.1.14/test/data/custom_directory/.pum.yaml +0 -1
- pum-1.1.14/test/data/custom_directory/my_delta_directory/1.2.3/my_delta_directory.sql +0 -9
- pum-1.1.14/test/data/custom_migration_schema/.pum.yaml +0 -3
- pum-1.1.14/test/data/custom_migration_schema/changelogs/1.2.3/custom_migration_schema.sql +0 -9
- pum-1.1.14/test/data/demo_data/.pum.yaml +0 -5
- pum-1.1.14/test/data/demo_data/changelogs/1.2.3/single_changelog.sql +0 -9
- pum-1.1.14/test/data/demo_data/demo_data/demo_data.sql +0 -8
- pum-1.1.14/test/data/dependencies/.pum.yaml +0 -17
- pum-1.1.14/test/data/dependencies/changelogs/1.2.3/pre_post_python_parameters.sql +0 -9
- pum-1.1.14/test/data/dependencies/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/dependencies/post/create_schema.sql +0 -2
- pum-1.1.14/test/data/dependencies/post/create_view.py +0 -22
- pum-1.1.14/test/data/dependencies/pre/drop_view.sql +0 -3
- pum-1.1.14/test/data/invalid_changelog_commit/changelogs/1.2.3/invalid_changelog.sql +0 -13
- pum-1.1.14/test/data/invalid_changelog_search_path/changelogs/1.2.3/invalid_changelog.sql +0 -2
- pum-1.1.14/test/data/min_version/.pum.yaml +0 -3
- pum-1.1.14/test/data/min_version/changelogs/1.2.3/roles.sql +0 -9
- pum-1.1.14/test/data/multiple_changelogs/changelogs/1.2.3/multiple_changelogs.sql +0 -9
- pum-1.1.14/test/data/multiple_changelogs/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/multiple_changelogs/changelogs/1.3.0/add_created_by_column.sql +0 -2
- pum-1.1.14/test/data/multiple_changelogs/changelogs/2.0.0/create_second_table.sql +0 -4
- pum-1.1.14/test/data/multiple_changelogs/changelogs/2.0.0/create_third_table.sql +0 -4
- pum-1.1.14/test/data/parameters/.pum.yaml +0 -16
- pum-1.1.14/test/data/parameters/changelogs/1.2.3/parameters.sql +0 -15
- pum-1.1.14/test/data/pre_post_python/.pum.yaml +0 -8
- pum-1.1.14/test/data/pre_post_python/changelogs/1.2.3/pre_post_python.sql +0 -9
- pum-1.1.14/test/data/pre_post_python/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/pre_post_python/post/create_schema.sql +0 -2
- pum-1.1.14/test/data/pre_post_python/post/create_view.py +0 -15
- pum-1.1.14/test/data/pre_post_python/pre/drop_view.sql +0 -3
- pum-1.1.14/test/data/pre_post_python_local_import/.pum.yaml +0 -8
- pum-1.1.14/test/data/pre_post_python_local_import/changelogs/1.2.3/pre_post_python_local_import.sql +0 -9
- pum-1.1.14/test/data/pre_post_python_local_import/post/create_schema.sql +0 -2
- pum-1.1.14/test/data/pre_post_python_local_import/post/create_view.py +0 -12
- pum-1.1.14/test/data/pre_post_python_local_import/post/folder/my_module.py +0 -8
- pum-1.1.14/test/data/pre_post_python_local_import/pre/drop_view.sql +0 -3
- pum-1.1.14/test/data/pre_post_python_parameters/.pum.yaml +0 -13
- pum-1.1.14/test/data/pre_post_python_parameters/changelogs/1.2.3/pre_post_python_parameters.sql +0 -9
- pum-1.1.14/test/data/pre_post_python_parameters/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/pre_post_python_parameters/post/create_schema.sql +0 -2
- pum-1.1.14/test/data/pre_post_python_parameters/post/create_view.py +0 -18
- pum-1.1.14/test/data/pre_post_python_parameters/pre/drop_view.sql +0 -3
- pum-1.1.14/test/data/pre_post_python_parameters_broken/.pum.yaml +0 -8
- pum-1.1.14/test/data/pre_post_python_parameters_broken/changelogs/1.2.3/pre_post_python_parameters_broken.sql +0 -9
- pum-1.1.14/test/data/pre_post_python_parameters_broken/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/pre_post_python_parameters_broken/post/create_schema.sql +0 -2
- pum-1.1.14/test/data/pre_post_python_parameters_broken/post/create_view.py +0 -24
- pum-1.1.14/test/data/pre_post_python_parameters_broken/pre/drop_view.sql +0 -3
- pum-1.1.14/test/data/pre_post_sql_code/.pum.yaml +0 -12
- pum-1.1.14/test/data/pre_post_sql_code/changelogs/1.2.3/pre_post_sql_code.sql +0 -9
- pum-1.1.14/test/data/pre_post_sql_code/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/pre_post_sql_code/post/create_view.sql +0 -0
- pum-1.1.14/test/data/pre_post_sql_code/pre/drop_view.sql +0 -0
- pum-1.1.14/test/data/pre_post_sql_files/.pum.yaml +0 -7
- pum-1.1.14/test/data/pre_post_sql_files/changelogs/1.2.3/pre_post_sql_files.sql +0 -9
- pum-1.1.14/test/data/pre_post_sql_files/changelogs/1.2.4/rename_created_date.sql +0 -2
- pum-1.1.14/test/data/pre_post_sql_files/post/create_view.sql +0 -7
- pum-1.1.14/test/data/pre_post_sql_files/pre/drop_view.sql +0 -3
- pum-1.1.14/test/data/roles/.pum.yaml +0 -16
- pum-1.1.14/test/data/roles/changelogs/1.2.3/roles.sql +0 -19
- pum-1.1.14/test/data/single_changelog/changelogs/1.2.3/single_changelog.sql +0 -9
- pum-1.1.14/test/test_checker.py.disabled +0 -348
- pum-1.1.14/test/test_pum.sh +0 -30
- {pum-1.1.14 → pum-1.1.15}/LICENSE +0 -0
- {pum-1.1.14 → pum-1.1.15}/README.md +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/__init__.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/changelog.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/checker.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/cli.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/config_model.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/dependency_handler.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/dumper.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/exceptions.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/hook.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/info.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/parameter.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/pum_config.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/role_manager.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/schema_migrations.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/sql_content.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum/upgrader.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum.egg-info/dependency_links.txt +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum.egg-info/entry_points.txt +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum.egg-info/requires.txt +0 -0
- {pum-1.1.14 → pum-1.1.15}/pum.egg-info/top_level.txt +0 -0
- {pum-1.1.14 → pum-1.1.15}/requirements/base.txt +0 -0
- {pum-1.1.14 → pum-1.1.15}/requirements/development.txt +0 -0
- {pum-1.1.14 → pum-1.1.15}/setup.cfg +0 -0
- {pum-1.1.14 → pum-1.1.15}/test/test_changelog.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/test/test_config.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/test/test_dumper.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/test/test_roles.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/test/test_schema_migrations.py +0 -0
- {pum-1.1.14 → pum-1.1.15}/test/test_upgrader.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pum
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.15
|
|
4
4
|
Summary: Pum stands for "Postgres Upgrades Manager". It is a Database migration management tool very similar to flyway-db or Liquibase, based on metadata tables.
|
|
5
5
|
Author-email: Denis Rouzaud <denis@opengis.ch>
|
|
6
6
|
License-Expression: GPL-2.0-or-later
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pum
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.15
|
|
4
4
|
Summary: Pum stands for "Postgres Upgrades Manager". It is a Database migration management tool very similar to flyway-db or Liquibase, based on metadata tables.
|
|
5
5
|
Author-email: Denis Rouzaud <denis@opengis.ch>
|
|
6
6
|
License-Expression: GPL-2.0-or-later
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
LICENSE
|
|
2
|
+
README.md
|
|
3
|
+
pyproject.toml
|
|
4
|
+
pum/__init__.py
|
|
5
|
+
pum/changelog.py
|
|
6
|
+
pum/checker.py
|
|
7
|
+
pum/cli.py
|
|
8
|
+
pum/config_model.py
|
|
9
|
+
pum/dependency_handler.py
|
|
10
|
+
pum/dumper.py
|
|
11
|
+
pum/exceptions.py
|
|
12
|
+
pum/hook.py
|
|
13
|
+
pum/info.py
|
|
14
|
+
pum/parameter.py
|
|
15
|
+
pum/pum_config.py
|
|
16
|
+
pum/role_manager.py
|
|
17
|
+
pum/schema_migrations.py
|
|
18
|
+
pum/sql_content.py
|
|
19
|
+
pum/upgrader.py
|
|
20
|
+
pum.egg-info/PKG-INFO
|
|
21
|
+
pum.egg-info/SOURCES.txt
|
|
22
|
+
pum.egg-info/dependency_links.txt
|
|
23
|
+
pum.egg-info/entry_points.txt
|
|
24
|
+
pum.egg-info/requires.txt
|
|
25
|
+
pum.egg-info/top_level.txt
|
|
26
|
+
requirements/base.txt
|
|
27
|
+
requirements/development.txt
|
|
28
|
+
test/test_changelog.py
|
|
29
|
+
test/test_config.py
|
|
30
|
+
test/test_dumper.py
|
|
31
|
+
test/test_roles.py
|
|
32
|
+
test/test_schema_migrations.py
|
|
33
|
+
test/test_upgrader.py
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
[build-system]
|
|
2
|
-
requires = ["setuptools>=61.0", "
|
|
2
|
+
requires = ["setuptools>=61.0", "wheel", "setuptools-git-versioning"]
|
|
3
3
|
build-backend = "setuptools.build_meta"
|
|
4
4
|
|
|
5
5
|
[project]
|
|
@@ -38,7 +38,7 @@ packages = ["pum"]
|
|
|
38
38
|
|
|
39
39
|
[tool.setuptools-git-versioning]
|
|
40
40
|
enabled = true
|
|
41
|
-
starting_version = "
|
|
41
|
+
starting_version = "0.0.0"
|
|
42
42
|
|
|
43
43
|
[tool.setuptools.dynamic]
|
|
44
44
|
readme = {file = ["README.md"], content-type = "text/markdown"}
|
pum-1.1.14/.ci/setup_db.sh
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env bash
|
|
2
|
-
|
|
3
|
-
export PGUSER=postgres
|
|
4
|
-
|
|
5
|
-
# determine the pg_service conf file location
|
|
6
|
-
if [ -z "$PGSYSCONFDIR" ]; then
|
|
7
|
-
PGSERVICE_FILE="$HOME/.pg_service.conf"
|
|
8
|
-
else
|
|
9
|
-
PGSERVICE_FILE="$PGSYSCONFDIR/pg_service.conf"
|
|
10
|
-
fi
|
|
11
|
-
|
|
12
|
-
pgsrv="pum_test"
|
|
13
|
-
echo "Adding service ${pgsrv} to $PGSERVICE_FILE"
|
|
14
|
-
printf "[${pgsrv}]\nhost=localhost\ndbname=${pgsrv}\nuser=postgres\npassword=postgres\n\n" >> "$PGSERVICE_FILE"
|
|
15
|
-
|
|
16
|
-
psql -c "DROP DATABASE IF EXISTS ${pgsrv};" "service=${pgsrv} dbname=postgres"
|
|
17
|
-
psql -c "CREATE DATABASE ${pgsrv};" "service=${pgsrv} dbname=postgres"
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
version: 2
|
|
2
|
-
updates:
|
|
3
|
-
- package-ecosystem: pip
|
|
4
|
-
directory: "/requirements"
|
|
5
|
-
schedule:
|
|
6
|
-
interval: monthly
|
|
7
|
-
time: "04:00"
|
|
8
|
-
timezone: Europe/Paris
|
|
9
|
-
|
|
10
|
-
- package-ecosystem: pip
|
|
11
|
-
directory: "/docs"
|
|
12
|
-
schedule:
|
|
13
|
-
interval: monthly
|
|
14
|
-
time: "04:00"
|
|
15
|
-
timezone: Europe/Paris
|
|
16
|
-
|
|
17
|
-
- package-ecosystem: "github-actions"
|
|
18
|
-
directory: "/"
|
|
19
|
-
schedule:
|
|
20
|
-
interval: "monthly"
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
name: 🚀 Deploying to pypi
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
tags:
|
|
6
|
-
- "*"
|
|
7
|
-
workflow_dispatch:
|
|
8
|
-
workflow_call:
|
|
9
|
-
|
|
10
|
-
jobs:
|
|
11
|
-
build-python-wheel:
|
|
12
|
-
name: "🐍 Python Wheel"
|
|
13
|
-
uses: ./.github/workflows/wheel.yml
|
|
14
|
-
secrets: inherit
|
|
15
|
-
|
|
16
|
-
release-pypi:
|
|
17
|
-
name: "🐍 Release on PyPI"
|
|
18
|
-
runs-on: ubuntu-latest
|
|
19
|
-
needs: [build-python-wheel]
|
|
20
|
-
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
|
|
21
|
-
environment:
|
|
22
|
-
name: pypi
|
|
23
|
-
url: https://pypi.org/p/${{ github.event.repository.name }}
|
|
24
|
-
permissions:
|
|
25
|
-
id-token: write
|
|
26
|
-
contents: write
|
|
27
|
-
|
|
28
|
-
steps:
|
|
29
|
-
- name: Retrieve artifact from Python build
|
|
30
|
-
uses: actions/download-artifact@v6
|
|
31
|
-
with:
|
|
32
|
-
name: python_wheel
|
|
33
|
-
path: dist/
|
|
34
|
-
|
|
35
|
-
- name: upload release asset
|
|
36
|
-
env:
|
|
37
|
-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
38
|
-
run: gh release upload --repo ${{ github.repository_owner }}/${{ github.event.repository.name }} ${{ github.ref_name }} "dist/${{ github.event.repository.name }}-${{ github.ref_name }}.tar.gz"
|
|
39
|
-
|
|
40
|
-
- name: Deploy to PyPI
|
|
41
|
-
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
name: "📚 Documentation Builder"
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- main
|
|
7
|
-
- docs
|
|
8
|
-
paths:
|
|
9
|
-
- .github/workflows/docs.yml
|
|
10
|
-
- pum/**/*.py
|
|
11
|
-
- docs/**/*
|
|
12
|
-
tags:
|
|
13
|
-
- "*"
|
|
14
|
-
|
|
15
|
-
pull_request:
|
|
16
|
-
branches:
|
|
17
|
-
- main
|
|
18
|
-
paths:
|
|
19
|
-
- .github/workflows/docs.yml
|
|
20
|
-
- pum/**/*.py
|
|
21
|
-
- docs/**/*
|
|
22
|
-
|
|
23
|
-
# Allow one concurrent deployment
|
|
24
|
-
concurrency:
|
|
25
|
-
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
|
|
26
|
-
cancel-in-progress: true
|
|
27
|
-
|
|
28
|
-
jobs:
|
|
29
|
-
build-docs:
|
|
30
|
-
|
|
31
|
-
runs-on: ubuntu-latest
|
|
32
|
-
|
|
33
|
-
steps:
|
|
34
|
-
- name: Get source code
|
|
35
|
-
uses: actions/checkout@v5
|
|
36
|
-
|
|
37
|
-
- uses: actions/setup-python@v6
|
|
38
|
-
with:
|
|
39
|
-
python-version: '3.12'
|
|
40
|
-
|
|
41
|
-
- name: Install dependencies
|
|
42
|
-
run: |
|
|
43
|
-
python -m pip install -r requirements/base.txt
|
|
44
|
-
python -m pip install -r docs/requirements.txt
|
|
45
|
-
|
|
46
|
-
- name: Install pum
|
|
47
|
-
run: python -m pip install .
|
|
48
|
-
|
|
49
|
-
- name: Update CLI docs
|
|
50
|
-
run: ./docs/update_cli_docs.py
|
|
51
|
-
|
|
52
|
-
- name: Build documentation
|
|
53
|
-
run: mkdocs build -f docs/mkdocs.yml
|
|
54
|
-
|
|
55
|
-
- uses: actions/upload-artifact@v5
|
|
56
|
-
if: ${{ github.event_name == 'pull_request' }}
|
|
57
|
-
with:
|
|
58
|
-
name: docs
|
|
59
|
-
path: docs/site
|
|
60
|
-
if-no-files-found: error
|
|
61
|
-
|
|
62
|
-
- name: Deploy to GitHub Pages
|
|
63
|
-
if: contains(fromJSON('["push", "workflow_dispatch"]'), github.event_name)
|
|
64
|
-
working-directory: docs
|
|
65
|
-
run: mkdocs gh-deploy --force
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
name: 🧪 Testing
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- main
|
|
7
|
-
pull_request:
|
|
8
|
-
branches:
|
|
9
|
-
- main
|
|
10
|
-
|
|
11
|
-
jobs:
|
|
12
|
-
build:
|
|
13
|
-
name: Testing (py${{ matrix.python }}-pg${{ matrix.postgres }})
|
|
14
|
-
|
|
15
|
-
strategy:
|
|
16
|
-
fail-fast: false
|
|
17
|
-
matrix:
|
|
18
|
-
os:
|
|
19
|
-
- ubuntu-latest
|
|
20
|
-
python:
|
|
21
|
-
- "3.10"
|
|
22
|
-
postgres: # dockerhub tags
|
|
23
|
-
- "13-3.5"
|
|
24
|
-
|
|
25
|
-
runs-on: ${{ matrix.os }}
|
|
26
|
-
|
|
27
|
-
env:
|
|
28
|
-
PGSYSCONFDIR: .
|
|
29
|
-
|
|
30
|
-
services:
|
|
31
|
-
postgres:
|
|
32
|
-
image: postgis/postgis:${{ matrix.postgres }}
|
|
33
|
-
ports:
|
|
34
|
-
- 5432:5432
|
|
35
|
-
env:
|
|
36
|
-
POSTGRES_USER: postgres
|
|
37
|
-
POSTGRES_PASSWORD: postgres
|
|
38
|
-
# Set health checks to wait until postgres has started
|
|
39
|
-
options: >-
|
|
40
|
-
--health-cmd pg_isready
|
|
41
|
-
--health-interval 10s
|
|
42
|
-
--health-timeout 5s
|
|
43
|
-
--health-retries 5
|
|
44
|
-
|
|
45
|
-
steps:
|
|
46
|
-
- uses: actions/checkout@v5
|
|
47
|
-
with:
|
|
48
|
-
fetch-tags: true
|
|
49
|
-
|
|
50
|
-
- name: Set up Python
|
|
51
|
-
uses: actions/setup-python@v6
|
|
52
|
-
with:
|
|
53
|
-
python-version: ${{ matrix.python }}
|
|
54
|
-
|
|
55
|
-
- name: Install dependencies
|
|
56
|
-
run: |
|
|
57
|
-
python -m pip install -r requirements/base.txt
|
|
58
|
-
python -m pip install -r requirements/development.txt
|
|
59
|
-
|
|
60
|
-
- name: Install pum
|
|
61
|
-
run: python -m pip install .
|
|
62
|
-
|
|
63
|
-
- name: Setup db
|
|
64
|
-
shell: bash
|
|
65
|
-
run: ./.ci/setup_db.sh
|
|
66
|
-
|
|
67
|
-
- name: Run base tests
|
|
68
|
-
run: nose2 -v
|
|
69
|
-
|
|
70
|
-
# - name: Run migrations tests
|
|
71
|
-
# shell: bash
|
|
72
|
-
# run: ./test/test_pum.sh
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
name: "🐍 Python Wheel"
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
pull_request:
|
|
5
|
-
branches:
|
|
6
|
-
- main
|
|
7
|
-
push:
|
|
8
|
-
branches:
|
|
9
|
-
- main
|
|
10
|
-
workflow_dispatch:
|
|
11
|
-
workflow_call:
|
|
12
|
-
|
|
13
|
-
jobs:
|
|
14
|
-
build-wheel:
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
steps:
|
|
17
|
-
- name: Get source code
|
|
18
|
-
uses: actions/checkout@v5
|
|
19
|
-
|
|
20
|
-
- name: Set up Python
|
|
21
|
-
uses: actions/setup-python@v6
|
|
22
|
-
with:
|
|
23
|
-
python-version: "3.10"
|
|
24
|
-
cache: "pip"
|
|
25
|
-
cache-dependency-path: "requirements/base.txt"
|
|
26
|
-
|
|
27
|
-
- name: Install project requirements
|
|
28
|
-
run: |
|
|
29
|
-
python -m pip install -U pip setuptools wheel
|
|
30
|
-
python -m pip install -U build
|
|
31
|
-
|
|
32
|
-
- name: Install project as a package
|
|
33
|
-
run: python -m pip install -e .
|
|
34
|
-
|
|
35
|
-
- name: Build a binary wheel and a source tarball
|
|
36
|
-
run: python -m build .
|
|
37
|
-
|
|
38
|
-
- uses: actions/upload-artifact@v5
|
|
39
|
-
with:
|
|
40
|
-
name: python_wheel
|
|
41
|
-
path: dist/*
|
|
42
|
-
if-no-files-found: error
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
name: 🪟 Winows Testing
|
|
2
|
-
|
|
3
|
-
on: [push, pull_request]
|
|
4
|
-
|
|
5
|
-
jobs:
|
|
6
|
-
build:
|
|
7
|
-
name: Testing Windows
|
|
8
|
-
|
|
9
|
-
strategy:
|
|
10
|
-
fail-fast: false
|
|
11
|
-
matrix:
|
|
12
|
-
os: [windows-latest]
|
|
13
|
-
pg_major: [13]
|
|
14
|
-
|
|
15
|
-
runs-on: ${{ matrix.os }}
|
|
16
|
-
|
|
17
|
-
env:
|
|
18
|
-
PGSYSCONFDIR: .
|
|
19
|
-
|
|
20
|
-
steps:
|
|
21
|
-
- uses: actions/checkout@v5
|
|
22
|
-
|
|
23
|
-
- name: Set up Python
|
|
24
|
-
uses: actions/setup-python@v6
|
|
25
|
-
with:
|
|
26
|
-
python-version: "3.x"
|
|
27
|
-
|
|
28
|
-
# Adapted from https://github.com/npgsql/npgsql/actions/runs/33087254/workflow#L28-L66
|
|
29
|
-
# alternatively we could use postgres-windows docker images (stellirin/postgres-windows:9.6)
|
|
30
|
-
- name: Start PostgreSQL ${{ matrix.pg_major }} (Windows)
|
|
31
|
-
if: startsWith(matrix.os, 'windows')
|
|
32
|
-
run: |
|
|
33
|
-
# Find EnterpriseDB version number
|
|
34
|
-
EDB_VERSION=$(\
|
|
35
|
-
curl -Ls 'http://sbp.enterprisedb.com/applications.xml' |
|
|
36
|
-
sed -n "\#<id>postgresql_${{ matrix.pg_major }}</id>#{n;p;n;p;}" |
|
|
37
|
-
sed -n "\#<platform>windows-x64</platform>#{n;p;}" |
|
|
38
|
-
sed -E 's#.*<version>([^<]+)</version>#\1#')
|
|
39
|
-
# Install PostgreSQL
|
|
40
|
-
echo "Installing PostgreSQL (version: ${EDB_VERSION})"
|
|
41
|
-
curl -o pgsql.zip -L https://get.enterprisedb.com/postgresql/postgresql-${EDB_VERSION}-windows-x64-binaries.zip
|
|
42
|
-
unzip pgsql.zip -x 'pgsql/include/**' 'pgsql/doc/**' 'pgsql/pgAdmin 4/**' 'pgsql/StackBuilder/**'
|
|
43
|
-
# Start PostgreSQL
|
|
44
|
-
pgsql/bin/initdb -D pgsql/PGDATA -E UTF8 -U postgres
|
|
45
|
-
pgsql/bin/pg_ctl -D pgsql/PGDATA -l logfile start
|
|
46
|
-
shell: bash
|
|
47
|
-
|
|
48
|
-
- name: Install dependencies
|
|
49
|
-
run: |
|
|
50
|
-
python -m pip install -r requirements/base.txt
|
|
51
|
-
python -m pip install -r requirements/development.txt
|
|
52
|
-
|
|
53
|
-
- name: Install pum
|
|
54
|
-
run: python -m pip install .
|
|
55
|
-
|
|
56
|
-
# see https://github.community/t5/GitHub-Actions/Append-PATH-on-Windows/m-p/42873/highlight/true#M5155
|
|
57
|
-
- name: Add psql/bin path
|
|
58
|
-
env:
|
|
59
|
-
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
|
|
60
|
-
run: echo "##[add-path].\pgsql\bin"
|
|
61
|
-
|
|
62
|
-
- name: Setup db
|
|
63
|
-
shell: bash
|
|
64
|
-
run: ./.ci/setup_db.sh
|
|
65
|
-
|
|
66
|
-
- name: Run base tests
|
|
67
|
-
run: nose2 -v
|
|
68
|
-
|
|
69
|
-
# - name: Run migrations tests
|
|
70
|
-
# shell: bash
|
|
71
|
-
# run: ./test/test_pum.sh
|
pum-1.1.14/.gitignore
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
fail_fast: false
|
|
2
|
-
repos:
|
|
3
|
-
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
4
|
-
rev: v5.0.0
|
|
5
|
-
hooks:
|
|
6
|
-
- id: check-added-large-files
|
|
7
|
-
args: ["--maxkb=600"]
|
|
8
|
-
- id: check-case-conflict
|
|
9
|
-
- id: check-toml
|
|
10
|
-
- id: check-xml
|
|
11
|
-
- id: check-yaml
|
|
12
|
-
- id: detect-private-key
|
|
13
|
-
- id: end-of-file-fixer
|
|
14
|
-
- id: fix-byte-order-marker
|
|
15
|
-
- id: trailing-whitespace
|
|
16
|
-
args: [--markdown-linebreak-ext=md]
|
|
17
|
-
|
|
18
|
-
# Ruff: linter, import sorter, autoflake, pyupgrade replacement
|
|
19
|
-
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
20
|
-
rev: v0.11.8
|
|
21
|
-
hooks:
|
|
22
|
-
- id: ruff
|
|
23
|
-
args:
|
|
24
|
-
- --fix
|
|
25
|
-
- --target-version=py310
|
|
26
|
-
types_or:
|
|
27
|
-
- python
|
|
28
|
-
- pyi
|
|
29
|
-
- id: ruff-format
|
|
30
|
-
args:
|
|
31
|
-
- --line-length=100
|
|
32
|
-
- --target-version=py310
|
|
33
|
-
types_or:
|
|
34
|
-
- python
|
|
35
|
-
- pyi
|
|
36
|
-
|
|
37
|
-
ci:
|
|
38
|
-
autofix_prs: true
|
|
39
|
-
autoupdate_schedule: quarterly
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.Changelog
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.DumpFormat
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.Dumper
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.ParameterDefinition
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.ParameterType
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.Permission
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.PermissionType
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.PumConfig
|
pum-1.1.14/docs/docs/api/role.md
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.Role
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.RoleManager
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.SchemaMigrations
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
::: pum.Upgrader
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
usage: create_cli_help.py check [-h]
|
|
2
|
-
- `[-i {tables,columns,constraints,views,sequences,indexes,triggers,functions,rules} [{tables,columns,constraints,views,sequences,indexes,triggers,functions,rules} ...]]`
|
|
3
|
-
- `[-N EXCLUDE_SCHEMA] [-P EXCLUDE_FIELD_PATTERN] [-o OUTPUT_FILE]`
|
|
4
|
-
|
|
5
|
-
### options:
|
|
6
|
-
- `-h, --help`: show this help message and exit
|
|
7
|
-
- `-i {tables,columns,constraints,views,sequences,indexes,triggers,functions,rules} [{tables,columns,constraints,views,sequences,indexes,triggers,functions,rules} ...], --ignore {tables,columns,constraints,views,sequences,indexes,triggers,functions,rules} [{tables,columns,constraints,views,sequences,indexes,triggers,functions,rules} ...]`
|
|
8
|
-
- `Elements to be ignored`
|
|
9
|
-
- `-N EXCLUDE_SCHEMA, --exclude-schema EXCLUDE_SCHEMA`
|
|
10
|
-
- `Schema to be ignored.`
|
|
11
|
-
- `-P EXCLUDE_FIELD_PATTERN, --exclude-field-pattern EXCLUDE_FIELD_PATTERN`
|
|
12
|
-
- `Fields to be ignored based on a pattern compatible with SQL LIKE.`
|
|
13
|
-
- `-o OUTPUT_FILE, --output_file OUTPUT_FILE`
|
|
14
|
-
- `Output file`
|
pum-1.1.14/docs/docs/cli/dump.md
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
usage: create_cli_help.py dump [-h] [-f {DumpFormat.CUSTOM,DumpFormat.PLAIN}] [-N EXCLUDE_SCHEMA] file
|
|
2
|
-
|
|
3
|
-
### positional arguments:
|
|
4
|
-
- `file`: The backup file
|
|
5
|
-
|
|
6
|
-
### options:
|
|
7
|
-
- `-h, --help`: show this help message and exit
|
|
8
|
-
- `-f {DumpFormat.CUSTOM,DumpFormat.PLAIN}, --format {DumpFormat.CUSTOM,DumpFormat.PLAIN}`
|
|
9
|
-
- `Dump format. Choices: ['custom', 'plain']. Default: plain.`
|
|
10
|
-
- `-N EXCLUDE_SCHEMA, --exclude-schema EXCLUDE_SCHEMA`
|
|
11
|
-
- `Schema to be ignored.`
|
pum-1.1.14/docs/docs/cli/info.md
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
usage: create_cli_help.py install [-h] [-p PARAMETER PARAMETER] [--max-version MAX_VERSION] [-r] [-g]
|
|
2
|
-
|
|
3
|
-
### options:
|
|
4
|
-
- `-h, --help`: show this help message and exit
|
|
5
|
-
- `-p PARAMETER PARAMETER, --parameter PARAMETER PARAMETER`
|
|
6
|
-
- `Assign variable for running SQL deltas. Format is name value.`
|
|
7
|
-
- `--max-version MAX_VERSION`
|
|
8
|
-
- `maximum version to install`
|
|
9
|
-
- `-r, --roles`: Create roles
|
|
10
|
-
- `-g, --grant`: Grant permissions to roles
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
usage: create_cli_help.py restore [-h] [-x] [-N EXCLUDE_SCHEMA] file
|
|
2
|
-
|
|
3
|
-
### positional arguments:
|
|
4
|
-
- `file`: The backup file
|
|
5
|
-
|
|
6
|
-
### options:
|
|
7
|
-
- `-h, --help`: show this help message and exit
|
|
8
|
-
- `-x`: ignore pg_restore errors
|
|
9
|
-
- `-N EXCLUDE_SCHEMA, --exclude-schema EXCLUDE_SCHEMA`
|
|
10
|
-
- `Schema to be ignored.`
|
pum-1.1.14/docs/docs/cli/role.md
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
usage: create_cli_help.py upgrade [-h] [-u MAX_VERSION] [-p PARAMETER PARAMETER]
|
|
2
|
-
|
|
3
|
-
### options:
|
|
4
|
-
- `-h, --help`: show this help message and exit
|
|
5
|
-
- `-u MAX_VERSION, --max-version MAX_VERSION`
|
|
6
|
-
- `upper bound limit version`
|
|
7
|
-
- `-p PARAMETER PARAMETER, --parameter PARAMETER PARAMETER`
|
|
8
|
-
- `Assign variable for running SQL deltas. Format is: name value.`
|
pum-1.1.14/docs/docs/cli.md
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
usage: create_cli_help.py [-h] [-c CONFIG_FILE] -s PG_SERVICE [-d DIR] [-v] [--version]
|
|
2
|
-
- `{info,install,role,check,dump,restore,baseline,upgrade} ...`
|
|
3
|
-
|
|
4
|
-
### options:
|
|
5
|
-
- `-h, --help`: show this help message and exit
|
|
6
|
-
- `-c CONFIG_FILE, --config_file CONFIG_FILE`
|
|
7
|
-
- `set the config file. Default: .pum.yaml`
|
|
8
|
-
- `-s PG_SERVICE, --pg-service PG_SERVICE`
|
|
9
|
-
- `Name of the postgres service`
|
|
10
|
-
- `-d DIR, --dir DIR`: Directory or URL of the module. Default: .
|
|
11
|
-
- `-v, --verbose`: Increase output verbosity (e.g. -v, -vv)
|
|
12
|
-
- `--version`: Show program's version number and exit.
|
|
13
|
-
|
|
14
|
-
### commands:
|
|
15
|
-
- `valid pum commands`
|
|
16
|
-
|
|
17
|
-
- `{info,install,role,check,dump,restore,baseline,upgrade}`
|
|
18
|
-
- `info`: show info about schema migrations history.
|
|
19
|
-
- `install`: Installs the module.
|
|
20
|
-
- `role`: manage roles in the database
|
|
21
|
-
- `check`: check the differences between two databases
|
|
22
|
-
- `dump`: dump a Postgres database
|
|
23
|
-
- `restore`: restore a Postgres database from a dump file
|
|
24
|
-
- `baseline`: Create upgrade information table and set baseline
|
|
25
|
-
- `upgrade`: upgrade db
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
# Configuration file .pum.yaml
|
|
2
|
-
|
|
3
|
-
## Introduction
|
|
4
|
-
|
|
5
|
-
In the config file `.pum.yaml`, you can define, with the YAML syntax:
|
|
6
|
-
|
|
7
|
-
* `changelogs_directory`: the directory with the changelogs files.
|
|
8
|
-
* `parameters`: the definition of parameters for the migration.
|
|
9
|
-
* `migrations_hooks`: the `pre` and `post` migrations hooks.
|
|
10
|
-
|
|
11
|
-
For example:
|
|
12
|
-
```yaml
|
|
13
|
-
|
|
14
|
-
changelogs_directory: my_custom_directory
|
|
15
|
-
|
|
16
|
-
parameters:
|
|
17
|
-
- name: SRID
|
|
18
|
-
type: integer
|
|
19
|
-
default: 2056
|
|
20
|
-
description: Coordinate Reference System (CRS) to use for the data. This is used for the geometry column in the database. Default is 2056 (CH1903+ / LV95).
|
|
21
|
-
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
## Complete documentation
|
|
25
|
-
|
|
26
|
-
For detailed configuration options, see the [Configuration Model](configuration/config_model.md).
|