From db2ab2f07d728a79e7d8b587a36a4de98f6c9bbc Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Mon, 13 Nov 2023 10:49:27 +0100 Subject: [PATCH 1/5] [Backport staging] Ship element-web as a debian package (#26563) Co-authored-by: Michael Telatynski <7t3chguy@gmail.com> --- .github/workflows/build_debian.yaml | 60 +++++++++++++++++------------ debian/.gitignore | 2 + debian/control | 13 ++++--- 3 files changed, 44 insertions(+), 31 deletions(-) create mode 100644 debian/.gitignore diff --git a/.github/workflows/build_debian.yaml b/.github/workflows/build_debian.yaml index 86553a05b..7ab28ff7c 100644 --- a/.github/workflows/build_debian.yaml +++ b/.github/workflows/build_debian.yaml @@ -31,38 +31,48 @@ jobs: - name: Prepare run: | - mkdir -p /tmp/element-web-debian/DEBIAN - cp -R debian/ /tmp/element-web-debian/DEBIAN/ - mkdir -p /tmp/element-web-debian/usr/share/element-web/ + mkdir -p debian/tmp/DEBIAN + find debian -maxdepth 1 -type f -exec cp "{}" debian/tmp/DEBIAN/ \; + mkdir -p debian/tmp/usr/share/element-web/ - tar -xf "element-$VERSION.tar.gz" -C /tmp/element-web-debian/usr/share/element-web --strip-components=1 - cp config.sample.json /tmp/element-web-debian/usr/share/element-web/config.json + tar -xf "element-$VERSION.tar.gz" -C debian/tmp/usr/share/element-web --strip-components=1 --no-same-owner --no-same-permissions + mv debian/tmp/usr/share/element-web/config{.sample,}.json + + - name: Write changelog + run: | + VERSION=$(cat package.json | jq -r .version) + TIME=$(date -d "$PUBLISHED_AT" -R) + { + echo "element-web ($VERSION) default; urgency=medium" + echo "$BODY" | sed 's/^##/\n */g;s/^\*/ */g' | perl -pe 's/\[.+?]\((.+?)\)/\1/g' + echo "" + echo " -- $ACTOR $TIME" + } > debian/tmp/DEBIAN/changelog + env: + ACTOR: ${{ github.actor }} + VERSION: ${{ github.event.release.tag_name }} + BODY: ${{ github.event.release.body }} + PUBLISHED_AT: ${{ github.event.release.published_at }} - name: Build deb package run: | VERSION=$(cat package.json | jq -r .version) - chmod -R u=rw,go=r /tmp/element-web-debian/usr/share/element-web/ - dpkg-deb -Zxz --root-owner-group -VVersion=$VERSION --build /tmp/element-web-debian element-web.deb + chmod -R u=rw,go=r debian/tmp/usr/share/element-web/ + dpkg-gencontrol -v"$VERSION" -ldebian/tmp/DEBIAN/changelog + dpkg-deb -Zxz --root-owner-group --build debian/tmp element-web.deb - # For now just upload the artifact to github - uses: actions/upload-artifact@v3 with: - name: debs - path: "*.deb" + name: element-web.deb + path: element-web.deb retention-days: 14 - #- name: Upload incoming deb - # if: github.event.release.prerelease == false - # run: aws s3 cp element-web.deb "s3://$R2_INCOMING_BUCKET" --endpoint-url "$R2_URL" --region auto - # env: - # AWS_ACCESS_KEY_ID: ${{ secrets.CF_R2_ACCESS_KEY_ID }} - # AWS_SECRET_ACCESS_KEY: ${{ secrets.CF_R2_TOKEN }} - - #reprepro: - # needs: build - # name: Run reprepro - # if: github.event.release.prerelease == false - # uses: ./.github/workflows/reprepro.yaml - # secrets: inherit - # with: - # incoming: element-web.deb + - name: Publish to packages.element.io + if: github.event.release.prerelease == false + uses: vector-im/packages.element.io@master + with: + file: element-web.deb + github-token: ${{ secrets.ELEMENT_BOT_TOKEN }} + bucket-api: ${{ vars.CF_R2_S3_API }} + bucket-key-id: ${{ secrets.CF_R2_ACCESS_KEY_ID }} + bucket-access-key: ${{ secrets.CF_R2_TOKEN }} diff --git a/debian/.gitignore b/debian/.gitignore new file mode 100644 index 000000000..7b52740dc --- /dev/null +++ b/debian/.gitignore @@ -0,0 +1,2 @@ +/files +/tmp diff --git a/debian/control b/debian/control index d8e38a750..158c3ada1 100755 --- a/debian/control +++ b/debian/control @@ -1,12 +1,13 @@ -Package: element-web -License: Apache-2.0 -Vendor: support@element.io -Architecture: all +Source: element-web Maintainer: support@element.io -Recommends: element-io-archive-keyring Section: web Priority: optional Homepage: https://element.io/ -Version: ${Version} + +Package: element-web +Architecture: all +Recommends: httpd, element-io-archive-keyring Description: A feature-rich client for Matrix.org + This package contains the web-based client that can be served through a web + server. From f69b58e7974095358281834cd673970c44c75fc5 Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Mon, 13 Nov 2023 10:26:32 +0000 Subject: [PATCH 2/5] Upgrade matrix-react-sdk to 3.84.1 --- package.json | 2 +- yarn.lock | 30 +++++++++++++++++++++++++----- 2 files changed, 26 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 6a438a8ea..df36a92f6 100644 --- a/package.json +++ b/package.json @@ -77,7 +77,7 @@ "katex": "^0.16.0", "lodash": "^4.17.21", "matrix-js-sdk": "30.0.0", - "matrix-react-sdk": "3.84.0", + "matrix-react-sdk": "3.84.1", "matrix-widget-api": "^1.3.1", "react": "17.0.2", "react-dom": "17.0.2", diff --git a/yarn.lock b/yarn.lock index a77410c4a..9cdf7da43 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8838,6 +8838,26 @@ matrix-js-sdk@30.0.0: unhomoglyph "^1.0.6" uuid "9" +matrix-js-sdk@30.0.1: + version "30.0.1" + resolved "https://registry.yarnpkg.com/matrix-js-sdk/-/matrix-js-sdk-30.0.1.tgz#33a1fb2d9a9a8875f51f48a1b3124c1e82457472" + integrity sha512-/yefRQ7e8xU0Aox8w6lYUDjYdK+9Wmpz59K1SJZX3E1KE1SUvIo4rkPkGojN3RkRFqXXBBP4ciJiy5vH6OodAg== + dependencies: + "@babel/runtime" "^7.12.5" + "@matrix-org/matrix-sdk-crypto-wasm" "^2.2.0" + another-json "^0.2.0" + bs58 "^5.0.0" + content-type "^1.0.4" + jwt-decode "^3.1.2" + loglevel "^1.7.1" + matrix-events-sdk "0.0.1" + matrix-widget-api "^1.6.0" + oidc-client-ts "^2.2.4" + p-retry "4" + sdp-transform "^2.14.1" + unhomoglyph "^1.0.6" + uuid "9" + matrix-mock-request@^2.5.0: version "2.6.0" resolved "https://registry.yarnpkg.com/matrix-mock-request/-/matrix-mock-request-2.6.0.tgz#0855c10b250668ce542b697251087be2bcc23f92" @@ -8845,10 +8865,10 @@ matrix-mock-request@^2.5.0: dependencies: expect "^28.1.0" -matrix-react-sdk@3.84.0: - version "3.84.0" - resolved "https://registry.yarnpkg.com/matrix-react-sdk/-/matrix-react-sdk-3.84.0.tgz#843e70460aff0680236180b8d5d92ab60cc906bf" - integrity sha512-k/3G+vNuAYQQy3Hx/leAOCsnPh8wJDMxNP4QB9JBm1wBTqFVtMojepyKaK0AryINbZzMa7xDPLel09u/cgJswQ== +matrix-react-sdk@3.84.1: + version "3.84.1" + resolved "https://registry.yarnpkg.com/matrix-react-sdk/-/matrix-react-sdk-3.84.1.tgz#2e915c3b6253a2157dadcde33deed1240a1acb12" + integrity sha512-yVL+vevxQxxZwN1gcOjEqz+I0RN6Ou6dXMxkO1zjTQdplJyVhOmePM0P8gH13ZLpsnLEc0ut9tFphPQdpoRypw== dependencies: "@babel/runtime" "^7.12.5" "@matrix-org/analytics-events" "^0.8.0" @@ -8891,7 +8911,7 @@ matrix-react-sdk@3.84.0: maplibre-gl "^2.0.0" matrix-encrypt-attachment "^1.0.3" matrix-events-sdk "0.0.1" - matrix-js-sdk "30.0.0" + matrix-js-sdk "30.0.1" matrix-widget-api "^1.5.0" memoize-one "^6.0.0" minimist "^1.2.5" From 5928fb973520a2c8989672da235cf14a2877e5a1 Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Mon, 13 Nov 2023 10:26:44 +0000 Subject: [PATCH 3/5] Upgrade matrix-js-sdk to 30.0.1 --- package.json | 2 +- yarn.lock | 20 -------------------- 2 files changed, 1 insertion(+), 21 deletions(-) diff --git a/package.json b/package.json index df36a92f6..6733721cd 100644 --- a/package.json +++ b/package.json @@ -76,7 +76,7 @@ "jsrsasign": "^10.5.25", "katex": "^0.16.0", "lodash": "^4.17.21", - "matrix-js-sdk": "30.0.0", + "matrix-js-sdk": "30.0.1", "matrix-react-sdk": "3.84.1", "matrix-widget-api": "^1.3.1", "react": "17.0.2", diff --git a/yarn.lock b/yarn.lock index 9cdf7da43..788af2993 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8818,26 +8818,6 @@ matrix-events-sdk@0.0.1: resolved "https://registry.yarnpkg.com/matrix-events-sdk/-/matrix-events-sdk-0.0.1.tgz#c8c38911e2cb29023b0bbac8d6f32e0de2c957dd" integrity sha512-1QEOsXO+bhyCroIe2/A5OwaxHvBm7EsSQ46DEDn8RBIfQwN5HWBpFvyWWR4QY0KHPPnnJdI99wgRiAl7Ad5qaA== -matrix-js-sdk@30.0.0: - version "30.0.0" - resolved "https://registry.yarnpkg.com/matrix-js-sdk/-/matrix-js-sdk-30.0.0.tgz#8a0ed49ea7eb1d4a036107c5789edd1eb2e7d65a" - integrity sha512-v0fDomTGCEkeq97BI4viphTrd7Bn26Op1i+ssubFjlQs302Q5xTfuEVXUaMjuXkn9iUYm8daee1WNezo7kxoaQ== - dependencies: - "@babel/runtime" "^7.12.5" - "@matrix-org/matrix-sdk-crypto-wasm" "^2.2.0" - another-json "^0.2.0" - bs58 "^5.0.0" - content-type "^1.0.4" - jwt-decode "^3.1.2" - loglevel "^1.7.1" - matrix-events-sdk "0.0.1" - matrix-widget-api "^1.6.0" - oidc-client-ts "^2.2.4" - p-retry "4" - sdp-transform "^2.14.1" - unhomoglyph "^1.0.6" - uuid "9" - matrix-js-sdk@30.0.1: version "30.0.1" resolved "https://registry.yarnpkg.com/matrix-js-sdk/-/matrix-js-sdk-30.0.1.tgz#33a1fb2d9a9a8875f51f48a1b3124c1e82457472" From 3f2dea5b6b72402709c1e774961c10db5733e1d3 Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Mon, 13 Nov 2023 10:28:08 +0000 Subject: [PATCH 4/5] Prepare changelog for v1.11.49 --- CHANGELOG.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0f4c059af..9d2e6b189 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,12 @@ +Changes in [1.11.49](https://github.com/vector-im/element-web/releases/tag/v1.11.49) (2023-11-13) +================================================================================================= + +## ✨ Features + * Ship element-web as a debian package ([\#26533](https://github.com/vector-im/element-web/pull/26533)). Fixes #2777. + +## 🐛 Bug Fixes + * Ensure `setUserCreator` is called when a store is assigned ([\#3867](https://github.com/matrix-org/matrix-js-sdk/pull/3867)). Fixes vector-im/element-web#26520. Contributed by @MidhunSureshR. + Changes in [1.11.48](https://github.com/vector-im/element-web/releases/tag/v1.11.48) (2023-11-07) ================================================================================================= From 5b1b7acc625694cab63c81e3e09f856310e1bd56 Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Mon, 13 Nov 2023 10:28:08 +0000 Subject: [PATCH 5/5] v1.11.49 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 6733721cd..06e05d966 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "element-web", - "version": "1.11.48", + "version": "1.11.49", "description": "A feature-rich client for Matrix.org", "author": "New Vector Ltd.", "repository": {