forked from OpenCatalogi/opencatalogi
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'development' into feature/DIMOC-322/update-dev-before-m…
…aster
- Loading branch information
Showing
17 changed files
with
161 additions
and
123 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,26 +4,50 @@ on: | |
push: | ||
branches: | ||
- master | ||
- main | ||
workflow_dispatch: | ||
inputs: | ||
version: | ||
description: 'Version to release (leave empty to use info.xml version)' | ||
required: false | ||
default: '' | ||
|
||
jobs: | ||
release-management: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set app env | ||
run: | | ||
# Split and keep last | ||
echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV | ||
echo "APP_VERSION=${GITHUB_REF##*/}" >> $GITHUB_ENV | ||
# Step 1: Checkout the code | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.head_ref }} # Checkout the correct branch name | ||
fetch-depth: 0 # Fetch the whole repo history | ||
- name: Get current version and increment | ||
id: increment_version | ||
run: | | ||
current_version=$(grep -oP '(?<=<version>)[^<]+' appinfo/info.xml) | ||
IFS='.' read -ra version_parts <<< "$current_version" | ||
((version_parts[2]++)) | ||
new_version="${version_parts[0]}.${version_parts[1]}.${version_parts[2]}" | ||
echo "NEW_VERSION=$new_version" >> $GITHUB_ENV | ||
echo "new_version=$new_version" >> $GITHUB_OUTPUT | ||
- name: Update version in info.xml | ||
run: | | ||
sed -i "s|<version>.*</version>|<version>${{ env.NEW_VERSION }}</version>|" appinfo/info.xml | ||
# Step 2: Prepare the signing certificate and key | ||
- name: Commit version update | ||
run: | | ||
git config --local user.email "[email protected]" | ||
git config --local user.name "GitHub Action" | ||
git commit -am "Bump version to ${{ env.NEW_VERSION }}" | ||
git push | ||
# Step 1: Prepare the signing certificate and key | ||
- name: Prepare Signing Certificate and Key | ||
run: | | ||
echo "${{ secrets.NEXTCLOUD_SIGNING_CERT }}" > signing-cert.crt | ||
|
@@ -51,10 +75,10 @@ jobs: | |
# Step 7: Build composer dependencies | ||
- run: composer i --no-dev | ||
|
||
# Step 8: Copy the files into the package directory, excluding .git and package itself | ||
# Step 8: Copy the files into the package directory | ||
- name: Copy the package files into the package | ||
run: | | ||
mkdir -p package/opencatalogi | ||
mkdir -p package/${{ github.event.repository.name }} | ||
rsync -av --progress \ | ||
--exclude='package' \ | ||
--exclude='.git' \ | ||
|
@@ -63,7 +87,7 @@ jobs: | |
--exclude='docker' \ | ||
--exclude='docs' \ | ||
--exclude='node_modules' \ | ||
--exclude='src' \ | ||
--exclude='/src' \ | ||
--exclude='test' \ | ||
--exclude='package-lock.json' \ | ||
--exclude='composer.lock' \ | ||
|
@@ -90,17 +114,17 @@ jobs: | |
--exclude='stylelint.config.js' \ | ||
--exclude='.babelrc' \ | ||
--exclude='.nvmrc' \ | ||
./ package/opencatalogi/ | ||
./ package/${{ github.event.repository.name }}/ | ||
# Step 9: Create the TAR.GZ archive with code in opencatalogi directory | ||
# Step 9: Create the TAR.GZ archive | ||
- name: Create Tarball | ||
run: | | ||
cd package && tar -czf ../nexcloud-release.tar.gz opencatalogi | ||
cd package && tar -czf ../nextcloud-release.tar.gz ${{ github.event.repository.name }} | ||
# Step 10: Sign the TAR.GZ file with OpenSSL | ||
- name: Sign the TAR.GZ file with OpenSSL | ||
run: | | ||
openssl dgst -sha512 -sign signing-key.key nexcloud-release.tar.gz | openssl base64 -out nexcloud-release.signature | ||
openssl dgst -sha512 -sign signing-key.key nextcloud-release.tar.gz | openssl base64 -out nextcloud-release.signature | ||
# Step 11: Generate Git version information | ||
- name: Git Version | ||
|
@@ -118,52 +142,55 @@ jobs: | |
# Step 13: Run Changelog CI | ||
- name: Run Changelog CI | ||
if: github.ref == 'refs/heads/master' | ||
if: github.ref == 'refs/heads/main' | ||
uses: saadmk11/[email protected] | ||
with: | ||
release_version: ${{ steps.version.outputs.version }} | ||
release_version: ${{ env.NEW_VERSION }} | ||
config_file: changelog-ci-config.json | ||
|
||
# Step 14: Output the version | ||
- name: Use the version | ||
run: | | ||
echo ${{ steps.version.outputs.version }} | ||
# Step 15: Copy the files into the package directory, excluding .git and package itself | ||
# Step 15: Copy the package files into the package (this step seems redundant, consider removing) | ||
- name: Copy the package files into the package | ||
run: | | ||
mkdir -p package/opencatalogi | ||
rsync -av --progress --exclude='package' --exclude='.git' ./ package/opencatalogi/ | ||
mkdir -p package/${{ github.event.repository.name }} | ||
rsync -av --progress --exclude='package' --exclude='.git' ./ package/${{ github.event.repository.name }}/ | ||
# Step 18: Create a new release on GitHub | ||
- name: Upload Release | ||
uses: ncipollo/[email protected] | ||
with: | ||
artifacts: | | ||
LICENSE.md | ||
nexcloud-release.tar.gz | ||
nexcloud-release.signature | ||
opencatalogi-build.zip | ||
opencatalogi-build.tar.gz | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
tag: ${{ steps.version.outputs.version }} | ||
tag: v${{ env.NEW_VERSION }} | ||
name: Release ${{ env.NEW_VERSION }} | ||
draft: false | ||
prerelease: false | ||
|
||
- name: Attach tarball to github release | ||
uses: svenstaro/upload-release-action@04733e069f2d7f7f0b4aebc4fbdbce8613b03ccd # v2 | ||
id: attach_to_release | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
file: nexcloud-release.tar.gz | ||
asset_name: ${{ env.APP_NAME }}-${{ env.APP_VERSION }}.tar.gz | ||
tag: ${{ github.ref }} | ||
file: nextcloud-release.tar.gz # Corrected spelling | ||
asset_name: ${{ env.APP_NAME }}-${{ env.NEW_VERSION }}.tar.gz | ||
tag: v${{ env.NEW_VERSION }} | ||
overwrite: true | ||
|
||
- name: Upload app to Nextcloud appstore | ||
uses: nextcloud-releases/nextcloud-appstore-push-action@a011fe619bcf6e77ddebc96f9908e1af4071b9c1 # v1 | ||
with: | ||
app_name: ${{ env.APP_NAME }} | ||
appstore_token: ${{ secrets.NEXTCLOUD_APPSTORE_TOKEN }} | ||
download_url: ${{ steps.attach_to_release.outputs.browser_download_url }} | ||
download_url: https://github.com/${{ github.repository }}/releases/download/v${{ env.NEW_VERSION }}/${{ env.APP_NAME }}-${{ env.NEW_VERSION }}.tar.gz | ||
app_private_key: ${{ secrets.NEXTCLOUD_SIGNING_KEY }} | ||
|
||
nightly: false | ||
|
||
- name: Verify version and contents | ||
run: | | ||
echo "App version: ${{ env.NEW_VERSION }}" | ||
echo "Tarball contents:" | ||
tar -tvf nextcloud-release.tar.gz | ||
echo "info.xml contents:" | ||
tar -xOf nextcloud-release.tar.gz ${{ env.APP_NAME }}/appinfo/info.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,7 +22,7 @@ Create a [bug report](https://github.com/OpenCatalogi/.github/issues/new/choose) | |
Create a [feature request](https://github.com/OpenCatalogi/.github/issues/new/choose) | ||
]]></description> | ||
<version>0.6.6</version> | ||
<version>0.6.18</version> | ||
<licence>agpl</licence> | ||
<author mail="[email protected]" homepage="https://www.conduction.nl/">Conduction</author> | ||
<author mail="[email protected]" homepage="https://acato.nl/">Acato</author> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
*** | ||
|
||
--- | ||
description: >- | ||
Welkom bij de gebruikersdocumentatie voor de OpenCatalogi Nextcloud App. Veel | ||
succes met het gebruik van de app. | ||
---------------------------------- | ||
Welkom bij de gebruikersdocumentatie voor de OpenCatalogi Nextcloud App. Veel | ||
succes met het gebruik van de app. | ||
--- | ||
|
||
# Welkom | ||
|
||
|
@@ -24,4 +23,4 @@ Deze documentatie is bedoeld voor diverse doelgroepen: | |
|
||
Voor meer informatie over OpenCatalogi en onze gemeenschappelijke inspanningen, bezoek onze [documentatie-pagina](https://documentatie.opencatalogi.nl) of de officiële website op [OpenCatalogi.nl](https://opencatalogi.nl). | ||
|
||
Veel succes met het gebruik van de app. Voor vragen of bijdragen, neem gerust contact met ons op via <[email protected]>. | ||
Veel succes met het gebruik van de app. Voor vragen of bijdragen, neem gerust contact met ons op via [[email protected]](mailto:[email protected]). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.