diff --git a/.github/changelog/changelog.tmpl b/.github/changelog/changelog.tmpl deleted file mode 100644 index 9b23d27..0000000 --- a/.github/changelog/changelog.tmpl +++ /dev/null @@ -1,57 +0,0 @@ -{{- if .NotesByType.deprecation -}} -### :warning: **Deprecations** - -{{range .NotesByType.deprecation -}} -* {{ template "note" .}} -{{ end -}} -{{- end -}} - -{{- if index .NotesByType "breaking-change" -}} -### :rotating_light: **Breaking Changes** - -{{range index .NotesByType "breaking-change" -}} -* {{ template "note" .}} -{{ end -}} -{{- end -}} - -{{- $features := combineTypes .NotesByType.feature (index .NotesByType "new-resource" ) (index .NotesByType "new-data-source") -}} -{{- if $features }} -### :rocket: **New Features** - -{{range $features | sort -}} -* {{ template "note" . }} -{{ end -}} -{{- end -}} - -{{- $improvements := combineTypes .NotesByType.improvement .NotesByType.enhancement -}} -{{- if $improvements }} -### :tada: **Improvements** - -{{range $improvements | sort -}} -* {{ template "note" . }} -{{ end -}} -{{- end -}} - -{{- if .NotesByType.bug }} -### :bug: **Bug Fixes** - -{{range .NotesByType.bug -}} -* {{ template "note" . }} -{{ end -}} -{{- end -}} - -{{- if .NotesByType.note -}} -### :information_source: **Notes** - -{{range .NotesByType.note -}} -* {{ template "note" .}} -{{ end -}} -{{- end -}} - -{{- if .NotesByType.dependency }} -### :dependabot: **Dependencies** - -{{range .NotesByType.dependency | sort -}} -* {{ template "note" . }} -{{ end -}} -{{- end -}} diff --git a/.github/changelog/generate-changelog.sh b/.github/changelog/generate-changelog.sh deleted file mode 100644 index 610c176..0000000 --- a/.github/changelog/generate-changelog.sh +++ /dev/null @@ -1,55 +0,0 @@ -#!/bin/bash - -set -x -set -o errexit -set -o nounset - -__dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" -__parent="$(dirname "$__dir")" -__root="$(dirname "$__parent")" - -CHANGELOG_FILE_NAME="CHANGELOG.md" -CHANGELOG_TMP_FILE_NAME="CHANGELOG.tmp" -TARGET_SHA=$(git rev-parse HEAD) -PREVIOUS_RELEASE_TAG=$(git tag -l | sort -V | grep -E 'v[0-9]+.[0-9]+.[0-9]+$' | tail -n 1) -PREVIOUS_RELEASE_SHA=$(git rev-list -n 1 $PREVIOUS_RELEASE_TAG) - -if [ $TARGET_SHA == $PREVIOUS_RELEASE_SHA ]; then - echo "Nothing to do" - exit 0 -fi - -PREVIOUS_CHANGELOG=$(sed -n -e "/# ${PREVIOUS_RELEASE_TAG#v}/,\$p" $__root/$CHANGELOG_FILE_NAME) - -if [ -z "$PREVIOUS_CHANGELOG" ] -then - echo "Unable to locate previous changelog contents." - exit 1 -fi - -CHANGELOG=$($(go env GOPATH)/bin/changelog-build -this-release $TARGET_SHA \ - -last-release $PREVIOUS_RELEASE_SHA \ - -git-dir $__root \ - -entries-dir .changelog \ - -changelog-template $__dir/changelog.tmpl \ - -note-template $__dir/release-note.tmpl) -if [ -z "$CHANGELOG" ] -then - echo "No changelog generated." - exit 0 -fi - -rm -f $CHANGELOG_TMP_FILE_NAME - -sed -n -e "1{/# /p;}" $__root/$CHANGELOG_FILE_NAME > $CHANGELOG_TMP_FILE_NAME -echo "$CHANGELOG" >> $CHANGELOG_TMP_FILE_NAME -echo >> $CHANGELOG_TMP_FILE_NAME -echo "$PREVIOUS_CHANGELOG" >> $CHANGELOG_TMP_FILE_NAME - -cp $CHANGELOG_TMP_FILE_NAME $CHANGELOG_FILE_NAME - -rm $CHANGELOG_TMP_FILE_NAME - -echo "Successfully generated changelog." - -exit 0 \ No newline at end of file diff --git a/.github/changelog/release-note.tmpl b/.github/changelog/release-note.tmpl deleted file mode 100644 index 7b7ed9e..0000000 --- a/.github/changelog/release-note.tmpl +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "note" -}} -{{if eq "new-resource" .Type}}**New Resource:** {{else if eq "new-data-source" .Type}}**New Data Source:** {{ end }}{{.Body}} (GH-{{- .Issue -}}) -{{- end -}} \ No newline at end of file diff --git a/.github/workflows/go-generate.yml b/.github/workflows/go-generate.yml index 4e2ef8c..2d25942 100644 --- a/.github/workflows/go-generate.yml +++ b/.github/workflows/go-generate.yml @@ -11,7 +11,7 @@ on: name: go-generate jobs: go-generate: - runs-on: ubuntu-latest + runs-on: [self-hosted, Linux] steps: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 diff --git a/.github/workflows/push_main.yml b/.github/workflows/push_main.yml deleted file mode 100644 index 8650998..0000000 --- a/.github/workflows/push_main.yml +++ /dev/null @@ -1,23 +0,0 @@ -# -------------------------------------------------------------- -# WARNING: This file is managed by centralized sync management system. -# Do not edit this file directly, your changes will be overwritten. -# See https://github.com/orange-cloudavenue/workflows for more information. -# -------------------------------------------------------------- -name: Push main -on: - push: - branches: - - main - workflow_dispatch: - -concurrency: - group: ${{ github.ref }}-${{ github.head_ref }}-main - cancel-in-progress: true - -permissions: - contents: write - -jobs: - request-doc-update: - name: "Request doc update" - uses: orange-cloudavenue/workflows/.github/workflows/doc_publish.yml@main \ No newline at end of file