Skip to content

Commit f37bbbc

Browse files
committed
Merge branch 'main' of github.com:devtron-labs/dashboard into feat/airgapped-release
2 parents 204af8c + ce4fac0 commit f37bbbc

File tree

2 files changed

+54
-5
lines changed

2 files changed

+54
-5
lines changed
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Increment tag for patch or minor
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
types:
8+
- closed # Trigger only when a PR is closed (merged or not)
9+
10+
jobs:
11+
tag:
12+
if: github.event.pull_request.merged == true
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v3
17+
with:
18+
fetch-depth: 0
19+
20+
- name: Create new tag
21+
env:
22+
TOKEN: ${{ secrets.TAG_CREATION_TOKEN_PUBLIC }}
23+
run: |
24+
echo $TOKEN | gh auth login --with-token
25+
latest_tag=$(git tag | sort -V | tail -n 1)
26+
echo "Latest tag: $latest_tag"
27+
28+
# Extract major and minor versions
29+
version=$(echo $latest_tag | cut -d. -f1-2)
30+
# Extract patch version
31+
patch=$(echo $latest_tag | cut -d. -f3)
32+
# Extract minor version
33+
minor=$(echo $latest_tag | cut -d. -f2)
34+
major=$(echo $latest_tag | cut -d. -f1)
35+
36+
# Check if the incoming branch starts with 'release-candidate-'
37+
incoming_branch="${{ github.head_ref }}"
38+
if [[ "$incoming_branch" == release-candidate-* ]]; then
39+
# Increment minor version and reset patch
40+
new_minor=$((minor+1))
41+
new_tag="$major.$new_minor.0"
42+
echo "New tag will be (minor increment): $new_tag"
43+
else
44+
# Increment patch version
45+
new_tag="$version.$((patch+1))"
46+
echo "New tag will be (patch increment): $new_tag"
47+
fi
48+
49+
git config --global user.email "[email protected]"
50+
git config --global user.name "systemsdt"
51+
git tag $new_tag
52+
git push origin $new_tag

src/components/app/list-new/GenericAppList.tsx

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ const GenericAppList = ({
141141
}, [appsList])
142142

143143
const handleArgoAppListing = () => {
144+
if (!clusterIdsCsv) return
144145
setDataStateType(AppListViewType.LOADING)
145146
getArgoInstalledExternalApps(clusterIdsCsv)
146147
.then((appsListResponse) => {
@@ -173,11 +174,7 @@ const GenericAppList = ({
173174

174175
// reset data
175176
function init() {
176-
if (isSSE && !payloadParsedFromUrl?.namespaces?.length) {
177-
setDataStateType(AppListViewType.LIST)
178-
} else {
179-
setDataStateType(AppListViewType.LOADING)
180-
}
177+
setDataStateType(AppListViewType.LIST)
181178
setClusterIdsCsv(_getClusterIdsFromRequestUrl() ?? null)
182179
setAppsList([])
183180
setFilteredAppsList([])

0 commit comments

Comments
 (0)