Skip to content

Commit 2c42c08

Browse files
authored
Update publish-helm-charts.yaml
Pushing new release
1 parent 08b4784 commit 2c42c08

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

.github/workflows/publish-helm-charts.yaml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ jobs:
1515
steps:
1616
- name: Checkout code
1717
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
18+
with:
19+
fetch-depth: 0
1820

1921
- name: Set release version
2022
id: release_version
@@ -65,6 +67,7 @@ jobs:
6567
--git-repo=ceph-csi-operator \
6668
--token=${{ secrets.CSI_GITHUB_TOKEN }} \
6769
--package-path=.csi-op-release-packages
70+
--release-name-template="v{{ .Version }}"
6871
6972
- name: Update Helm repo index and push to gh-pages
7073
run: |
@@ -73,10 +76,8 @@ jobs:
7376
git config --global user.name "GitHub Actions"
7477
7578
git checkout deploy/charts/ceph-csi-operator/Chart.yaml deploy/charts/ceph-csi-drivers/Chart.yaml
76-
echo "Checking if gh-pages branch exists..."
77-
git fetch origin gh-pages || git checkout --orphan gh-pages
7879
git checkout gh-pages
79-
echo "If gh-pages branch didn't exist, it has been created."
80+
mkdir -p .cr-index
8081
8182
echo "pushing it to the github pacges"
8283
mkdir -p .cr-index
@@ -91,7 +92,7 @@ jobs:
9192
cp -r .cr-index/* .
9293
git add .
9394
git commit -m "Update Helm repo index from release ${{ github.event.release.tag_name }}"
94-
git push origin gh-pages
95+
git push origin gh-pages -f
9596
9697
9798

0 commit comments

Comments
 (0)