Files
truecharts/.github/workflows/charts-restructure.yaml
Kjeld Schouten-Lebbing 1d51be0e3d 777 on new scripts (+2 squashed commit)
Squashed commit:

[9ae7dd0f] add helm-docs to workflow

[2206f5ba] fix small typo in workflows (+1 squashed commits)

Squashed commits:

[29c2ceb4] Documentation-Cleanup (#181)

* work on readme generation

* document windows setup

* add simple pre-commit install script

* more docs for git setup

* Update pre-commit

* pre-commit automatic fixes

* Increase all patch versions

* Auto Readme and Config doc

* Auto app-readme.md generation

* increase common and common-test versions accordingly (due to cleanup)

* move contribution guidelines to /development in wiki

* fix some end-of-line issues (again)

* fix line 14 of workflows
2021-02-23 18:21:54 +01:00

65 lines
1.8 KiB
YAML

name: "Charts: Release"
on:
push:
branches:
- master
tags-ignore:
- '**'
paths:
- 'charts/**'
- '!charts/**/*.md'
- '!charts/**/README.md'
- '!charts/**/README.md.gotmpl'
- '!charts/**/app-readme.md'
- '!charts/**/app-readme.md.gotmpl'
- '!charts/**/docs/*'
- 'library/**'
- '!library/**/*.md'
- '!library/**/README.md'
- '!library/**/README.md.gotmpl'
- '!library/**/app-readme.md'
- '!library/**/app-readme.md.gotmpl'
- '!library/**/docs/*'
jobs:
copy:
runs-on: ubuntu-latest
steps:
- name: Checkout-Master
uses: actions/checkout@v2
with:
ref: 'master'
path: 'master'
- name: Checkout-Charts
uses: actions/checkout@v2
with:
ref: 'charts'
path: 'charts'
- name: Generate Helm Structure
run: |
cd master
rm -Rf ../charts/charts/*
for chart in charts/*; do
if [ -d "${chart}" ]; then
maxversion=$(ls -l ${chart} | grep ^d | awk '{print $9}' | tail -n 1)
chartname=$(basename ${chart})
echo "Processing ${chart} version ${maxversion}"
mv ${chart}/${maxversion} ../charts/charts/${chartname}
rm ../charts/charts/${chartname}/Chart.lock || echo "chart.lock missing for ${chartname}, continuing..."
fi
done
mv library/* ../charts/charts/
ls ../charts/charts/
cd ..
- name: Commit and push updated charts
run: |
cd charts
git config user.name "$GITHUB_ACTOR"
git config user.email "$GITHUB_ACTOR@users.noreply.github.com"
git add --all
git commit -sm "Publish Chart updates" || exit 0
git push