From c10e550b5fb46908440c26f5b09c4a173fe77f28 Mon Sep 17 00:00:00 2001 From: Jasperhino Date: Mon, 9 Dec 2024 22:08:09 +0100 Subject: [PATCH] feat: add pnpm caching to pipelines, update action versions, use new treemap library --- .github/workflows/main.yml | 52 +++++++++++++++++++++++------- .github/workflows/pull-request.yml | 25 ++++++++++---- README.md | 2 +- frontend/pnpm-lock.yaml | 39 +++++++++++++++++----- 4 files changed, 91 insertions(+), 27 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6f71e42..ddb311c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -15,19 +15,33 @@ jobs: steps: - name: Checkout 🛎️ - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Bump version and push tag 🏷 id: tag - uses: anothrNick/github-tag-action@1.36.0 + uses: anothrNick/github-tag-action@1.71.0 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} WITH_V: true - name: Install pnpm ⚙ - uses: pnpm/action-setup@v2.2.2 + uses: pnpm/action-setup@v4 with: - version: 7 + version: 8 + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + - name: Install treemaps library 📦 run: | @@ -58,27 +72,41 @@ jobs: steps: # To use this repository's private action, we must check out the repository - name: Checkout 🛎️ - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup pnpm ⚙️ - uses: pnpm/action-setup@v2.2.2 + uses: pnpm/action-setup@v4 with: - version: 7 + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- - name: Install Node 🟢 - uses: actions/setup-node@v2 + uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 22 cache: "pnpm" cache-dependency-path: frontend/pnpm-lock.yaml - name: Install treemaps library 📦 run: | cd frontend - git clone --branch hiviser_deployment https://${{ secrets.SEERENE_TREEMAPS_DEPLOY_USER }}:${{ secrets.SEERENE_TREEMAPS_DEPLOY_TOKEN }}@gitlab.hpi3d.de/seerene/treemaps.git - cd treemaps + git submodule add git@github.com:varg-dev/treemap-renderer.git + cd treemap-renderer npm install - npm run build-lib + npm run build - name: Install and Build Pages 🔧 run: | diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index a58990c..847e87b 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -13,17 +13,30 @@ jobs: steps: - name: Checkout 🛎️ - uses: actions/checkout@v3 + uses: actions/checkout@v4 - - name: Install pnpm ⚙ - uses: pnpm/action-setup@v2.2.2 + - name: Install pnpm ⚙ + uses: pnpm/action-setup@v4 with: - version: 7 + version: 8 + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- - name: Install Node 🟢 - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 22 cache: "pnpm" cache-dependency-path: frontend/pnpm-lock.yaml diff --git a/README.md b/README.md index 5815897..3b9dbc5 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ jobs: steps: - name: Check out Git repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Run Analytics Treemap Embedding Action 🚀 uses: hpicgs/github-software-analytics-embedding@v0 diff --git a/frontend/pnpm-lock.yaml b/frontend/pnpm-lock.yaml index 7aa609f..13b672f 100644 --- a/frontend/pnpm-lock.yaml +++ b/frontend/pnpm-lock.yaml @@ -20,6 +20,9 @@ importers: '@mui/material': specifier: ^5.8.6 version: 5.16.9(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react-dom@18.1.0(react@18.1.0))(react@18.1.0) + '@mui/x-data-grid': + specifier: ^6.19.1 + version: 6.20.4(@mui/material@5.16.9(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react-dom@18.1.0(react@18.1.0))(react@18.1.0))(@mui/system@5.16.8(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react-dom@18.1.0(react@18.1.0))(react@18.1.0) buffer: specifier: ^6.0.3 version: 6.0.3 @@ -29,9 +32,6 @@ importers: octokit: specifier: ^1.8.1 version: 1.8.1 - papaparse: - specifier: ^5.3.2 - version: 5.4.1 pretty-bytes: specifier: ^6.0.0 version: 6.1.1 @@ -407,6 +407,15 @@ packages: '@types/react': optional: true + '@mui/x-data-grid@6.20.4': + resolution: {integrity: sha512-I0JhinVV4e25hD2dB+R6biPBtpGeFrXf8RwlMPQbr9gUggPmPmNtWKo8Kk2PtBBMlGtdMAgHWe7PqhmucUxU1w==} + engines: {node: '>=14.0.0'} + peerDependencies: + '@mui/material': ^5.4.1 + '@mui/system': ^5.4.1 + react: ^17.0.0 || ^18.0.0 + react-dom: ^17.0.0 || ^18.0.0 + '@nodelib/fs.scandir@2.1.5': resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} @@ -1768,9 +1777,6 @@ packages: package-json-from-dist@1.0.1: resolution: {integrity: sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==} - papaparse@5.4.1: - resolution: {integrity: sha512-HipMsgJkZu8br23pW15uvo6sib6wne/4woLZPlFf3rpDyMe9ywEXUsuD7+6K9PRkJlVT51j/sCOYDKGGS3ZJrw==} - parent-module@1.0.1: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} @@ -1942,6 +1948,9 @@ packages: resolution: {integrity: sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==} engines: {node: '>=8'} + reselect@4.1.8: + resolution: {integrity: sha512-ab9EmR80F/zQTMNeneUr4cv+jSwPJgIlvEmVwLerwrWVbpLlBuls9XHzIeTFy4cegU2NHBp3va0LKOzU5qFEYQ==} + resolve-from@4.0.0: resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} engines: {node: '>=4'} @@ -2672,6 +2681,20 @@ snapshots: optionalDependencies: '@types/react': 18.0.12 + '@mui/x-data-grid@6.20.4(@mui/material@5.16.9(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react-dom@18.1.0(react@18.1.0))(react@18.1.0))(@mui/system@5.16.8(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react-dom@18.1.0(react@18.1.0))(react@18.1.0)': + dependencies: + '@babel/runtime': 7.26.0 + '@mui/material': 5.16.9(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react-dom@18.1.0(react@18.1.0))(react@18.1.0) + '@mui/system': 5.16.8(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@emotion/styled@11.13.5(@emotion/react@11.13.5(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0))(@types/react@18.0.12)(react@18.1.0) + '@mui/utils': 5.16.8(@types/react@18.0.12)(react@18.1.0) + clsx: 2.1.1 + prop-types: 15.8.1 + react: 18.1.0 + react-dom: 18.1.0(react@18.1.0) + reselect: 4.1.8 + transitivePeerDependencies: + - '@types/react' + '@nodelib/fs.scandir@2.1.5': dependencies: '@nodelib/fs.stat': 2.0.5 @@ -4278,8 +4301,6 @@ snapshots: package-json-from-dist@1.0.1: {} - papaparse@5.4.1: {} - parent-module@1.0.1: dependencies: callsites: 3.1.0 @@ -4435,6 +4456,8 @@ snapshots: regexpp@3.2.0: {} + reselect@4.1.8: {} + resolve-from@4.0.0: {} resolve@1.22.8: