From a86f2720bc856caef5111a352dae5d6751dac32b Mon Sep 17 00:00:00 2001 From: Richard van der Hoff Date: Thu, 27 Oct 2016 10:16:10 +0100 Subject: [PATCH 01/11] Avoid errors if olm is missing If olm isn't installed, webpack prints out scary warnings (though it still actually succeeds). Let's avoid scaring people by quietly removing it from the list of things to process. --- webpack.config.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/webpack.config.js b/webpack.config.js index bfd233b586..e1336f40fb 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -102,3 +102,12 @@ module.exports = { ], devtool: 'source-map' }; + +// olm is an optional dependency. Ignore it if it's not installed, to avoid a +// scary-looking error. +try { + require('olm'); +} catch (e) { + console.log("Olm is not installed; not shipping it"); + delete(module.exports.entry["olm"]); +} From f17e851435c2116908ac4fba6342324fc7cf1335 Mon Sep 17 00:00:00 2001 From: David Baker Date: Tue, 1 Nov 2016 15:22:06 +0000 Subject: [PATCH 02/11] Rename the package script/output dir to 'dist' To match conventions from other projects and match the release script which expects releasde artefacts in dist/ --- README.md | 6 +++--- package.json | 2 +- scripts/package.sh | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 180bcff5ce..1d18fbe155 100644 --- a/README.md +++ b/README.md @@ -54,14 +54,14 @@ to build. && npm install)` 1. Configure the app by copying `config.sample.json` to `config.json` and modifying it (see below for details) -1. `npm run package` to build a tarball to deploy. Untaring this file will give +1. `npm run dist` to build a tarball to deploy. Untaring this file will give a version-specific directory containing all the files that need to go on your web server. -Note that `npm run package` is not supported on Windows, so Windows users can run `npm +Note that `npm run dist` is not supported on Windows, so Windows users can run `npm run build`, which will build all the necessary files into the `vector` directory. The version of Vector will not appear in Settings without -using the package script. You can then mount the vector directory on your +using the dist script. You can then mount the vector directory on your webserver to actually serve up the app, which is entirely static content. config.json diff --git a/package.json b/package.json index 3fb456615d..619e1c595f 100644 --- a/package.json +++ b/package.json @@ -33,7 +33,7 @@ "build:bundle:dev": "webpack --optimize-occurence-order --progress", "build": "node scripts/babelcheck.js && npm run build:emojione && npm run build:css && npm run build:bundle", "build:dev": "npm run build:emojione && npm run build:css && npm run build:bundle:dev", - "package": "scripts/package.sh", + "dist": "scripts/package.sh", "start:emojione": "cpx \"node_modules/emojione/assets/svg/*\" vector/emojione/svg/ -w", "start:js": "webpack -w --progress --no-cache-buster", "start:js:prod": "NODE_ENV=production webpack -w --progress --no-cache-buster", diff --git a/scripts/package.sh b/scripts/package.sh index 73a1c51107..7cfb397465 100755 --- a/scripts/package.sh +++ b/scripts/package.sh @@ -5,11 +5,11 @@ set -e version=`git describe --dirty --tags || echo unknown` npm run build -mkdir -p packages +mkdir -p dist cp -r vector vector-$version echo $version > vector-$version/version -tar chvzf packages/vector-$version.tar.gz vector-$version +tar chvzf dist/vector-$version.tar.gz vector-$version rm -r vector-$version echo -echo "Packaged packages/vector-$version.tar.gz" +echo "Packaged dist/vector-$version.tar.gz" From 622ab27254e654dd8da1d4cf4d0dcae7e992f867 Mon Sep 17 00:00:00 2001 From: David Baker Date: Tue, 1 Nov 2016 15:35:41 +0000 Subject: [PATCH 03/11] gitignore dist --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 766f41c003..7811cc43d8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ /build /cert.pem +/dist /karma-reports /key.pem /lib From 890751951c3f3b66b6b49cf402c091285edfc165 Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:11:40 +0000 Subject: [PATCH 04/11] Released js-sdk & react-sdk --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 619e1c595f..e3916fd23c 100644 --- a/package.json +++ b/package.json @@ -59,8 +59,8 @@ "gfm.css": "^1.1.1", "highlight.js": "^9.0.0", "linkifyjs": "^2.1.3", - "matrix-js-sdk": "matrix-org/matrix-js-sdk#develop", - "matrix-react-sdk": "matrix-org/matrix-react-sdk#develop", + "matrix-js-sdk": "0.6.4-rc.2", + "matrix-react-sdk": "0.7.5-rc.1", "modernizr": "^3.1.0", "q": "^1.4.1", "react": "^15.2.1", From 3bfdbad5ba80042c05e7357b11753874f3bd9146 Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:17:36 +0000 Subject: [PATCH 05/11] Prepare changelog for v0.8.4-rc.1 --- CHANGELOG.md | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 76d9d9e46e..dba2ac8ec1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,45 @@ +Changes in [0.8.4-rc.1](https://github.com/vector-im/vector-web/releases/tag/v0.8.4-rc.1) (2016-11-02) +====================================================================================================== +[Full Changelog](https://github.com/vector-im/vector-web/compare/v0.8.3...v0.8.4-rc.1) + +Breaking Changes +---------------- + * End-to-end encryption now requires one-time keys to be + signed, so end-to-end encryption will not interoperate + with previous releases of vector-web. End-to-end encryption + remains in beta. + +Other Changes +------------- + * Rename the package script/output dir to 'dist' + [\#2528](https://github.com/vector-im/vector-web/pull/2528) + * Avoid errors if olm is missing + [\#2518](https://github.com/vector-im/vector-web/pull/2518) + * Put a cachebuster in the names of CSS and JS files + [\#2515](https://github.com/vector-im/vector-web/pull/2515) + * Bump to olm 2.0.0 + [\#2517](https://github.com/vector-im/vector-web/pull/2517) + * Don't include the world in the published packages + [\#2516](https://github.com/vector-im/vector-web/pull/2516) + * Use webpack to copy olm.js + [\#2514](https://github.com/vector-im/vector-web/pull/2514) + * Don't include two copies of the CSS in the tarball + [\#2513](https://github.com/vector-im/vector-web/pull/2513) + * Correct text alignment on room directory search + [\#2512](https://github.com/vector-im/vector-web/pull/2512) + * Correct spelling of 'rel' + [\#2510](https://github.com/vector-im/vector-web/pull/2510) + * readme tweaks + [\#2507](https://github.com/vector-im/vector-web/pull/2507) + * s/vector/riot/ in the readme + [\#2491](https://github.com/vector-im/vector-web/pull/2491) + * Switch to babel 6, again + [\#2480](https://github.com/vector-im/vector-web/pull/2480) + * Revert "Switch to babel 6" + [\#2472](https://github.com/vector-im/vector-web/pull/2472) + * Switch to babel 6 + [\#2461](https://github.com/vector-im/vector-web/pull/2461) + Changes in [0.8.3](https://github.com/vector-im/vector-web/releases/tag/v0.8.3) (2016-10-12) ============================================================================================ [Full Changelog](https://github.com/vector-im/vector-web/compare/v0.8.2...v0.8.3) From 4fb273284dcf946485dab2b2add27ebe86d90399 Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:17:36 +0000 Subject: [PATCH 06/11] v0.8.4-rc.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index e3916fd23c..0f341dec00 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vector-web", - "version": "0.8.3", + "version": "0.8.4-rc.1", "description": "Vector webapp", "author": "matrix.org", "repository": { From d04cc03c1c0d5a38b8d11206eb675f540fda494c Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:38:11 +0000 Subject: [PATCH 07/11] Take version from first arg, if given --- scripts/package.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/package.sh b/scripts/package.sh index 7cfb397465..64d555533c 100755 --- a/scripts/package.sh +++ b/scripts/package.sh @@ -2,7 +2,11 @@ set -e -version=`git describe --dirty --tags || echo unknown` +if [ $# -eq 1 ]; then + version=$1 +else + version=`git describe --dirty --tags || echo unknown` +fi npm run build mkdir -p dist From 7323ae5bf59bb79fb6c0d7b4c0638005129dca4b Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:40:04 +0000 Subject: [PATCH 08/11] Prepare changelog for v0.8.4-rc.2 --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index dba2ac8ec1..be3d87d94e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +Changes in [0.8.4-rc.2](https://github.com/vector-im/vector-web/releases/tag/v0.8.4-rc.2) (2016-11-02) +====================================================================================================== +[Full Changelog](https://github.com/vector-im/vector-web/compare/v0.8.4-rc.1...v0.8.4-rc.2) + + * Fix the version in the generated distribution package + Changes in [0.8.4-rc.1](https://github.com/vector-im/vector-web/releases/tag/v0.8.4-rc.1) (2016-11-02) ====================================================================================================== [Full Changelog](https://github.com/vector-im/vector-web/compare/v0.8.3...v0.8.4-rc.1) From 91793a7a8ebf93c7990c27511efc0d35b13850cf Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:40:04 +0000 Subject: [PATCH 09/11] v0.8.4-rc.2 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0f341dec00..aecf659645 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vector-web", - "version": "0.8.4-rc.1", + "version": "0.8.4-rc.2", "description": "Vector webapp", "author": "matrix.org", "repository": { From 03caaeef07913d26167a7acd72f1e2bef06ba1d6 Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 11:47:30 +0000 Subject: [PATCH 10/11] Back to develop js-sdk & react-sdk --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index aecf659645..3daddc2c23 100644 --- a/package.json +++ b/package.json @@ -59,8 +59,8 @@ "gfm.css": "^1.1.1", "highlight.js": "^9.0.0", "linkifyjs": "^2.1.3", - "matrix-js-sdk": "0.6.4-rc.2", - "matrix-react-sdk": "0.7.5-rc.1", + "matrix-js-sdk": "matrix-org/matrix-js-sdk#develop", + "matrix-react-sdk": "matrix-org/matrix-react-sdk#develop", "modernizr": "^3.1.0", "q": "^1.4.1", "react": "^15.2.1", From db07ef7899e61a661f487136222290b81becc941 Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Nov 2016 12:01:01 +0000 Subject: [PATCH 11/11] Update readme to point to github releases not /packages --- README.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 1d18fbe155..9d1fb48c0a 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ https://riot.im/develop for those who like living dangerously. To host your own copy of Riot, the quickest bet is to use a pre-built released version of Riot: -1. Download the latest version from https://vector.im/packages/ +1. Download the latest version from https://github.com/vector-im/vector-web/releases 1. Untar the tarball on your web server 1. Move (or symlink) the vector-x.x.x directory to an appropriate name 1. If desired, copy `config.sample.json` to `config.json` and edit it @@ -121,10 +121,11 @@ sudo npm install nativefier -g nativefier https://riot.im/app/ ``` -krisa has a dedicated electron project at https://github.com/krisak/vector-electron-desktop -(although you should swap out the 'vector' folder for the latest vector tarball you want to run. -Get a tarball from https://vector.im/packages or build your own - see Building From Source -above). +krisa has a dedicated electron project at +https://github.com/krisak/vector-electron-desktop (although you should swap out +the 'vector' folder for the latest vector tarball you want to run. Get a +tarball from https://github.com/vector-im/vector-web/releases or build your own +- see Building From Source above). There's also a (much) older electron distribution at https://github.com/stevenhammerton/vector-desktop