mirror of
https://github.com/brain-tec/account_ebics.git
synced 2026-11-06 10:00:39 +00:00
[IMP] addons-repo-template v9.2.1
This commit is contained in:
1 parent
e4c40c373e
commit
296695f97a
21 files changed
+188
-291
No files matched your search
@@ -24,6 +24,6 @@ jobs:
|
||||
- name: Add Noviat CI Tools to PATH
|
||||
run: |
|
||||
git clone https://github.com/Noviat-CI/noviat-ci-tools.git /opt/noviat-ci-tools
|
||||
echo "/opt/noviat-ci-tools" >> $GITHUB_PATH
|
||||
echo "/opt/noviat-ci-tools" >> "$GITHUB_PATH"
|
||||
- name: Check module version bump
|
||||
run: check_module_version_bump
|
||||
@@ -23,7 +23,7 @@ jobs:
|
||||
cache: 'pip'
|
||||
cache-dependency-path: '.pre-commit-config.yaml'
|
||||
- name: Get python version
|
||||
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
|
||||
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> "$GITHUB_ENV"
|
||||
- uses: actions/cache@v6
|
||||
with:
|
||||
path: ~/.cache/pre-commit
|
||||
|
||||
+32
-34
@@ -20,11 +20,11 @@ jobs:
|
||||
- uses: actions/checkout@v7
|
||||
- run: |
|
||||
for reqfile in requirements.txt test-requirements.txt ; do
|
||||
if [ -f ${reqfile} ] ; then
|
||||
if [ -f "${reqfile}" ] ; then
|
||||
result=0
|
||||
# reject non-comment lines that contain a / (i.e. URLs, relative paths)
|
||||
# unless they have a "# SKIP TEST" comment
|
||||
grep "^[^#].*/" ${reqfile} | grep -v "# SKIP TEST" || result=$?
|
||||
grep "^[^#].*/" "${reqfile}" | grep -v "# SKIP TEST" || result=$?
|
||||
if [ $result -eq 0 ] ; then
|
||||
echo "Unreleased dependencies found in ${reqfile}."
|
||||
exit 1
|
||||
@@ -33,7 +33,11 @@ jobs:
|
||||
done
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
container: ${{ matrix.container }}
|
||||
container:
|
||||
image: ${{ matrix.container }}
|
||||
credentials:
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.PRIVATE_TOKEN }}
|
||||
name: ${{ matrix.name }}
|
||||
permissions:
|
||||
pull-requests: write
|
||||
@@ -42,12 +46,12 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- container: ghcr.io/oca/oca-ci/py3.10-odoo18.0:latest
|
||||
- container: ghcr.io/noviat-ci/odoo-ci:18.0-stable
|
||||
name: test with Odoo Community
|
||||
odoo_enterprise : 0
|
||||
exclude_modules : "account_asset"
|
||||
exclude: "account_ebics_batch_payment,account_ebics_oe"
|
||||
- container: ghcr.io/oca/oca-ci/py3.10-odoo18.0:latest
|
||||
skip: "account_ebics_batch_payment,account_ebics_oe"
|
||||
- container: ghcr.io/noviat-ci/odoo-ci:18.0-stable
|
||||
name: test with Odoo Enterprise
|
||||
odoo_enterprise : 1
|
||||
exclude_modules : "account_asset"
|
||||
@@ -73,49 +77,43 @@ jobs:
|
||||
TOKEN: ${{ secrets.PRIVATE_TOKEN }}
|
||||
run: |
|
||||
git config --global http.https://github.com/.extraheader "AUTHORIZATION: basic $(printf 'x-access-token:%s' "$TOKEN" | base64 -w0)"
|
||||
- name: Set pip constraints (pyOpenSSL / cryptography)
|
||||
- name: Show the CI image age
|
||||
run: |
|
||||
cat > /tmp/constraints.txt <<'EOF'
|
||||
pyOpenSSL == 22.1.0
|
||||
cryptography == 38.0.4
|
||||
EOF
|
||||
echo "PIP_CONSTRAINT=/tmp/constraints.txt" >> $GITHUB_ENV
|
||||
- name: Upgrade pip in container
|
||||
run: python -m pip install --upgrade pip
|
||||
- name: Install Odoo upgrade util
|
||||
run: python -m pip install git+https://github.com/odoo/upgrade-util@master
|
||||
- name: Add Noviat CI Tools to PATH
|
||||
run: |
|
||||
git clone https://github.com/Noviat-CI/noviat-ci-tools.git /opt/noviat-ci-tools
|
||||
echo "/opt/noviat-ci-tools" >> $GITHUB_PATH
|
||||
- name: Clone Odoo Enterprise
|
||||
if: ${{ matrix.odoo_enterprise == 1 }}
|
||||
run : |
|
||||
git clone https://github.com/odoo/enterprise.git --depth 1 -b 18.0 /opt/enterprise
|
||||
age=$(( ( $(date -u +%s) - $(date -u -d "$NOVIAT_CI_IMAGE_BUILD_DATE" +%s) ) / 86400 ))
|
||||
echo "Image $NOVIAT_CI_ODOO_VERSION built $NOVIAT_CI_IMAGE_BUILD_DATE ($age days old)" | tee -a "$GITHUB_STEP_SUMMARY"
|
||||
- name: Clone Noviat Dependencies
|
||||
run: clone_oca_dependencies_by_noviat
|
||||
- name: Create addons path
|
||||
run: |
|
||||
mkdir -p ${{ env.INSTALL_ADDONS_DIR }}/setup
|
||||
find $(realpath $ADDONS_DIR) $(realpath ${{ env.ADDITIONAL_ADDONS_DIR }}) -name __manifest__.py -exec sh -c 'ln -s "$(dirname "$0")" "${{ env.INSTALL_ADDONS_DIR }}"' {} \;
|
||||
find $(realpath $ADDONS_DIR) $(realpath ${{ env.ADDITIONAL_ADDONS_DIR }}) -iwholename '*/setup/*/setup.py' -exec sh -c 'ln -s "$(dirname "$0")" "${{ env.INSTALL_ADDONS_DIR }}/setup"' {} \;
|
||||
if [ -n ${{ matrix.exclude}} ]
|
||||
mkdir -p "$INSTALL_ADDONS_DIR/setup"
|
||||
find "$(realpath "$ADDONS_DIR")" "$(realpath "$ADDITIONAL_ADDONS_DIR")" -name __manifest__.py -exec sh -c 'ln -s "$(dirname "$0")" "$1"' {} "$INSTALL_ADDONS_DIR" \;
|
||||
find "$(realpath "$ADDONS_DIR")" "$(realpath "$ADDITIONAL_ADDONS_DIR")" -iwholename '*/setup/*/setup.py' -exec sh -c 'ln -s "$(dirname "$0")" "$1/setup"' {} "$INSTALL_ADDONS_DIR" \;
|
||||
# EXCLUDE (from matrix.exclude) only exists with rebel module groups
|
||||
if [ -n "${EXCLUDE:-}" ]
|
||||
then
|
||||
remove_excluded_modules ${{ env.INSTALL_ADDONS_DIR }} ${{ matrix.exclude }}
|
||||
remove_excluded_modules "$INSTALL_ADDONS_DIR" "$EXCLUDE"
|
||||
fi
|
||||
- name: Skip addons
|
||||
if: ${{ matrix.skip }}
|
||||
env:
|
||||
SKIPPED: ${{ matrix.skip }}
|
||||
run: |
|
||||
remove_excluded_modules "$INSTALL_ADDONS_DIR" "$SKIPPED"
|
||||
echo "EXCLUDE=${EXCLUDE:+$EXCLUDE,}$SKIPPED" >> "$GITHUB_ENV"
|
||||
echo "Not installed nor tested with Odoo Community: $SKIPPED" | tee -a "$GITHUB_STEP_SUMMARY"
|
||||
- name: Update addons path with enterprise
|
||||
if: ${{ matrix.odoo_enterprise == 1 }}
|
||||
run: |
|
||||
echo "ADDONS_PATH=/opt/odoo/addons,/opt/enterprise,${{ env.INSTALL_ADDONS_DIR }}" >> $GITHUB_ENV
|
||||
echo "ADDONS_PATH=/opt/odoo/addons,/opt/enterprise,${{ env.INSTALL_ADDONS_DIR }}" >> "$GITHUB_ENV"
|
||||
- name: Update addons path without enterprise
|
||||
if: ${{ matrix.odoo_enterprise == 0 }}
|
||||
run: |
|
||||
echo "ADDONS_PATH=/opt/odoo/addons,${{ env.INSTALL_ADDONS_DIR }}" >> $GITHUB_ENV
|
||||
echo "ADDONS_PATH=/opt/odoo/addons,${{ env.INSTALL_ADDONS_DIR }}" >> "$GITHUB_ENV"
|
||||
- name: Add addons to EXCLUDE PATH
|
||||
if: ${{ matrix.EXCLUDE_MODULES }}
|
||||
run: |
|
||||
echo "server_wide_modules = web,module_change_auto_install" >> ${ODOO_RC}
|
||||
echo "ODOO_MODULES_AUTO_INSTALL_DISABLED=${{ matrix.EXCLUDE_MODULES }}" >> $GITHUB_ENV
|
||||
echo "server_wide_modules = web,module_change_auto_install" >> "${ODOO_RC}"
|
||||
echo "ODOO_MODULES_AUTO_INSTALL_DISABLED=${{ matrix.EXCLUDE_MODULES }}" >> "$GITHUB_ENV"
|
||||
- name: Install addons and dependencies
|
||||
run: |
|
||||
(ADDONS_PATH=${ADDONS_PATH} ADDONS_DIR=${INSTALL_ADDONS_DIR} oca_install_addons)
|
||||
@@ -149,7 +147,7 @@ jobs:
|
||||
hide_complexity: true
|
||||
- name: Write to Job Summary
|
||||
if: steps.coverage.outputs.report == 'true'
|
||||
run: cat code-coverage-results.md >> $GITHUB_STEP_SUMMARY
|
||||
run: cat code-coverage-results.md >> "$GITHUB_STEP_SUMMARY"
|
||||
- name: Update .pot files
|
||||
run: noviat_export_and_push_pot https://github.com/${{ github.repository }}
|
||||
if: ${{ matrix.makepot == 'true' && github.event_name == 'push' }}
|
||||
Reference in new issue
Block a user