Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:TryQuiet/quiet into chore/bump-p…
Browse files Browse the repository at this point in the history
…ackages
  • Loading branch information
vinkabuki committed Oct 8, 2023
2 parents 244bfe6 + 520fc30 commit 1593dc9
Show file tree
Hide file tree
Showing 58 changed files with 1,274 additions and 105 deletions.
2 changes: 1 addition & 1 deletion .github/actions/before-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,5 @@ runs:
shell: bash

- name: "Build the project"
run: lerna run build:prod --scope quiet
run: lerna run build:prod --scope @quiet/desktop
shell: bash
9 changes: 8 additions & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,11 @@
### Pull Request Checklist

- [ ] I have linked this PR to related GitHub issue.
- [ ] I have updated the CHANGELOG.md file with relevant changes (the file is located at the root of monorepo).
- [ ] I have updated the CHANGELOG.md file with relevant changes (the file is located at the root of monorepo).

### (Optional) Mobile checklist

Please ensure you completed the following checks if you did any changes to the mobile package:

- [ ] I have run e2e tests for mobile
- [ ] I have updated base screenshots for visual regression tests
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Visual regressions
name: Desktop visual regressions

on:
pull_request:
Expand All @@ -24,7 +24,7 @@ jobs:
- name: Setup environment
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Publish to Chromatic"
uses: chromaui/action@v1
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,13 @@ jobs:
uses: ./.github/actions/setup-env
if: ${{ runner.os != 'Windows' }}
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,@quiet/mobile,e2e-tests,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,@quiet/mobile,e2e-tests,backend-bundle"


- name: "Setup environment for Windows"
uses: ./.github/actions/setup-env
if: ${{ runner.os == 'Windows' }}
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,e2e-tests,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,e2e-tests,backend-bundle"

- name: "Lint"
if: ${{ runner.os != 'Windows' }}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build release
name: Desktop release build

on:
release:
Expand All @@ -17,7 +17,7 @@ jobs:
# needs: run-e2e-tests-linux
runs-on: ubuntu-22.04
if: |
startsWith(github.ref, 'refs/tags/quiet')
startsWith(github.ref, 'refs/tags/@quiet/desktop')
env:
TEST_MODE: ${{ github.event.action == 'prereleased' }}
Expand All @@ -30,7 +30,7 @@ jobs:
- name: Setup environment
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: Install libfuse
run: sudo apt install libfuse2
Expand All @@ -52,7 +52,7 @@ jobs:
run: cd packages/desktop && USE_HARD_LINKS=false node_modules/.bin/electron-builder -p always --linux ${{ env.ELECTRON_BUILDER_PROPS }}

- name: "Calculate new checksum for electron updater"
run: lerna run postBuild --scope quiet
run: lerna run postBuild --scope @quiet/desktop

- name: "Push electron-updater new checksum to S3"
uses: vinkabuki/upload-s3-action@master
Expand Down Expand Up @@ -89,7 +89,7 @@ jobs:
# needs: run-e2e-tests-mac
runs-on: macos-latest
if: |
startsWith(github.ref, 'refs/tags/quiet')
startsWith(github.ref, 'refs/tags/@quiet/desktop')
env:
TEST_MODE: ${{ github.event.action == 'prereleased' }}
Expand All @@ -111,7 +111,7 @@ jobs:
- name: Setup environment
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: Before build
uses: ./.github/actions/before-build
Expand Down Expand Up @@ -162,7 +162,7 @@ jobs:
# needs: run-e2e-tests-win
runs-on: windows-2019
if: |
startsWith(github.ref, 'refs/tags/quiet')
startsWith(github.ref, 'refs/tags/@quiet/desktop')
env:
TEST_MODE: ${{ github.event.action == 'prereleased' }}
Expand All @@ -189,7 +189,7 @@ jobs:
- name: Setup environment
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle,e2e-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle,e2e-tests"

- name: Before build
uses: ./.github/actions/before-build
Expand Down
31 changes: 31 additions & 0 deletions .github/workflows/desktop-rtl-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Desktop - state-manager bracket tests (RTL)

on:
pull_request:
paths:
- packages/desktop/**
- packages/state-manager/**

jobs:
desktop-tests:
timeout-minutes: 25
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-20.04, macos-latest]

steps:
- name: "Print OS"
run: echo ${{ matrix.os }}

- uses: actions/checkout@v3

- name: "Setup environment"
uses: ./.github/actions/setup-env
with:
cachePrefix: "desktop-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Desktop - state-manager bracket tests"
run: lerna run rtl-test --scope @quiet/desktop --stream
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Scroll regression tests
name: Desktop scroll regression tests

on:
pull_request:
Expand All @@ -23,7 +23,7 @@ jobs:
- name: Setup environment
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Install libs"
run: sudo apt-get update && sudo apt-get install -y libgtk2.0-0 libgtk-3-0 libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 libxtst6 xauth xvfb
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,7 @@ jobs:
uses: ./.github/actions/setup-env
with:
cachePrefix: "desktop-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Unit tests"
run: lerna run test --scope quiet --stream

- name: "desktop-state-manager bracket tests"
run: lerna run rtl-test --scope quiet --stream
run: lerna run test --scope @quiet/desktop --stream
10 changes: 9 additions & 1 deletion .github/workflows/e2e-crossplatform.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
name: E2E cross platform

on: [pull_request]
on:
pull_request:
paths:
- packages/desktop/**
- packages/backend/**
- packages/state-manager/**
- packages/identity/**
- packages/common/**

jobs:
mac:
uses: ./.github/workflows/e2e-mac.yml
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/e2e-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
uses: ./.github/actions/setup-env
with:
cachePrefix: "e2e-crossplatform-linux"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle,e2e-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle,e2e-tests"

- name: Run X11
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/e2e-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
uses: ./.github/actions/setup-env
with:
cachePrefix: "e2e-crossplatform-mac"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle,e2e-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle,e2e-tests"

- name: Before build
uses: ./.github/actions/before-build
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/e2e-win.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
uses: ./.github/actions/setup-env
with:
cachePrefix: "e2e-crossplatform-windows"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle,e2e-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle,e2e-tests"

- name: "Fetch jsign"
shell: bash
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Deploy Android to Google Play (internal testing)
name: Deploy Android to Google Play

on:
release:
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,7 @@ jobs:
- name: "Setup environment"
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,quiet,backend-bundle"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Unit tests"
run: lerna run test --scope @quiet/state-manager --stream

- name: "desktop-state-manager bracket tests"
run: lerna run rtl-test --scope quiet --stream
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@

[unreleased]

* Add possible impersonation attack UI for desktop and mobile

* Fix truncated long messages in channelInput component

* Unblock mobile e2e tests
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"version": "independent",
"command": {
"version": {
"allowBranch": ["master", "develop", "workflows/require-e2e-before-build-release"],
"allowBranch": ["master", "develop"],
"conventionalCommits": true,
"createRelease": "github"
},
Expand Down
5 changes: 3 additions & 2 deletions packages/backend-bundle/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@
"scripts": {},
"keywords": [],
"author": "",
"license": "ISC"
}
"license": "ISC",
"private": true
}
1 change: 1 addition & 0 deletions packages/backend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"exports": "lib/index.js",
"author": "",
"license": "MIT",
"private": true,
"scripts": {
"build": "tsc -p tsconfig.build.json",
"webpack": "run-script-os",
Expand Down
1 change: 1 addition & 0 deletions packages/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"files": [
"lib/**/*"
],
"private": true,
"scripts": {
"build": "tsc -p tsconfig.build.json",
"prepare": "npm run build",
Expand Down
4 changes: 2 additions & 2 deletions packages/desktop/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/desktop/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "quiet",
"name": "@quiet/desktop",
"productName": "Quiet",
"author": {
"name": "Zbay LLC",
Expand Down
2 changes: 1 addition & 1 deletion packages/desktop/scripts/setEnvs.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ exports.default = async function (context) {
childProcess.execSync(`${context.artifactPaths[0]} --appimage-extract`)
childProcess.execSync(`mv ./squashfs-root ${context.outDir}/squashfs-root`)
const data = fs.readFileSync(`${context.outDir}/squashfs-root/AppRun`, 'utf8').split('\n')
const index = data.findIndex(text => text === 'BIN="$APPDIR/quiet"')
const index = data.findIndex(text => text === 'BIN="$APPDIR/@quietdesktop"')
if (index !== -1) {
data[index - 1] = 'export LD_PRELOAD="${APPDIR}/usr/lib/libssl.so"'
fs.writeFileSync(`${context.outDir}/squashfs-root/AppRun`, data.join('\n'), 'utf8')
Expand Down
3 changes: 2 additions & 1 deletion packages/desktop/src/renderer/Root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import ChannelCreationModal from './components/ChannelCreationModal/ChannelCreat
import { SaveStateComponent } from './components/SaveState/SaveStateComponent'
import UnregisteredModalContainer from './components/widgets/userLabel/unregistered/UnregisteredModal.container'
import DuplicateModalContainer from './components/widgets/userLabel/duplicate/DuplicateModal.container'
// Trigger lerna
import PossibleImpersonationAttackModalContainer from './components/widgets/possibleImpersonationAttackModal/PossibleImpersonationAttackModal.container'

export const persistor = persistStore(store)
export default () => {
Expand All @@ -48,6 +48,7 @@ export default () => {
<DuplicateModalContainer />
<SearchModal />
<ErrorModal />
<PossibleImpersonationAttackModalContainer />
<LoadingPanel />
<ChannelCreationModal />
<CreateChannel />
Expand Down
Loading

0 comments on commit 1593dc9

Please sign in to comment.