Commit Graph

545 Commits (772019711d472809f0eb0add49783b8333e6dcb6)

Author SHA1 Message Date
Travis Ralston 3614170906 Disable scripts in CI too 2020-04-16 12:47:25 -06:00
Travis Ralston 005269e2ad Make Jitsi download script a JS script
It's awful but means that we create the directory on all platforms in-process.

Fixes https://github.com/vector-im/riot-web/issues/13215
2020-04-16 12:37:41 -06:00
Danny Colin c128e75f5d fix build:jitsi scripts crash caused by a missing folder
On a freshly install of the developer environment, the build:jitsi try
to create a file in ./webapp with the cURL command. However, ./webapp
folder doesn't exist and the build script crash. This patch makes sure
the appropriate folder is created if it doesn't already exist

Signed-off-by: Danny Colin <contact@dannycolin.com>
2020-04-10 14:14:19 -04:00
Michael Telatynski 68608c2bcb Fix gen-i18n.js script for .ts files
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2020-04-08 21:42:12 +01:00
David Baker fea600ba0a Fix artifact searching in redeployer
Indenting fail
2020-03-25 15:12:53 +00:00
J. Ryan Stinnett 4afe7a73c4 Fix version for Docker builds
This (should) fix the version script for Docker builds by testing the branch
with a regex instead of single char glob.

Fixes https://github.com/vector-im/riot-web/issues/12777
2020-03-19 21:00:37 +00:00
David Baker 544e2c9971 Don't use buildkite agent to upload logs 2020-03-18 20:56:02 +00:00
Travis Ralston 7dd7417f12 Enable support for TypeScript in components
Includes: compilation, translations, IDE support (use .tsx not .ts), typings, and other build tools.

TypeScript component have to import PropTypes and React with `import * as React from 'react';`
2020-03-11 18:03:43 -06:00
Travis Ralston b0f71bc990 Fix Docker image version for develop builds
Turns out it helps to use the right syntax.

Fixes https://github.com/vector-im/riot-web/issues/12009
2020-03-09 19:57:52 -06:00
Jonas Fentker f5bd5a345e docker: download required branch only 2020-03-04 23:14:42 +01:00
J. Ryan Stinnett 096a828e44 Change Windows signing to warning when missing token
This allows Windows builds to complete when the singing token is not present.
2020-02-26 11:54:20 +00:00
J. Ryan Stinnett bdb395aa41 Change to banner style 2020-02-25 12:05:36 +00:00
J. Ryan Stinnett 420537a64d Relax macOS notarisation check to print a warning
This makes it a bit more friendly to build macOS Electron builds without a
notarisation config set up by only warning when it is missing.
2020-02-25 11:44:33 +00:00
Bruno Windels cda281044d ignore node_modules in e2e tests 2020-02-21 14:18:28 +01:00
Jason Robinson 9534a25270 Fix contribute.json location as per spec
Signed-off-by: Jason Robinson <jasonr@matrix.org>
2020-02-05 16:28:44 +02:00
Jason Robinson 3abe61e13b Add contribute.json
This document is required for example for all Mozilla websites
and makes sense for Riot to also describe itself - see
https://www.contributejson.org/

Signed-off-by: Jason Robinson <jasonr@matrix.org>
2020-02-05 15:25:09 +02:00
Michael Telatynski b099c983d6 Use minimist instead of optimist as it is deprecated 2020-02-04 10:16:39 +00:00
David Baker 57ee99d6f7 chmod 2020-01-24 14:30:41 +00:00
David Baker 5536384866 Do less unnecessary work on CI
We were checking out & installing the develop js-sdk explicitly
in cases where we didn't need it at all. We were babeling the src
folder many, many times over (in some cases twice in the same job)
and never using the output at all.
2020-01-24 14:21:28 +00:00
J. Ryan Stinnett b6963d0e5c Use bash in Docker scripts
Our Docker scripts use Bash-style conditionals that aren't supported by the
default Debian shell.
2020-01-22 17:45:22 +00:00
Travis Ralston 708f62784f
Consistency
Co-Authored-By: J. Ryan Stinnett <jryans@gmail.com>
2020-01-21 10:59:33 -07:00
Travis Ralston 33220c2d72 Ensure generated files are present for riot-web tests 2020-01-21 10:53:17 -07:00
Travis Ralston 3b2f96bc04 Try explicitly mapping the directory 2020-01-20 18:02:54 -07:00
Travis Ralston 776b3af6bb Fix relative pathing on riot-web link 2020-01-20 16:33:22 -07:00
Travis Ralston 19615d3721 Disable minification of Riot in end-to-end tests 2020-01-20 16:33:13 -07:00
Travis Ralston 27412ba0b2 Fix end-to-end test layering too 2020-01-20 16:23:33 -07:00
Travis Ralston 3eeeb9c6af Remove irrelevant build steps 2020-01-20 16:20:02 -07:00
Travis Ralston 62b1dd77a6 Fix layering of the riot-web tests pipeline 2020-01-20 16:12:59 -07:00
Travis Ralston 909fddb732 Don't minifiy builds of develop through CI packaging
Fixes https://github.com/vector-im/riot-web/issues/11864

This uses an environment variable because the build script assumes you want a production build, but we don't for this particular script. To avoid having a mess of NPM scripts to worry about, we'll just pass a flag down.
2020-01-15 12:19:45 -07:00
Travis Ralston 8f37f8638d Build the js-sdk for Jest tests
This is theoretically a fix for the tests failing post-sourcemaps.
2020-01-15 10:28:27 -07:00
Travis Ralston a978a6734f Fix CI tests
There's a bunch of generated files that webpack relies on to work, and Karma works off webpack. To make both happy we've added
a new `build:genfiles` script which takes care of this for us. We also have to install and build our other layers to get the
same effect (like generating the react-sdk's component index, while we still have one).

This commit also fixes all the imports in the tests because they were just wrong. They should have been caught in the ES6ification
earlier, but were missed.
2020-01-13 20:40:00 -07:00
Travis Ralston f73d2bae1f Merge branch 'develop' into travis/sourcemaps 2020-01-13 11:22:47 -07:00
Dale Harvey a41484cb35 Add stub service worker so users can install on desktop with Chrome
Signed-off-by: Dale Harvey <dale@arandomurl.com>
2020-01-10 19:08:56 +00:00
Travis Ralston a8c8406ac4 Merge remote-tracking branch 'origin/t3chguy/jest' into travis/sourcemaps 2020-01-09 16:06:46 -07:00
Travis Ralston fde32f13a5 [CONFLICT CHUNKS] Merge branch 'develop' into travis/sourcemaps-develop 2020-01-09 14:15:09 -07:00
Travis Ralston 9bf1c65971 [CONFLICT CHUNKS] Merge branch 'develop' into travis/sourcemaps-dev 2020-01-09 13:43:25 -07:00
Travis Ralston ec66069e96 Update build scripts for new process
We have to convert *something* to TypeScript so it doesn't complain that there's nothing to compile, so this converts the easiest utility library.

Many of the scripts are copied from the react-sdk.
2020-01-08 16:09:42 -07:00
David Baker 2970a9faaf Don't fail if logs exists and is an empty dir 2020-01-03 15:16:02 +00:00
Travis Ralston 3389f7afc9 Fix version file for Docker images
Fixes https://github.com/vector-im/riot-web/issues/11642
2019-12-24 18:34:40 -07:00
Michael Telatynski d35b01b63a Get rid of stripped-emoji.json in favour of an in-memory single truth source 2019-12-18 15:40:19 +00:00
Michael Telatynski 386d6ec055 we don't need to install riot-web for react-sdk unit tests 2019-12-17 12:16:40 +00:00
Travis Ralston 20a615396b Implementation of new potential skinning mechanism
With a switch to Only One Webpack™ we need a way to help developers generate the component index without a concurrent watch task. The best way to do this is to have developers import their components, but how do they do that when we support skins? The answer in this commit is to change skinning.

Skinning now expects to receive your list of overrides instead of the react-sdk+branded components. For Riot this means we send over *only* the Vector components and not Vector+react-sdk. 

Components can then be annotated with the `replaceComponent` decorator to have them be skinnable. The decorator must take a string with the dot path of the component because we can't reliably calculate it ourselves, sadly. 

The decorator does a call to `getComponent` which is where the important part of the branded components not including the react-sdk is important: if the branded app includes the react-sdk then the decorator gets executed before the skin has finished loading, leading to all kinds of fun errors. This is also why the skinner lazily loads the react-sdk components to avoid importing them too early, breaking the app.

The decorator will end up receiving null for a component because of the getComponent loop mentioned: the require() call is still in progress when the decorator is called, therefore we can't error out. All usages of getComponent() within the app are safe to not need such an error (the return won't be null, and developers shouldn't use getComponent() after this commit anyways).

The AuthPage, being a prominent component, has been converted to demonstrate this working. Changes to riot-web are required to have this work.

The reskindex script has also been altered to reflect these skinning changes - it no longer should set the react-sdk as a parent. The eventual end goal is to get rid of `getComponent()` entirely as it'll be easily replaced by imports.
2019-12-12 19:48:45 -07:00
David Baker 604745de96
Merge pull request #3698 from matrix-org/dbkr/chmod_ci
Make CI scripts executable
2019-12-05 11:39:58 +00:00
David Baker c44cfff7cf Remove logs before running end-to-end tests
Hopefully will stop the end-to-end tests failing when buildkite
re-uses an agent.
2019-12-04 11:17:41 +00:00
David Baker c36950db23 Make CI scripts executable
and remove chmod line from pipeline
2019-12-04 10:30:37 +00:00
Travis Ralston 831522d02d Update Lithuanian language name
By request: https://matrix.to/#/!yvhoprZiKmhjxKfNHa:matrix.org/$E_5Waedui4X866edAWmYVAjg6vv-vwAXRHN4h0DKY6s?via=matrix.eclabs.de&via=matrix.org&via=dodsorf.as
2019-12-03 23:14:40 -07:00
Travis Ralston ea1ed19a92
Merge pull request #11592 from vector-im/travis/more-language
Enable more languages
2019-12-03 10:11:54 -07:00
Travis Ralston e4bf84701d Use ISO code table as a source instead
https://en.wikipedia.org/wiki/List_of_ISO_639-2_codes
2019-12-03 09:52:10 -07:00
Travis Ralston a76f897171 Enable more languages
Enabled (riot-web % / react-sdk %):
* Lithuanian: 100% / 48.1% translated
* Hindi: 69.6% / 36.5% translated
* Ukrainian: 100% / 28.5% translated
* Icelandic: 43.5% / 27.7% translated

They aren't the highest languages, but they are more than our lowest translated & enabled languages.
2019-12-02 20:55:16 -07:00
Travis Ralston 726bf35b76 Fix Docker build for develop and publish a /version file
Fixes https://github.com/vector-im/riot-web/issues/10426
2019-12-02 16:58:50 -07:00
RiotRobot b93b6b448e Restore creation of the dist directory 2019-11-27 13:02:14 +00:00
RiotRobot d0c8a6af50 Copy signed Windows installers to pub directory 2019-11-27 12:44:40 +00:00
RiotRobot dd9305140b Only log signing command when it fails 2019-11-27 12:22:51 +00:00
RiotRobot cde5c9c027 Remove redundant Windows installer signing
The signing in `electron-package.sh` is no longer needed, since it's already
handled in the new sign script for `electron-builder`.
2019-11-27 12:15:05 +00:00
RiotRobot 99ee0fc72d Fix Windows signing args
The hash arg seems to only accept the short `-h` form. In addition, the args in
the environment contained a fixed hash type which is removed here.
2019-11-27 11:54:33 +00:00
David Baker 070d5fc6e8 Sign all of the Windows executable files
We can actually just supply a custom signing module here to do our
signing rather than manually signing things in the afterSign hook.
This means all 4 executable files get signed (the main exe, the
stub exe, Update.exe and the installer).
2019-11-26 12:08:29 -07:00
David Baker 64c23ae18d Fix error/exception in electron signing script
'Exception' isn't a thing: Error is
2019-11-19 15:55:03 +00:00
Bruno Windels b03ebb964b split up installing static webserver and riot copy
so we can just do the latter for the e2e tests on CI
2019-10-18 17:18:18 +02:00
David Baker 8e81685a9f
Merge pull request #11126 from vector-im/dbkr/windows_signing
Sign main Windows executable
2019-10-18 12:02:04 +01:00
David Baker 94e721acf2 Update cert name & do bash globbing correctly 2019-10-18 10:31:45 +01:00
David Baker 3545b2751d
typo
Co-Authored-By: Travis Ralston <travpc@gmail.com>
2019-10-18 10:08:43 +01:00
David Baker 21ea6c6283
Merge pull request #11119 from vector-im/dbkr/notarise
Notarise the macOS app
2019-10-11 15:48:04 +01:00
Nazım Can Altınova dd9898e687 Fix the label of Turkish language
Türk means Turkish as nationality and Türkçe means Turkish as language.
2019-10-11 14:01:16 +02:00
David Baker 1ff06c4be4 Missing space
also don't print the signing command line as it has the token password
2019-10-11 12:21:28 +01:00
David Baker 5a7efcd738 Sign the main executable on windows
and automate the signing of the installers
2019-10-11 12:01:50 +01:00
David Baker 071223120b Warn that this might be a while 2019-10-11 10:45:42 +01:00
David Baker 2bab328f8d Check everything's in place for the notarising dance
...before we start the build process.
2019-10-10 15:32:17 +01:00
David Baker 7faba49f66 fix quotes 2019-10-10 11:53:49 +01:00
Bruno Windels 645a9d836f install static webserver for server symlinked riot on CI 2019-10-10 11:40:04 +02:00
David Baker bad97db302 remove random spaces 2019-10-09 16:40:31 +01:00
David Baker ff70339aad Working branch for notarisation 2019-10-09 16:29:24 +01:00
Bruno Windels 5b9bfae320 first attempt at running local e2e tests from CI 2019-10-09 17:03:01 +02:00
J. Ryan Stinnett 54767b5a65 Clean Yarn cache during Electron builds 2019-09-27 12:49:13 +01:00
Travis Ralston 6b07186078 Verify i18n in CI 2019-07-11 12:45:06 -06:00
Travis Ralston f6af464fff Verify i18n in CI
To protect developers from mistakes such as missing strings or getting them out of order.
2019-07-11 12:37:17 -06:00
J. Ryan Stinnett aaceaf097c Add Albanian language 2019-06-04 17:45:59 +01:00
J. Ryan Stinnett 1c42ee1a30 Add West Flemish language 2019-06-04 17:43:28 +01:00
Matthew Hodgson 4cbe6c1000 remove emojione 2019-05-19 21:26:11 +01:00
Matthew Hodgson dbc6815abf make EmojiProvider and stripped-emoji.json work 2019-05-19 20:48:18 +01:00
Matthew Hodgson dc72641264 replace emojione with twemoji. completely untested & debugged & unoptimised 2019-05-19 15:23:43 +01:00
Travis Ralston 3123b429f7 Increase timeout for yarn install in Docker builds
Otherwise we run into problems where Docker Hub's limited machines timeout trying to download our dependencies
2019-05-15 16:24:25 -06:00
David Baker a7756fc876 Respond quickly to buildkite pokes
Otherwise it thinks they have failed, as per comment.
2019-05-02 18:05:11 +01:00
Travis Ralston 9957149115
Merge pull request #9426 from vector-im/travis/dockerfile-continued
Add Dockerfile (part 2)
2019-05-01 10:42:21 -06:00
David Baker 77dff119db Fix variable scope in redeployer 2019-04-26 16:26:48 +01:00
David Baker 0718d438b8 Fix more typos in redeployer 2019-04-26 16:19:49 +01:00
David Baker 3a2541d3bf more logging for auto-deployer 2019-04-26 16:16:14 +01:00
David Baker f49732b036 Link to buildkite webhook docs 2019-04-26 15:41:20 +01:00
J. Ryan Stinnett 73144c3493
Typing is hard
Co-Authored-By: dbkr <dbkr@users.noreply.github.com>
2019-04-26 15:40:23 +01:00
J. Ryan Stinnett c5e7e82b46
I can't type buildkite
Co-Authored-By: dbkr <dbkr@users.noreply.github.com>
2019-04-26 15:40:05 +01:00
David Baker af6ad9355d Convert redeploy.py to buildkite 2019-04-26 15:26:03 +01:00
David Baker c62da0eda6 Don't fail if there's no local config to remove
The script has a set -e so don't fail if there's nothing to rm
2019-04-26 14:13:02 +01:00
David Baker afc2b48073 combine sets 2019-04-26 12:22:32 +01:00
David Baker 1b8583fa51 Change jenkins script to package script
Take the useful part of the jenkins script and put it in a script
that makes a package with the git hashes as its version.
2019-04-26 11:25:41 +01:00
J. Ryan Stinnett 8002d98f50 Remove config.json from package dir 2019-04-24 11:28:26 +01:00
David Baker addca871ad Fix default for --include arg
nargs options are arrays and we assume it's an array later, so it
would iterate over each char of the string if left as the default
2019-04-17 18:31:36 +01:00
Travis Ralston 1bb70930fa Support custom SDKs and use yarn 2019-04-10 15:47:02 -06:00
Bruno Windels f5f89ee4e3 move package installation to docker image to avoid on every run 2019-04-09 17:56:03 +02:00
Bruno Windels 57092eeb4f add buildkite sections 2019-04-09 17:27:49 +02:00
Bruno Windels 7dde322ce2 only need to invoke artifact tool once 2019-04-09 17:19:29 +02:00
Bruno Windels 64f123563b upload separate log files 2019-04-09 17:16:39 +02:00
Bruno Windels 6a4a443c26 attempt at uploading logs as artefacts 2019-04-09 16:20:33 +02:00
Bruno Windels 5802a1d9eb also show test logs 2019-04-09 15:11:33 +02:00
Bruno Windels 309d2ead8f dump server log after running tests 2019-04-09 14:39:31 +02:00
Bruno Windels addafe224f need to disable sandbox because ci tests run as root and puppeteer wont let you do stupid stuff by accident 2019-04-05 17:39:41 +02:00
Bruno Windels 4eeaf05e81 no sandbox didn't work, lets try installing a gazilion deps from the puppeteer page 2019-04-05 17:29:33 +02:00
Bruno Windels af0dee0d65 disable sandbox to run under debian 2019-04-05 16:45:41 +02:00
Bruno Windels 711974a6df remove obsolete --travis flag 2019-04-03 17:05:19 +02:00
J. Ryan Stinnett 52ad757cf4 Switch to `git` protocol for CI dependencies
If you try to clone a repo that doesn't exist via `https`, `git` will prompt for
auth credentials and hang forever. Using `git` avoids this and fails immediately
instead, which is what we want for a missing repo.

Part of https://github.com/vector-im/riot-web/issues/9221
2019-03-20 18:06:18 +00:00
J. Ryan Stinnett 6f79e8503a Switch to `git` protocol for CI dependencies
If you try to clone a repo that doesn't exist via `https`, `git` will prompt for
auth credentials and hang forever. Using `git` avoids this and fails immediately
instead, which is what we want for a missing repo.

Part of https://github.com/vector-im/riot-web/issues/9221
2019-03-20 18:06:07 +00:00
J. Ryan Stinnett f5c28a19e1 Support CI for matching branches on forks
Currently, people with push access to the main Riot repos can push matching
branch names to Riot and the SDKs, and CI will test all the branches together.
This change allows contributors to access the same ability when submitting
several matching PRs from their fork of each repo.

Part of https://github.com/vector-im/riot-web/issues/9041
2019-03-19 18:17:27 +00:00
J. Ryan Stinnett 02569fca4b Support CI for matching branches on forks
Currently, people with push access to the main Riot repos can push matching
branch names to Riot and the SDKs, and CI will test all the branches together.
This change allows contributors to access the same ability when submitting
several matching PRs from their fork of each repo.

Part of https://github.com/vector-im/riot-web/issues/9041
2019-03-19 16:59:31 +00:00
Travis Ralston 6d7703dcb6 Re-introduce `yarn test` and fix comments 2019-03-15 11:19:05 -06:00
Travis Ralston 365c8e9fdc Fetch downstream dependencies from as many places as possible
Gives the build the best possible chance at passing
2019-03-15 10:34:30 -06:00
Travis Ralston 5b68a70da1 Remove uneeded CHROME_BIN env setter 2019-03-15 10:33:55 -06:00
Travis Ralston df7b617881 Fix downstream branch fetching
We should be giving the PR the best possible chance at passing the build.
2019-03-15 10:23:43 -06:00
Travis Ralston ef6313fbb4 Use the right CI branch 2019-03-13 22:44:28 -06:00
Travis Ralston cab5f7aba4 Use the right branch for fetching dependencies 2019-03-13 22:44:09 -06:00
Travis Ralston 618b2b1ae6 Add basic BuildKite :pipeline: 2019-03-13 17:42:05 -06:00
J. Ryan Stinnett 1312ba537a Update scripts and docs to use `yarn` where appropriate
Most `npm` operations are replaced with `yarn`, which generally has better
behavior. However, steps like publish that write to the NPM registry are left to
`npm`, which currently handles these tasks best.
2019-03-12 11:06:57 +00:00
J. Ryan Stinnett d9063bbf8e Maybe bash instead of dash 2019-03-11 18:36:45 +00:00
J. Ryan Stinnett 337ac2f6a0 Reorder link and install steps
Take advantage of Yarn's preservation of links while installing and set up links
first and install second. This should result in a small speedup since we no
longer install the published SDKs just to replace them on the next line.
2019-03-11 18:36:45 +00:00
J. Ryan Stinnett 7c947d87ab Update scripts and docs to use `yarn` where appropriate
Most `npm` operations are replaced with `yarn`, which generally has better
behavior. However, steps like publish that write to the NPM registry are left to
`npm`, which currently handles these tasks best.
2019-03-11 14:22:02 +00:00
David Baker 12a56e37ba Don't copy the 32 bit linux deb
As per comment
2019-03-07 11:12:43 +00:00
David Baker 7b684aee0c Also makes this unnecessary 2019-03-06 16:48:58 +00:00
David Baker 8543c7b9ff Merge branch 'release-v1.0.2' 2019-03-06 11:36:41 +00:00
David Baker 1e7af106b0 Merge branch 'master' into develop 2019-03-06 11:28:54 +00:00
David Baker 53e25ff247 Set a resuire alias for the webapp directory
So languagehandler can pull the languages json from there
2019-03-01 11:32:37 +00:00
David Baker 63c6f600bf Use webpack alias to resolve the languages file
Hopefully this will end up simpler than having to figure out in
riot-web what the relative path is from react-sdk's
src/languageHandler.js to riot-web's webapp directory.
2019-03-01 11:30:50 +00:00
Bruno Windels 712522a16d set chrome path for travis CI explicitly
karma seems to be giving priority to a location where an old version is installed.
2019-02-28 12:45:43 +01:00
J. Ryan Stinnett 09b17f77c2 Fix language file path for Jenkins
Jenkins seems to use a different layout of the repos than other environments.
The sub-projects are cloned inside of the `riot-web` workspace. To account for
this, we need to adjust the Riot language file path.
2019-02-21 12:31:45 +00:00
Bruno Windels e56206241b use same hash format as webpack defaults 2019-02-20 09:39:27 +01:00
Richard van der Hoff d4e1f1af7a
Fix cleanup script not to remove extracted/bundles directories (#8764) 2019-02-18 17:05:48 +00:00
Bruno Windels 6bf8269bcd riot-web is a subdirectory when running the tests 2019-02-18 17:26:09 +01:00
Bruno Windels 878190ba27 add content hash to individual language files 2019-02-18 16:11:41 +01:00
Matthew Hodgson 20dc7068af
Merge pull request #8550 from abeluck/develop
Make scripts/make-icons.sh work on linux
2019-02-15 12:28:58 +00:00
J. Ryan Stinnett 674b8c3561 Merge branch 'release-v1.0.0' 2019-02-14 17:11:09 +00:00
J. Ryan Stinnett 4872992ba2 Make arch specific directories 2019-02-14 13:13:53 +00:00
J. Ryan Stinnett 2b069fce75 Copy unsigned builds to separate dirs 2019-02-14 13:05:49 +00:00
J. Ryan Stinnett 0f4757c289 Fix up packaging directories for Windows 2019-02-14 12:54:26 +00:00
Abel Luck d395fdcc6a
Make scripts/make-icons.sh work on linux
This commit detects if the macos-only utility `iconutil` is available in
the PATH, if it is, then the icns is built as usual. However if it
isn't (such as on a linux system), then it checks for `png2icns` and
uses it if possible.

Signed-off-by: Abel Luck <abel@guardianproject.info>
2019-02-13 11:59:36 +01:00
J. Ryan Stinnett 7b9de1dbf2 Remove Status theme 2019-02-13 10:47:51 +00:00
J. Ryan Stinnett dd51cccd7c Move home to welcome, remove unused images 2019-02-07 17:10:38 +00:00
vectorwebexp@ares c421c0b1bf cleanup script for the deployment dir
-- richvdh
2019-02-02 22:43:43 +00:00
David Baker 03de7f9901 Cache-bust olm.wasm
In the same way as we now do images/fonts
2019-01-28 14:09:28 +00:00
David Baker a28691f14d Add returns to fetch-develop-deps
These look necessary for https://github.com/vector-im/riot-web/pull/8225
to work - the build is failing on jenkins
2019-01-23 11:40:21 +00:00
J. Ryan Stinnett cf150fc575 Try fetching more branches for PRs
Attempt both the PR author's branch and the PR's target branch. This resolves
issues on experimental where we need matrix-react-sdk to also be experimental.
2019-01-22 21:28:09 -06:00
J. Ryan Stinnett 49be03e845 Process images with Webpack
This adds a `file-loader` rule to the Webpack build so that any requests for
image resource will be output into the app's output directory, but with an extra
content has appended so that we can safely use a long cache lifetime.

The CSS and SCSS rules are also changed to use `css-loader` so that any `url`
inside is automatically processed by the new image rule above.
2019-01-18 08:39:09 -06:00
Bruno Windels 19190deb3c set x perms 2019-01-09 15:20:55 +01:00
Bruno Windels 45558f5323 run both react-sdk and riot-web tests 2019-01-09 15:16:20 +01:00
Bruno Windels 509ae4cea4 run unit tests on riot-web like before 2019-01-09 15:02:20 +01:00
Bruno Windels 419726f423 set executable perms 2019-01-09 14:43:05 +01:00
Bruno Windels 481cd292ad make e2e tests job conditional at travis.yml level 2019-01-09 14:36:32 +01:00
Bruno Windels 5ce08523f8 split up script for unit and end-to-end tests so unit tests are not run as part of e2e tests 2019-01-09 14:21:45 +01:00
Erik Johnston ab468b5346 Refactor travis-ci to use parallel jobs 2019-01-08 11:33:12 +00:00
Travis Ralston 8017f0a4a1 Merge remote-tracking branch 'origin/experimental' into travis/develop-for-real 2019-01-03 16:00:23 -07:00
David Baker f928be6f59 Revert "Merge pull request #2395 from matrix-org/dbkr/merge_develop_experimental"
This reverts commit ad47144355.
2019-01-03 15:37:03 -07:00
David Baker 7d161de35b Partial merge of develop to experimental
Does not include #2336 as the file has been moved out from underneath it:
will do this separately
2019-01-03 15:02:58 +00:00
J. Ryan Stinnett 135a0884c9
Update scripts/fetchdep.sh
Co-Authored-By: turt2live <travpc@gmail.com>
2018-12-28 19:42:13 -07:00
Travis Ralston 310f634a0d Ensure we install the master branch of the e2e tests as a default 2018-12-21 19:24:07 -07:00
J. Ryan Stinnett 7affd5fcff Try fetching more branches for PRs
Attempt both the PR author's branch and the PR's target branch. This resolves
issues on experimental where we need riot-web to also be experimental.
2018-12-20 22:58:09 +00:00
Travis Ralston a2b825ba92 Sort translations by file name
This keeps the strings close together and roughly in the same area as the others, and makes it easier to maintain the translation file.
2018-12-05 11:52:10 -07:00
David Baker 8298e73205 Argh, npm, why are you so awful? 2018-11-21 19:25:11 +00:00
David Baker d2c87a0331 Fix jenkins build 2018-11-21 19:13:42 +00:00
David Baker 7df77d7e5d Recent node please 2018-11-21 19:00:11 +00:00
Aaron Raimist 2f991d190f
Add Japanese (#7599)
Signed-off-by: Aaron Raimist <aaron@raim.ist>
2018-11-08 13:31:09 -06:00
David Baker 9b80aa76ce
Merge pull request #7385 from vector-im/dbkr/wasm
Support WebAssembly version of Olm
2018-10-25 15:58:24 +01:00
David Baker de7d3ba701 Change electron build script paths
Because electron builder has decided to output the mac assets to
somewhere else today.
2018-10-16 10:26:04 +01:00
David Baker c5ee92f4c3 Fall back to legacy asm.js Olm 2018-10-04 20:11:34 +01:00
David Baker 30f0a7932b Merge remote-tracking branch 'origin/develop' into dbkr/wasm 2018-10-02 16:58:31 +01:00
Travis Ralston fb262596b2 Provide more helpful errors when i18n generation fails
Also fix TextForEvent.js so it doesn't break the script. Using a variable here is not recognized, so the object has been moved inline instead.
2018-09-27 11:55:57 -06:00
David Baker 1f34d2d644 Kill off olm-loader
Now that Olm needs to be inited asynchronously anyway, we can just
pass the options to Olm.init(), and as long as we do that before we
start the js-sdk, we're all good.

This will means the olm js is now part of the main bundle but since
it's now just a wrapper around the wasm, this is probably faster.

Also add the directwatch flag to olm.wasm because otherwise it
doesn't seem to copy the file in watch mode...
2018-09-26 16:44:52 +01:00
Travis Ralston 4041f3db5c Send standard output/input from npm-sub.js to the parent proc 2018-09-25 15:54:38 -06:00
Travis Ralston 91304e70a1 Swap out the complicated canary stuff for serial execution
Fixes https://github.com/vector-im/riot-web/issues/7386
2018-09-25 15:49:14 -06:00
Travis Ralston 27c23058dc Alter build process to rely on canaries only
With the react-sdk and js-sdk having their `npm start`s split out (as per https://github.com/matrix-org/matrix-react-sdk/pull/2175 and https://github.com/matrix-org/matrix-js-sdk/pull/742) we can trigger an initial build ourselves and start the watcher afterwards. This canary approach has a very slight speed increase over serially running all the commands as the watcher can be started as early as possible.

This all can be improved and potentially eliminated with a bit more planning, however: https://github.com/vector-im/riot-web/issues/7386
2018-09-25 11:20:58 -06:00
David Baker c511902356 Support WebAssembly version of Olm.
* Olm no longer supports setting the stack/memory size at runtime,
   so don't (they're now set to be that in the Olm build).
 * Copy the wasm file from the Olm library (see multiple comments
   about it being in the wrong place and webpack being awful).
2018-09-25 17:55:41 +01:00
Travis Ralston 8d7cec2a94 Add some comments to describe the build process 2018-09-24 17:57:18 -06:00
Travis Ralston 2b037ee146 Prevent races by blocking on SDK builds
If we don't block on SDK builds, then the riot-web build fails due to half-built dependencies. This needs to be done at two levels: the js-sdk because it is used by both the react-sdk and riot-web, and at the react-sdk because riot-web needs it. This means our build process is synchronous for js -> react -> riot, at least for the initial build. 

This does increase the startup time, particularly because the file watch timer is at 5 seconds. The timer is used to detect a storm of file changes in the underlying SDKs and give the build process some room to compile larger files if needed. 

The file watcher is accompanied by a "canary signal file" to prevent the build-blocking script from unblocking too early. Both the js and react SDKs build when `npm install` is run, so we ensure that we only listen for the `npm start` build for each SDK.

This is all done at the riot level instead of at the individual SDK levels (where we could use a canary file to signal up the stack) because:
* babel (used by the js-sdk) doesn't really provide an "end up build" signal
* webpack is a bit of a nightmare to get it to behave at times
* this blocking approach is really only applicable to riot-web, although may be useful to some other projects.

Hopefully that all makes sense.
2018-09-24 17:12:42 -06:00
Travis Ralston c6da122e41 Fix npm link in the build script 2018-09-17 17:57:27 -06:00
Travis Ralston 67e9606d55 Reduce the number of terminals required to build riot-web to 1
A step towards a real solution for https://github.com/vector-im/riot-web/issues/7305

This approach makes use of `npm link` to remove the use of symlinks in the build process. The build process has also been altered to invoke the build process of each underlying SDK (react, js). This means that one can now `npm link` and `npm start` and have a working environment. 

At the same time, parallelshell was dropped due to lack of maintenance from the maintainer.
2018-09-17 17:50:03 -06:00
David Baker e1394d592a
Allow translation tags object to be a variable
Don't try to validate the translation tags if it's not an object literal.
2018-09-14 14:11:59 +01:00
David Baker 8a167d2743 Add Norsk & Italian 2018-08-16 15:04:17 +01:00
Michael Telatynski 07f0713a56
allow autocompleting Emoji by common aliases, e.g 👍 to 👍
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2018-07-24 17:06:45 +01:00
Michael Telatynski 7225f7372c
Revert " make click to insert nick work on join/parts, /me's etc" 2018-07-03 10:30:08 +01:00
Michael Telatynski dddf7991b9
create map-i18n to aid with transforming the i18n entries not to waste them
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2018-06-29 14:56:06 +01:00
David Baker 9f8202c8a9 Remove directories if they exist 2018-05-02 16:49:08 +01:00
David Baker 82349ec933 Fix sed 2018-05-02 16:43:51 +01:00
David Baker 183947615f Fux up jenkins origin/ branches 2018-05-02 16:39:10 +01:00
David Baker 0040ea0d9f Use develop js-sdk in travis build 2018-05-02 15:53:38 +01:00
David Baker 9bccecf449 Get symlink right
Also No need to cd into the symlink, can just go straight there
2018-05-02 11:23:57 +01:00
David Baker 825d610938 Bah, no pushd.
Also this npm install should now be unnecessary
2018-05-02 11:13:16 +01:00
David Baker c54198464b npm install the js-sdk 2018-05-02 11:09:28 +01:00
David Baker b44582777b Would if I added the script 2018-05-02 11:03:40 +01:00
David Baker 730512bc3f Use the right js-sdk branch when testing
On the react-sdk tests not just riot-web
2018-05-02 10:58:43 +01:00
David Baker 0abaff5aed Copy media from react-sdk
Looks like this just got missed

Fixes https://github.com/vector-im/riot-web/issues/6586
2018-04-23 17:27:35 +01:00
David Baker f012dd5f31 Fix favicon
In removing 'media' here, it changed the meaning of the copy so
the contents of vector-icons (rather than the dir itself) got
copied to webapp/
2018-04-23 11:28:01 +01:00
Matthew Hodgson a46b718b4a copy resources from their new locations 2018-04-13 01:49:52 +01:00
Matthew Hodgson 40a67ca8fe point imports at the new locations 2018-04-13 00:43:44 +01:00
Krombel 57803f7a41 reorder based on language code 2018-03-17 16:24:47 +01:00
Krombel 14f70beac2 Add languages (czech, galician and serbian) 2018-03-17 11:27:10 +01:00
Luke Barnard 075f568f61 Fix crash; fs event received /w langauge file empty
It was common, at least for me, to experience a crash produced
when running the `matrix-react-sdk/scripts/gen-i18n.js` script
because when writing en_EN.json (via the script or otherwise)
choikdar would receive an event and cause the file to be read,
but the file would be empty when clearly it wasn't.

This would happen even when doing an atomic write in gen-i18n.

The fix adds a debounce as a workaround.
2018-03-02 15:30:06 +00:00