Skip to content

Commit

Permalink
Merge branch 'new-reports-ui' of https://github.com/wreiske/Rocket.Chat
Browse files Browse the repository at this point in the history
… into new-reports-ui

* 'new-reports-ui' of https://github.com/wreiske/Rocket.Chat: (97 commits)
  LingoHub Update 🚀 (RocketChat#14643)
  [FIX] Role name spacing on Permissions page (RocketChat#14625)
  [FIX] Avatar images on old Livechat client (RocketChat#14590)
  [FIX] Inject code at the end of <head> tag (RocketChat#14623)
  [FIX] Mailer breaking if user doesn't have an email address (RocketChat#14614)
  Ci improvements (RocketChat#14600)
  [FIX] E2E messages not decrypting in message threads (RocketChat#14580)
  Fix: emoji render performance for alias (RocketChat#14593)
  [FIX] Send replyTo for livechat offline messages (RocketChat#14568)
  Federation i18n message changes (RocketChat#14595)
  [REGRESSION] Fix Slack bridge channel owner on channel creation (RocketChat#14565)
  Fix thumbs up emoji shortname (RocketChat#14581)
  Fix broken logo url in app.json (RocketChat#14572)
  Add digitalocean button to readme (RocketChat#14583)
  Fix: Add emoji shortnames to emoji's list (RocketChat#14576)
  [IMPROVE] Message rendering time (RocketChat#14252)
  [IMPROVE] Change user presence events to Meteor Streams (RocketChat#14488)
  Removed unnecessary DDP unblocks (RocketChat#13641)
  [FIX] Downloading files when running in sub directory (RocketChat#14485)
  [FIX] Broken layout when sidebar is open on IE/Edge (RocketChat#14567)
  ...
  • Loading branch information
wreiske committed May 27, 2019
2 parents 5a4c87c + b1e4e41 commit a120595
Show file tree
Hide file tree
Showing 1,505 changed files with 31,462 additions and 15,100 deletions.
6 changes: 2 additions & 4 deletions .circleci/config.yml
Expand Up @@ -69,6 +69,7 @@ jobs:
<<: *defaults
docker:
- image: circleci/node:8.11-stretch
- image: mongo:3.2

steps:
- checkout
Expand Down Expand Up @@ -117,9 +118,6 @@ jobs:
# rm -rf node_modules
# rm -f package-lock.json
meteor npm install
cd packages/rocketchat-livechat/.app
meteor npm install
cd -
- run:
name: Lint
Expand All @@ -129,7 +127,7 @@ jobs:
- run:
name: Unit Test
command: |
meteor npm run testunit
MONGO_URL=mongodb://localhost:27017 meteor npm run testunit
- restore_cache:
keys:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/snap.sh
Expand Up @@ -13,7 +13,7 @@ cd $PWD/.snapcraft
echo -e "Tag: $CIRCLE_TAG\r\nBranch: $CIRCLE_BRANCH\r\nBuild: $CIRCLE_BUILD_NUM\r\nCommit: $CIRCLE_SHA1" > buildinfo

# Clone launchpad repo for the channel down.
git clone -b $SNAP_CHANNEL git+ssh://rocket.chat.buildmaster@git.launchpad.net/rocket.chat launchpad
git clone -b $SNAP_CHANNEL --depth 1 git+ssh://rocket.chat.buildmaster@git.launchpad.net/rocket.chat launchpad

# Rarely will change, but just incase we copy it all
cp -r resources buildinfo snap launchpad/
Expand Down
1 change: 1 addition & 0 deletions .eslintignore
Expand Up @@ -22,3 +22,4 @@ public/livechat/
!.scripts
!packages/rocketchat-livechat/.app
public/pdf.worker.min.js
imports/client/
18 changes: 0 additions & 18 deletions .eslintrc
@@ -1,24 +1,6 @@
{
"extends": ["@rocket.chat/eslint-config"],
"parser": "babel-eslint",
"rules": {
"import/no-unresolved": [2, {
"commonjs": true,
"amd": true,
"ignore": [
"^meteor\/.+$"
]
}],
"import/named": 0,
"import/namespace": 0,
"import/default": 0,
"import/export": 2,
"import/no-cycle": 0,
"import/no-useless-path-segments": 2,
"import/no-duplicates": 2,
"import/no-named-as-default": 0,
"import/no-named-as-default-member": 0
},
"globals": {
"__meteor_bootstrap__" : false,
"__meteor_runtime_config__" : false,
Expand Down
1 change: 0 additions & 1 deletion .meteor/packages
Expand Up @@ -84,7 +84,6 @@ accounts-base
accounts-oauth
autoupdate
babel-compiler
emojione:emojione@2.2.6
google-oauth
htmljs
less
Expand Down
5 changes: 2 additions & 3 deletions .meteor/versions
Expand Up @@ -41,7 +41,6 @@ ecmascript-runtime-server@0.7.1
edgee:slingshot@0.7.1
ejson@1.1.0
email@1.2.3
emojione:emojione@2.2.6
es5-shim@4.8.0
facebook-oauth@1.5.0
fastclick@1.0.13
Expand Down Expand Up @@ -71,7 +70,7 @@ konecty:change-case@2.3.0
konecty:delayed-task@1.0.0
konecty:mongo-counter@0.0.5_3
konecty:multiple-instances-status@1.1.0
konecty:user-presence@2.3.0
konecty:user-presence@2.4.0
launch-screen@1.1.1
less@2.8.0
littledata:synced-cron@1.5.1
Expand Down Expand Up @@ -132,7 +131,7 @@ rocketchat:mongo-config@0.0.1
rocketchat:monitoring@2.30.2_3
rocketchat:oauth2-server@2.0.0
rocketchat:push@3.3.1
rocketchat:streamer@1.0.1
rocketchat:streamer@1.0.2
rocketchat:version@1.0.0
routepolicy@1.1.0
service-configuration@1.0.11
Expand Down
29 changes: 29 additions & 0 deletions .scripts/fix-i18n.js
@@ -0,0 +1,29 @@
/**
* This script will:
*
* - remove any duplicated i18n key on the same file;
* - re-order all keys based on source i18n file (en.i18n.json)
* - remove all keys not present in source i18n file
*/

const fs = require('fs');

const fg = require('fast-glob');

const fixFiles = (path, source, newlineAtEnd = false) => {
const sourceFile = JSON.parse(fs.readFileSync(`${ path }${ source }`, 'utf8'));
const sourceKeys = Object.keys(sourceFile);

fg([`${ path }/**/*.i18n.json`]).then((entries) => {
entries.forEach((file) => {
console.log(file);

const json = JSON.parse(fs.readFileSync(file, 'utf8'));

fs.writeFileSync(file, `${ JSON.stringify(json, sourceKeys, 2) }${ newlineAtEnd ? '\n' : '' }`);
});
});
};

fixFiles('./packages/rocketchat-i18n', '/i18n/en.i18n.json');
fixFiles('./packages/rocketchat-livechat/.app/i18n', '/en.i18n.json');
3 changes: 2 additions & 1 deletion .scripts/logs.js
@@ -1,5 +1,6 @@
const path = require('path');
const fs = require('fs');

const semver = require('semver');
const ProgressBar = require('progress');
const _ = require('underscore');
Expand All @@ -14,7 +15,7 @@ const historyDataFile = path.join(__dirname, '../.github/history.json');

let historyData = (() => {
try {
return require(historyDataFile);
return require(historyDataFile); // eslint-disable-line import/no-dynamic-require
} catch (error) {
return {};
}
Expand Down
7 changes: 4 additions & 3 deletions .scripts/md.js
@@ -1,8 +1,9 @@
const path = require('path');
const fs = require('fs');
const { execSync } = require('child_process');

const semver = require('semver');
const _ = require('underscore');
const { execSync } = require('child_process');

const historyDataFile = path.join(__dirname, '../.github/history.json');
const historyManualDataFile = path.join(__dirname, '../.github/history-manual.json');
Expand Down Expand Up @@ -50,15 +51,15 @@ const SummaryNameEmoticons = {

const historyData = (() => {
try {
return require(historyDataFile);
return require(historyDataFile); // eslint-disable-line import/no-dynamic-require
} catch (error) {
return {};
}
})();

const historyManualData = (() => {
try {
return require(historyManualDataFile);
return require(historyManualDataFile); // eslint-disable-line import/no-dynamic-require
} catch (error) {
return {};
}
Expand Down
2 changes: 2 additions & 0 deletions .scripts/npm-postinstall.js
Expand Up @@ -9,3 +9,5 @@ execSync('mkdir -p public/fonts/');
execSync('cp node_modules/katex/dist/fonts/* public/fonts/');

execSync('cp node_modules/pdfjs-dist/build/pdf.worker.min.js public/');

execSync('cd packages/rocketchat-livechat/.app && (meteor npm install || npm install) && cd -');
3 changes: 2 additions & 1 deletion .scripts/set-version.js
Expand Up @@ -2,6 +2,7 @@

const path = require('path');
const fs = require('fs');

const semver = require('semver');
const inquirer = require('inquirer');
// const execSync = require('child_process').execSync;
Expand All @@ -10,7 +11,7 @@ const git = require('simple-git/promise')(process.cwd());
let pkgJson = {};

try {
pkgJson = require(path.resolve(
pkgJson = require(path.resolve( // eslint-disable-line import/no-dynamic-require
process.cwd(),
'./package.json'
));
Expand Down
7 changes: 4 additions & 3 deletions .scripts/start.js
Expand Up @@ -5,6 +5,7 @@ const fs = require('fs');
const extend = require('util')._extend;
const { spawn } = require('child_process');
const net = require('net');

const processes = [];
let exitCode;

Expand Down Expand Up @@ -116,9 +117,9 @@ function startChimp() {
// params: ['2'],
options: {
env: Object.assign({}, process.env, {
NODE_PATH: `${ process.env.NODE_PATH +
path.delimiter + srcDir +
path.delimiter + srcDir }/node_modules`,
NODE_PATH: `${ process.env.NODE_PATH
+ path.delimiter + srcDir
+ path.delimiter + srcDir }/node_modules`,
}),
},
});
Expand Down
3 changes: 2 additions & 1 deletion .scripts/version.js
@@ -1,8 +1,9 @@
const path = require('path');

let pkgJson = {};

try {
pkgJson = require(path.resolve(
pkgJson = require(path.resolve( // eslint-disable-line import/no-dynamic-require
process.cwd(),
'./package.json'
));
Expand Down
13 changes: 10 additions & 3 deletions README.md
Expand Up @@ -19,6 +19,7 @@
* [Desktop Apps](#desktop-apps)
* [Deployment](#deployment)
* [Snaps](#instant-server-installation-with-snaps)
* [DigitalOcean](#digitalocean-droplet)
* [RocketChatLauncher](#rocketchatlauncher)
* [Layershift](#layershift)
* [Yunohost.org](#yunohostorg)
Expand Down Expand Up @@ -81,7 +82,7 @@ Join thousands of members worldwide 24/7 in our [community server](https://open.

[![Rocket.Chat](https://open.rocket.chat/api/v1/shield.svg?type=channel&name=Rocket.Chat&channel=dev)](https://open.rocket.chat/channel/dev) for developers needing help from the community to developing new features.

You can also join the conversation at [Twitter](https://twitter.com/RocketChat), [Facebook](https://www.facebook.com/RocketChatApp) or [Google Plus](https://plus.google.com/+RocketChatApp).
You can also join the conversation at [Twitter](https://twitter.com/RocketChat) and [Facebook](https://www.facebook.com/RocketChatApp).

# Desktop Apps
Download the Native Cross-Platform Desktop Application at [Rocket.Chat.Electron](https://github.com/RocketChat/Rocket.Chat.Electron/releases)
Expand Down Expand Up @@ -109,6 +110,12 @@ Our snap features a built-in reverse proxy that can request and maintain free Le

Find out more information about our snaps [here](https://rocket.chat/docs/installation/manual-installation/ubuntu/snaps/).

## DigitalOcean droplet

Deploy to a DigitalOcean droplet with our one-click install listing from the DigitalOcean Marketplace.

[![do-btn-blue](https://user-images.githubusercontent.com/51996/58146107-50512580-7c1a-11e9-8ec9-e032ba387c2a.png)](https://marketplace.digitalocean.com/apps/rocket-chat?action=deploy&refcode=1940fe28bd31)

## RocketChatLauncher

Focus on your team/community and not on servers or code - the Launcher provides RocketChat-as-a-Service on a monthly subscription model.
Expand Down Expand Up @@ -450,9 +457,9 @@ Thanks to our core team
[Sing Li](https://github.com/Sing-Li),
and to hundreds of awesome [contributors](https://github.com/RocketChat/Rocket.Chat/graphs/contributors).

![Emoji One](https://cloud.githubusercontent.com/assets/1986378/24772858/47290a70-1ae9-11e7-9a5a-2913d0002c94.png)
![JoyPixels](https://i.imgur.com/OrhYvLe.png)

Emoji provided free by [Emoji One](http://emojione.com)
Emoji provided graciously by [JoyPixels](https://www.joypixels.com/)

![BrowserStack](https://cloud.githubusercontent.com/assets/1986378/24772879/57d57b88-1ae9-11e7-98b4-4af824b47933.png)

Expand Down
2 changes: 1 addition & 1 deletion app.json
Expand Up @@ -2,7 +2,7 @@
"name": "Rocket.Chat",
"description": "Have your own open-source Slack-like online chat platform.",
"repository": "https://github.com/RocketChat/Rocket.Chat",
"logo": "https://raw.githubusercontent.com/RocketChat/Rocket.Chat/master/public/images/logo/512x512.png?v=3",
"logo": "https://raw.githubusercontent.com/RocketChat/Rocket.Chat/master/public/images/logo/1024x1024.png",
"keywords": ["meteor", "social", "community", "chat"],
"website": "https://rocket.chat",
"env": {
Expand Down
3 changes: 2 additions & 1 deletion app/2fa/client/TOTPPassword.js
@@ -1,8 +1,9 @@
import { Meteor } from 'meteor/meteor';
import { Accounts } from 'meteor/accounts-base';
import toastr from 'toastr';

import { modal } from '../../ui-utils';
import { t } from '../../utils';
import toastr from 'toastr';

function reportError(error, callback) {
if (callback) {
Expand Down
5 changes: 3 additions & 2 deletions app/2fa/client/accountSecurity.js
@@ -1,11 +1,12 @@
import { Meteor } from 'meteor/meteor';
import { ReactiveVar } from 'meteor/reactive-var';
import { Template } from 'meteor/templating';
import toastr from 'toastr';
import qrcode from 'yaqrcode';

import { modal } from '../../ui-utils';
import { settings } from '../../settings';
import { t } from '../../utils';
import toastr from 'toastr';
import qrcode from 'yaqrcode';

window.qrcode = qrcode;

Expand Down
3 changes: 2 additions & 1 deletion app/2fa/server/lib/totp.js
@@ -1,8 +1,9 @@
import { SHA256 } from 'meteor/sha';
import { Random } from 'meteor/random';
import speakeasy from 'speakeasy';

import { Users } from '../../../models';
import { settings } from '../../../settings';
import speakeasy from 'speakeasy';

export const TOTP = {
generateSecret() {
Expand Down
3 changes: 2 additions & 1 deletion app/2fa/server/loginHandler.js
@@ -1,8 +1,9 @@
import { Meteor } from 'meteor/meteor';
import { Accounts } from 'meteor/accounts-base';

import { TOTP } from './lib/totp';
import { settings } from '../../settings';
import { callbacks } from '../../callbacks';
import { TOTP } from './lib/totp';

Accounts.registerLoginHandler('totp', function(options) {
if (!options.totp || !options.totp.code) {
Expand Down
1 change: 1 addition & 0 deletions app/2fa/server/methods/disable.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { Users } from '../../../models';
import { TOTP } from '../lib/totp';

Expand Down
1 change: 1 addition & 0 deletions app/2fa/server/methods/enable.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { Users } from '../../../models';
import { TOTP } from '../lib/totp';

Expand Down
1 change: 1 addition & 0 deletions app/2fa/server/methods/regenerateCodes.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { Users } from '../../../models';
import { TOTP } from '../lib/totp';

Expand Down
1 change: 1 addition & 0 deletions app/2fa/server/methods/validateTempToken.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { Users } from '../../../models';
import { TOTP } from '../lib/totp';

Expand Down
2 changes: 0 additions & 2 deletions app/2fa/server/startup/settings.js
Expand Up @@ -17,5 +17,3 @@ settings.addGroup('Accounts', function() {
});
});
});


1 change: 1 addition & 0 deletions app/action-links/both/lib/actionLinks.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { Messages, Subscriptions } from '../../../models';

// Action Links namespace creation.
Expand Down
2 changes: 1 addition & 1 deletion app/action-links/client/init.js
@@ -1,12 +1,12 @@
import { Blaze } from 'meteor/blaze';
import { Template } from 'meteor/templating';

import { handleError } from '../../utils';
import { fireGlobalEvent, Layout } from '../../ui-utils';
import { messageArgs } from '../../ui-utils/client/lib/messageArgs';
import { actionLinks } from '../both/lib/actionLinks';



Template.room.events({
'click .action-link'(event, instance) {
event.preventDefault();
Expand Down
1 change: 1 addition & 0 deletions app/action-links/client/lib/actionLinks.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { handleError } from '../../../utils';
import { actionLinks } from '../../both/lib/actionLinks';
// Action Links Handler. This method will be called off the client.
Expand Down
1 change: 1 addition & 0 deletions app/action-links/server/actionLinkHandler.js
@@ -1,4 +1,5 @@
import { Meteor } from 'meteor/meteor';

import { actionLinks } from '../both/lib/actionLinks';
// Action Links Handler. This method will be called off the client.

Expand Down
1 change: 1 addition & 0 deletions app/analytics/client/loadScript.js
@@ -1,6 +1,7 @@
import { Meteor } from 'meteor/meteor';
import { Tracker } from 'meteor/tracker';
import { Template } from 'meteor/templating';

import { settings } from '../../settings';

Template.body.onRendered(() => {
Expand Down

0 comments on commit a120595

Please sign in to comment.