@@ -56,21 +56,33 @@ jobs:
5656 php-version : ' 8.5'
5757 extensions : intl, mbstring, xml, soap, zip, curl
5858
59+ - name : Get comment
60+ id : get-comment
61+ run : |
62+ curl -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/FriendsOfTYPO3/visual_editor/releases/tags/${{ env.version }} > release.json
63+
64+ readonly local comment=$(
65+ jq -r '.name, "", .body, "", .html_url' release.json \
66+ | php -r 'echo preg_replace("/[\x{1F1E6}-\x{1F1FF}\x{1F300}-\x{1FAFF}\x{2600}-\x{27BF}\x{FE0F}\x{200D}]/u", "", stream_get_contents(STDIN));' \
67+ )
68+
69+ {
70+ echo 'comment<<EOF'
71+ echo "$comment"
72+ echo EOF
73+ } >> "$GITHUB_ENV"
74+
5975 - name : Install typo3/tailor
6076 run : composer global require typo3/tailor --prefer-dist --no-progress
6177
6278 - name : Upload EXT:visual_editor to TER
6379 run : |
6480 sed -i 's/InstalledVersions::getPrettyVersion('\''friendsoftypo3\/visual-editor'\'')/'\''${{ env.version }}'\''/g' ext_emconf.php \
81+ sed -i 's/$version,/'\''${{ env.version }}'\','/g' ext_emconf.php \
6582 && git config --global user.email "no@one" \
6683 && git config --global user.name "No One" \
6784 && git add ext_emconf.php \
6885 && git commit -m 'x' -n \
6986 && git archive -o archive.zip HEAD --prefix=visual_editor-${{ env.version }}/ \
7087 && git reset --hard HEAD~ \
71- && curl -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/FriendsOfTYPO3/visual_editor/releases/tags/${{ env.version }} > release.json \
72- && php ~/.composer/vendor/bin/tailor ter:publish ${{ env.version }} --artefact=archive.zip \
73- --comment="$(
74- jq -r '.name, "", .body, "", .html_url' release.json \
75- | php -r 'echo preg_replace("/[\x{1F1E6}-\x{1F1FF}\x{1F300}-\x{1FAFF}\x{2600}-\x{27BF}\x{FE0F}\x{200D}]/u", "", stream_get_contents(STDIN));'
76- )"
88+ && php ~/.composer/vendor/bin/tailor ter:publish -vvv ${{ env.version }} --artefact=archive.zip --comment="${{ env.comment }}"
0 commit comments