diff --git a/.github/actions/init-dbt/action.yml b/.github/actions/init-dbt/action.yml new file mode 100644 index 00000000..807038c5 --- /dev/null +++ b/.github/actions/init-dbt/action.yml @@ -0,0 +1,13 @@ +name: init dbt +runs: + using: "composite" + steps: + - name: Set up dependencies + run: | + pip install pip==23.1.2 + pip install pip-tools==6.13.0 + pip install -r requirements.txt + + - name: Download DBT Manifest + run: | + wget https://artemis-xyz.github.io/dbt/manifest.json \ No newline at end of file diff --git a/.github/workflows/compile.yml b/.github/workflows/compile.yml index ad676c0a..f4e3aac3 100644 --- a/.github/workflows/compile.yml +++ b/.github/workflows/compile.yml @@ -25,11 +25,8 @@ jobs: with: ref: ${{ github.event.pull_request.head.sha }} - - name: Set up dependencies - run: | - pip install pip==23.1.2 - pip install pip-tools==6.13.0 - pip install -r requirements.txt + - name: Init dbt + uses: ./.github/actions/init-dbt - name: Compile run: | diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index f5471ef0..772873c0 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -28,11 +28,8 @@ jobs: owner: ${{ github.repository_owner }} repositories: "artemis-xyz.github.io" - - name: Set up dependencies - run: | - pip install pip==23.1.2 - pip install pip-tools==6.13.0 - pip install -r requirements.txt + - name: Init dbt + uses: ./.github/actions/init-dbt - name: Generate docs run: | diff --git a/.github/workflows/show_changed_models.yml b/.github/workflows/show_changed_models.yml index 0d827c75..c76ef8a0 100644 --- a/.github/workflows/show_changed_models.yml +++ b/.github/workflows/show_changed_models.yml @@ -49,15 +49,8 @@ jobs: with: ref: ${{ github.event.pull_request.head.sha }} - - name: Set up dependencies - run: | - pip install pip==23.1.2 - pip install pip-tools==6.13.0 - pip install -r requirements.txt - - - name: Download manifest.json - run: | - wget https://artemis-xyz.github.io/dbt/manifest.json + - name: Init dbt + uses: ./.github/actions/init-dbt - name: Show results of changed models run: |