Skip to content

Commit 1cc86af

Browse files
authored
Merge pull request #11 from picimako/disable-changelog-patch
Disable changelog patching
2 parents 0930ff1 + 76ccf53 commit 1cc86af

File tree

2 files changed

+41
-45
lines changed

2 files changed

+41
-45
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ jobs:
3030
runs-on: ubuntu-latest
3131
outputs:
3232
version: ${{ steps.properties.outputs.version }}
33-
changelog: ${{ steps.properties.outputs.changelog }}
3433
steps:
3534

3635
# Check out current repository
@@ -57,13 +56,8 @@ jobs:
5756
PROPERTIES="$(./gradlew properties --console=plain -q)"
5857
VERSION="$(echo "$PROPERTIES" | grep "^version:" | cut -f2- -d ' ')"
5958
NAME="$(echo "$PROPERTIES" | grep "^pluginName:" | cut -f2- -d ' ')"
60-
CHANGELOG="$(./gradlew getChangelog --unreleased --no-header --console=plain -q)"
61-
CHANGELOG="${CHANGELOG//'%'/'%25'}"
62-
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
63-
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
6459
echo "::set-output name=version::$VERSION"
6560
echo "::set-output name=name::$NAME"
66-
echo "::set-output name=changelog::$CHANGELOG"
6761
echo "::set-output name=pluginVerifierHomeDir::~/.pluginVerifier"
6862
./gradlew listProductsReleases # prepare list of IDEs for Plugin Verifier
6963
# Run tests
@@ -138,6 +132,7 @@ jobs:
138132
gh api repos/{owner}/{repo}/releases \
139133
--jq '.[] | select(.draft == true) | .id' \
140134
| xargs -I '{}' gh api -X DELETE repos/{owner}/{repo}/releases/{}
135+
141136
# Create new release draft - which is not publicly visible and requires manual acceptance
142137
- name: Create Release Draft
143138
env:
@@ -147,6 +142,5 @@ jobs:
147142
--draft \
148143
--title "v${{ needs.build.outputs.version }}" \
149144
--notes "$(cat << 'EOM'
150-
${{ needs.build.outputs.changelog }}
151145
EOM
152146
)"

.github/workflows/release.yml

Lines changed: 40 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -28,27 +28,29 @@ jobs:
2828
java-version: 11
2929
cache: gradle
3030

31-
# Set environment variables
32-
- name: Export Properties
33-
id: properties
34-
shell: bash
35-
run: |
36-
CHANGELOG="$(cat << 'EOM' | sed -e 's/^[[:space:]]*$//g' -e '/./,$!d'
37-
${{ github.event.release.body }}
38-
EOM
39-
)"
40-
41-
CHANGELOG="${CHANGELOG//'%'/'%25'}"
42-
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
43-
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
44-
echo "::set-output name=changelog::$CHANGELOG"
31+
# # Set environment variables
32+
# - name: Export Properties
33+
# id: properties
34+
# shell: bash
35+
# run: |
36+
# CHANGELOG="$(cat << 'EOM' | sed -e 's/^[[:space:]]*$//g' -e '/./,$!d'
37+
# ${{ github.event.release.body }}
38+
# EOM
39+
# )"
40+
#
41+
# CHANGELOG="${CHANGELOG//'%'/'%25'}"
42+
# CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
43+
# CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
44+
# echo "::set-output name=changelog::$CHANGELOG"
45+
4546
# Update Unreleased section with the current release note
46-
- name: Patch Changelog
47-
if: ${{ steps.properties.outputs.changelog != '' }}
48-
env:
49-
CHANGELOG: ${{ steps.properties.outputs.changelog }}
50-
run: |
51-
./gradlew patchChangelog --release-note="$CHANGELOG"
47+
# - name: Patch Changelog
48+
# if: ${{ steps.properties.outputs.changelog != '' }}
49+
# env:
50+
# CHANGELOG: ${{ steps.properties.outputs.changelog }}
51+
# run: |
52+
# ./gradlew patchChangelog --release-note="$CHANGELOG"
53+
5254
# Publish the plugin to the Marketplace
5355
- name: Publish Plugin
5456
env:
@@ -61,21 +63,21 @@ jobs:
6163
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6264
run: gh release upload ${{ github.event.release.tag_name }} ./build/distributions/*
6365

64-
# Create pull request
65-
- name: Create Pull Request
66-
if: ${{ steps.properties.outputs.changelog != '' }}
67-
env:
68-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
69-
run: |
70-
VERSION="${{ github.event.release.tag_name }}"
71-
BRANCH="changelog-update-$VERSION"
72-
git config user.email "[email protected]"
73-
git config user.name "GitHub Action"
74-
git checkout -b $BRANCH
75-
git commit -am "Changelog update - $VERSION"
76-
git push --set-upstream origin $BRANCH
77-
gh pr create \
78-
--title "Changelog update - \`$VERSION\`" \
79-
--body "Current pull request contains patched \`CHANGELOG.md\` file for the \`$VERSION\` version." \
80-
--base main \
81-
--head $BRANCH
66+
# # Create pull request
67+
# - name: Create Pull Request
68+
# if: ${{ steps.properties.outputs.changelog != '' }}
69+
# env:
70+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
71+
# run: |
72+
# VERSION="${{ github.event.release.tag_name }}"
73+
# BRANCH="changelog-update-$VERSION"
74+
# git config user.email "[email protected]"
75+
# git config user.name "GitHub Action"
76+
# git checkout -b $BRANCH
77+
# git commit -am "Changelog update - $VERSION"
78+
# git push --set-upstream origin $BRANCH
79+
# gh pr create \
80+
# --title "Changelog update - \`$VERSION\`" \
81+
# --body "Current pull request contains patched \`CHANGELOG.md\` file for the \`$VERSION\` version." \
82+
# --base main \
83+
# --head $BRANCH

0 commit comments

Comments
 (0)