From 2ea4ab6c43139766509fbf58744fb8c56ba7d321 Mon Sep 17 00:00:00 2001 From: Alexander Streltsov Date: Thu, 28 Dec 2023 10:20:06 +0300 Subject: [PATCH] ci: debug print env --- .github/workflows/main.yaml | 6 ++++-- sync.mjs | 3 +-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index d2cc090..da64295 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -8,7 +8,7 @@ on: workflow_dispatch: jobs: - publish-gpr: + test-and-deploy: runs-on: ubuntu-latest permissions: contents: read @@ -18,7 +18,9 @@ jobs: with: node-version: 20 - run: npm ci - - run: node sync.mjs + - run: | + printenv + node sync.mjs env: AIDBOX_URL: ${{ vars.AIDBOX_STAGE_URL }} AIDBOX_USER: ${{ vars.AIDBOX_STAGE_USERNAME }} diff --git a/sync.mjs b/sync.mjs index 4e03bac..27d8a0a 100644 --- a/sync.mjs +++ b/sync.mjs @@ -49,7 +49,7 @@ function getContentTypeByExt(ext) { function buildOperationResource(filepath) { const [_, ...splited] = filepath.split(/[\/\._]/); const method = splited.slice(-2)[0]; - console.log(filepath); + const route = splited.slice(0, -2).map(route_path => { if (route_path[0] === ':') return { name: route_path.slice(1) } @@ -106,7 +106,6 @@ async function getSeedImport(client) { '/SeedImport/aidbox-ui'); return resp.data.resources; } catch (e) { - console.log(e); if (e.response.status === 404) return [] else