From 7f0a1e8f7b21c60f954411c5ca12e5b781c9596a Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Tue, 11 Jun 2024 19:59:44 -0600 Subject: [PATCH 1/8] Added two lines for setting latest directory --- .github/workflows/docs-ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index 04e85f29b19..863119a72ce 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -36,9 +36,11 @@ jobs: steps: - name: Make Symlinks run: | + git tag -a -m "[Temp Tag] ${{ github.ref_name }}" ${{ github.ref_name }} release/${{ github.ref_name }} + LATEST=$(git tag --sort="version:refname" | grep -E "^v([0-9]+[.]?){3}$" | tail -1) mkdir -p tmp-deephaven-core-v2/symlinks cd tmp-deephaven-core-v2/symlinks - ln -s ../${{ github.ref_name }} latest + ln -s ../${LATEST} latest ln -s ../main next - name: Deploy Symlinks From 336fa746cdbca3ad6640c248e405908ccd914b7f Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Wed, 12 Jun 2024 13:33:38 -0600 Subject: [PATCH 2/8] Added version var to parse ref_branch --- .github/workflows/docs-ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index 863119a72ce..78a5cdf59fe 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -36,7 +36,8 @@ jobs: steps: - name: Make Symlinks run: | - git tag -a -m "[Temp Tag] ${{ github.ref_name }}" ${{ github.ref_name }} release/${{ github.ref_name }} + VERSION=$(basename ${{ github.ref_name }}) + git tag -a -m "[Temp Tag] ${VERSION}" ${VERSION} release/${VERSION} LATEST=$(git tag --sort="version:refname" | grep -E "^v([0-9]+[.]?){3}$" | tail -1) mkdir -p tmp-deephaven-core-v2/symlinks cd tmp-deephaven-core-v2/symlinks From 64ede56bb7e99ed81e030d5bff514e0884c8ac3d Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Wed, 12 Jun 2024 17:07:15 -0600 Subject: [PATCH 3/8] Added Git Setup Action --- .github/workflows/docs-ci.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index 78a5cdf59fe..bc7f0a3b8b2 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -34,6 +34,12 @@ jobs: needs: [javadoc, typedoc, pydoc, cppdoc, rdoc] runs-on: ubuntu-22.04 steps: + - uses: actions/checkout@v4 + - name: Setup Git + run: | + git config user.name "$(git --no-pager log --format=format:'%an' -n 1)" + git config user.email "$(git --no-pager log --format=format:'%ae' -n 1)" + - name: Make Symlinks run: | VERSION=$(basename ${{ github.ref_name }}) @@ -41,7 +47,7 @@ jobs: LATEST=$(git tag --sort="version:refname" | grep -E "^v([0-9]+[.]?){3}$" | tail -1) mkdir -p tmp-deephaven-core-v2/symlinks cd tmp-deephaven-core-v2/symlinks - ln -s ../${LATEST} latest + ln -s ../release/${LATEST} latest ln -s ../main next - name: Deploy Symlinks From dc987f2a86f4dd16d6d5ff873c7946c716b39607 Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Thu, 13 Jun 2024 15:50:21 -0600 Subject: [PATCH 4/8] Added tag fetch --- .github/workflows/docs-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index bc7f0a3b8b2..b4fbe6494a2 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -39,6 +39,8 @@ jobs: run: | git config user.name "$(git --no-pager log --format=format:'%an' -n 1)" git config user.email "$(git --no-pager log --format=format:'%ae' -n 1)" + git remote add upstream https://github.com/deephaven/deephaven-core.git + git fetch --tags upstream - name: Make Symlinks run: | From 873c798829dfa0e7975f93feb58107d885d62ec4 Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Thu, 13 Jun 2024 19:25:38 -0600 Subject: [PATCH 5/8] Upsert remote upstream --- .github/workflows/docs-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index b4fbe6494a2..0efc0c11590 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -39,7 +39,7 @@ jobs: run: | git config user.name "$(git --no-pager log --format=format:'%an' -n 1)" git config user.email "$(git --no-pager log --format=format:'%ae' -n 1)" - git remote add upstream https://github.com/deephaven/deephaven-core.git + git remote remove upstream 2>/dev/null || git remote add upstream https://github.com/deephaven/deephaven-core.git git fetch --tags upstream - name: Make Symlinks From f309558e81280dcf077185a84143d5c011010c0e Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Fri, 14 Jun 2024 15:42:41 -0600 Subject: [PATCH 6/8] Use Fetch tag instead of git command --- .github/workflows/docs-ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index 0efc0c11590..d0ca20980ac 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -34,13 +34,13 @@ jobs: needs: [javadoc, typedoc, pydoc, cppdoc, rdoc] runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v4 - name: Setup Git - run: | - git config user.name "$(git --no-pager log --format=format:'%an' -n 1)" - git config user.email "$(git --no-pager log --format=format:'%ae' -n 1)" - git remote remove upstream 2>/dev/null || git remote add upstream https://github.com/deephaven/deephaven-core.git - git fetch --tags upstream + uses: actions/checkout@v4 + with: + fetch-tags: true + - run: | + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: Make Symlinks run: | From 8ec4812004000237c346e158a87b54a1f639afe6 Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Mon, 17 Jun 2024 13:22:13 -0600 Subject: [PATCH 7/8] Update docs-ci.yml --- .github/workflows/docs-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index d0ca20980ac..c23453ee27b 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -37,6 +37,7 @@ jobs: - name: Setup Git uses: actions/checkout@v4 with: + fetch-depth: 0 # Fixes Bug: https://github.com/actions/checkout/issues/1471 fetch-tags: true - run: | git config user.name "github-actions[bot]" From 4726fe47952aab6272ea010bdd97885cca617a5e Mon Sep 17 00:00:00 2001 From: Stan Brubaker <120737309+stanbrub@users.noreply.github.com> Date: Mon, 24 Jun 2024 12:41:40 -0600 Subject: [PATCH 8/8] Removed temp tag and used bash sort version --- .github/workflows/docs-ci.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/docs-ci.yml b/.github/workflows/docs-ci.yml index 2384f15265d..cafe7d6c53e 100644 --- a/.github/workflows/docs-ci.yml +++ b/.github/workflows/docs-ci.yml @@ -39,15 +39,11 @@ jobs: with: fetch-depth: 0 # Fixes Bug: https://github.com/actions/checkout/issues/1471 fetch-tags: true - - run: | - git config user.name "github-actions[bot]" - git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: Make Symlinks run: | VERSION=$(basename ${{ github.ref_name }}) - git tag -a -m "[Temp Tag] ${VERSION}" ${VERSION} release/${VERSION} - LATEST=$(git tag --sort="version:refname" | grep -E "^v([0-9]+[.]?){3}$" | tail -1) + LATEST=$((git tag -l && echo "${VERSION}") | grep -E '^v[0-9]+([.][0-9]+){2}$' | sort --version-sort | tail -1) mkdir -p tmp-deephaven-core-v2/symlinks cd tmp-deephaven-core-v2/symlinks ln -s ../release/${LATEST} latest