Skip to content
This repository has been archived by the owner on Jun 16, 2022. It is now read-only.

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
gre committed Jul 5, 2021
2 parents 1446fb8 + 2a44c39 commit 7c3664f
Show file tree
Hide file tree
Showing 411 changed files with 15,900 additions and 12,170 deletions.
7 changes: 5 additions & 2 deletions .github/actions/prepare-comment-body/action.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: prepare-comment-body
name: prepare-comment-body
description: gets a list of images and return a formatted markdown body for comment
author: valpinkman
outputs:
Expand Down Expand Up @@ -43,10 +43,13 @@ inputs:
lintoutput:
description: lintoutput
required: true
jestoutput:
description: jestoutput
required: true
runs:
using: node12
main: index.js

branding:
icon: align-center
color: white
color: white
17 changes: 15 additions & 2 deletions .github/actions/prepare-comment-body/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,13 @@ const main = async () => {
}
const testoutput = core.getInput("testoutput");
const lintoutput = core.getInput("lintoutput");
const jestoutput = core.getInput("jestoutput");
const fullrepo = core.getInput("fullrepo").split("/");
const imgArr = JSON.parse(images);

let str = "";
if (imgArr.length) {
imgArr.map(image => {
imgArr.forEach(image => {
str += image.name + "\n\n";
str += "![](" + image.link + ")\n\n";
});
Expand All @@ -30,6 +31,7 @@ const main = async () => {

const lintFailed = (lintoutput || "").indexOf("exit code 255") >= 0;
const testsFailed = (testoutput || "").indexOf("FAIL") >= 0;
const jestFailed = (jestoutput || "").indexOf("FAIL") >= 0;
const imgDiffFailed = !!imgArr.length;

str = `
Expand All @@ -44,6 +46,15 @@ ${lintoutput}
</p>
</details>
<details>
<summary><b>Tests outputs ${jestFailed ? "❌" : " ✅"}</b></summary>
<p>
${jestoutput}
</p>
</details>
<details>
<summary><b>Tests outputs ${testsFailed ? "❌" : " ✅"}</b></summary>
<p>
Expand All @@ -63,7 +74,7 @@ ${str}
</details>
`;

if (!lintFailed && !testsFailed && !imgDiffFailed && imgChanged.length) {
if (imgChanged.length) {
imgChanged = imgChanged.map(
img => `
${img}
Expand All @@ -88,6 +99,7 @@ ${diffStr}

const strSlack = `
Lint outputs ${lintFailed ? "❌" : " ✅"}
Jest outputs ${jestFailed ? "❌" : " ✅"}
Tests outputs ${testsFailed ? "❌" : " ✅"}
Diff output ${imgDiffFailed ? "❌" : " ✅"}
Expand All @@ -106,6 +118,7 @@ https://github.com/LedgerHQ/ledger-live-desktop/commits/develop

const strSlackAuthor = `
Lint outputs ${lintFailed ? "❌" : " ✅"}
Jest outputs ${jestFailed ? "❌" : " ✅"}
Tests outputs ${testsFailed ? "❌" : " ✅"}
Diff output ${imgDiffFailed ? "❌" : " ✅"}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/build-linux-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ on:
workflow_dispatch:
inputs:
tag:
description: 'Tag?'
description: "Tag?"
required: true

jobs:
Expand All @@ -19,7 +19,7 @@ jobs:
ref: ${{github.event.inputs.tag}}
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- name: install linux dependencies
run: sudo apt-get update && sudo apt-get install libudev-dev libusb-1.0-0-dev
- name: get yarn cache
Expand All @@ -46,4 +46,4 @@ jobs:
uses: actions/upload-artifact@v2
with:
name: latest-linux.yml
path: dist/latest-linux.yml
path: dist/latest-linux.yml
6 changes: 3 additions & 3 deletions .github/workflows/build-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
repository: ${{github.event.pull_request.head.repo.full_name}}
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- name: install dependencies
run: yarn --ignore-scripts --frozen-lockfile
- name: set beta name
Expand All @@ -41,7 +41,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- name: install linux dependencies
run: sudo apt-get update && sudo apt-get install libudev-dev libusb-1.0-0-dev
- name: get yarn cache
Expand Down Expand Up @@ -76,7 +76,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- uses: actions/setup-python@v1
with:
python-version: "2.7.x"
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/build-windows-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
ref: ${{github.event.inputs.tag}}
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- uses: actions/setup-python@v1
with:
python-version: "2.7.x"
Expand All @@ -43,4 +43,3 @@ jobs:
with:
name: win-unpacked
path: dist/win-unpacked

8 changes: 4 additions & 4 deletions .github/workflows/bundle-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- name: set git user
run: |
git config user.email "team-live@ledger.fr"
Expand Down Expand Up @@ -87,7 +87,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- name: set git user
run: |
git config user.email "team-live@ledger.fr"
Expand Down Expand Up @@ -145,7 +145,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-node@main
with:
node-version: 12.x
node-version: 14.x
- uses: actions/setup-python@v1
with:
python-version: "2.7.x"
Expand Down Expand Up @@ -182,4 +182,4 @@ jobs:
uses: actions/upload-artifact@v1
with:
name: ${{ steps.postversion1.outputs.content }}${{ steps.postversion2.outputs.content }}-win.exe
path: dist/${{ steps.version.outputs.name }}-${{ steps.version.outputs.version }}-win.exe
path: dist/${{ steps.version.outputs.name }}-${{ steps.version.outputs.version }}-win.exe
20 changes: 15 additions & 5 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ jobs:
- name: Cancel Previous Runs
run: curl -i -L -X GET 'http://github-actions-live-vercel.vercel.app/api/cancel-previous-run?runId=${{ github.run_id }}&owner=LedgerHQ&repo=ledger-live-desktop&branch=${{ github.event.pull_request.head.ref }}&headSha=${{ github.event.pull_request.head.sha }}'
- name: install linux dependencies
run: sudo apt-get update && sudo apt-get install -y libudev-dev libusb-1.0-0-dev
run: |
sudo apt-get update && sudo apt-get install -y libudev-dev libusb-1.0-0-dev
- name: Setup xvfb
run: |
sudo apt-get -qqy install xvfb libnss3-dev libgconf-2-4 fuse libgtk2.0-0 libgtk-3-0 libasound2 libudev-dev libusb-1.0-0 libusb-1.0-0-dev lib32z1 rpm fakeroot dpkg libdbus-1-dev libx11-dev libavahi-compat-libdnssd-dev g++ gcc-multilib g++-multilib libgtk-3-dev libxtst6 libxss1 libnss3
sudo apt-get -qqy install xvfb libnss3-dev libgconf-2-4 fuse libgtk2.0-0 libgtk-3-0 libasound2 libudev-dev libusb-1.0-0 libusb-1.0-0-dev lib32z1 rpm fakeroot dpkg libdbus-1-dev libx11-dev libavahi-compat-libdnssd-dev g++ gcc gcc-multilib g++-multilib libgtk-3-dev libxtst6 libxss1 libnss3
- uses: actions/checkout@v2
if: always() && job.status != 'cancelled'
with:
Expand All @@ -28,7 +29,7 @@ jobs:
- uses: actions/setup-node@main
if: always() && job.status != 'cancelled'
with:
node-version: 12.x
node-version: 14.x
- name: get yarn cache
if: always() && job.status != 'cancelled'
id: yarn-cache
Expand Down Expand Up @@ -57,6 +58,14 @@ jobs:
env:
INSTRUMENT_BUILD: true
run: yarn build
- name: Tests
run: yarn test 2>jest.txt
- name: Read jest output
id: jest
if: always() && job.status != 'cancelled'
uses: juliangruber/read-file-action@e0a316da496006ffd19142f0fd594a1783f3b512
with:
path: ./jest.txt
- name: start electron webdriver
if: always() && job.status != 'cancelled'
env:
Expand All @@ -76,9 +85,9 @@ jobs:
uses: juliangruber/read-file-action@e0a316da496006ffd19142f0fd594a1783f3b512
with:
path: ./output.txt
- name: run coverage generation
- name: run coverage generation
if: always() && github.event_name == 'push' && job.status != 'cancelled'
run: yarn spectron-coverage
run: yarn spectron-coverage
env:
CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}}
- name: upload diffs to imgur
Expand Down Expand Up @@ -118,6 +127,7 @@ jobs:
runId: ${{ github.run_id }}
testoutput: ${{ steps.spectron.outputs.content }}
lintoutput: ${{ steps.lint.outputs.content }}
jestoutput: ${{ steps.jest.outputs.content }}
author: ${{github.event.sender.login}}
pullId: ${{github.event.number}}
imgChanged: ${{steps.imgChanged.outputs.content}}
Expand Down
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v14.17.1
74 changes: 51 additions & 23 deletions DEEPLINK.md
Original file line number Diff line number Diff line change
@@ -1,30 +1,58 @@
# Deep Linking Ledger Live

## Protocols

Currently, Ledger Live will open with this scheme:

- ledgerlive://

## Routing
_Every route is preceded by the protocol_

- **portfolio** => `/`
- **accounts** => `/accounts`
- **account?currency=xxx** => `/account` of the selected currency with highest funds
- *currency* => the ticker of the currency **required**
- **send?currency=xxx&arg2=xxx** => open `send` modal
- *currency* => the ticker of the currency **required**
- *amount* => the amount to send
- *recipient* => the address to send to
- **receive?currency=xxx** => open the `receive` modal
- - *currency* => the ticker of the currency **required**
- **delegate?currency=xxx** => open the `delagation` flow
- *currency* => the ticker of the currency **required**

- *validator.s* => validator.s to delegate to _(not implemented yet)_


**### Examples**

`ledgerlive://portfolio` => to access the dashboard
`ledgerlive://account?currency=mana` => to access the first decentraland mana account
`ledgerlive://send?currency=btc&amount=0.001&recipient=adress` => open the send modal with profiled inputs

_Every route is preceded by the protocol \*\*\_ledgerlive://_\*\*\_

- **_portfolio_** 🠒 Portfolio page (default landing)

`ledgerlive://` _or_ `ledgerlive://portfolio`

- **_accounts_** 🠒 Accounts Page

`ledgerlive://accounts` will redirect to accounts page

- **_account?currency_** 🠒 Account Page

`ledgerlive://account?currency=btc` will open first bitcoin account found

- _currency_ => the ticker or name of the currency **required**

- **_send?currency?amount?recipient_** 🠒 Send Flow

`ledgerlive://send` will redirect to send page

`ledgerlive://send?currency=ethereum` will redirect to send page with the first ethereum account found

`ledgerlive://send?currency=ethereum&recipient=0xex...xxx&amount=3` will redirect to send page with the first ethereum account found and recipient and amount prefilled

- *currency* => the ticker of the currency **required**
- *amount* => the amount to send
- *recipient* => the address to send to

- **_receive?currency_** 🠒 Receive Flow

`ledgerlive://receive?currency=ethereum` will redirect to receive page with the first ethereum account found

- *currency* => the ticker or name of the currency **required**

- **delegate?currency\_** 🠒 Send Flow

`ledgerlive://delegate?currency=tron` will redirect to delegation page with the first tron account found

- *currency* => the ticker or name of the currency **required**
- *validators* => TBD - no ready yet

* **\_buy** 🠒 Buy Crypto Flow

`ledgerlive://buy` will redirect to buy page

* **_swap_** 🠒 Swap Crypto Flow

`ledgerlive://swap` will redirect to swap page
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
- Related: [ledger-live-mobile](https://github.com/ledgerhq/ledger-live-mobile)
- Backed by: [ledger-live-common](https://github.com/ledgerhq/ledger-live-common)

> Ledger Live is a new generation wallet desktop application providing a unique interface to maintain multiple cryptocurrencies for your Ledger Nano S / Blue. Manage your device, create accounts, receive and send cryptoassets, [...and many more](https://www.ledger.fr/2018/07/09/ledger-launches-ledger-live-the-all-in-one-companion-app-to-your-ledger-device/).
> Ledger Live is a new generation wallet desktop application providing a unique interface to maintain multiple cryptocurrencies for your Ledger Nano S / Blue. Manage your device, create accounts, receive and send cryptoassets, [...and many more](https://www.ledger.com/ledger-launches-ledger-live-the-all-in-one-companion-app-to-your-ledger-device).
<a href="https://github.com/LedgerHQ/ledger-live-desktop/releases">
<p align="center">
Expand Down Expand Up @@ -42,7 +42,7 @@ Ledger Live releases are signed. The automatic update mechanism makes use of the

### Requirements

- [NodeJS](https://nodejs.org) LTS/erbium (Node 12.x)
- [NodeJS](https://nodejs.org) `lts/fermium` (Node 14.x)
- [Yarn 1.x](https://classic.yarnpkg.com/) (Classic)
- [Python](https://www.python.org/) 2.7 or 3.5+
- A C/C++ toolchain (see [node-gyp documentation](https://github.com/nodejs/node-gyp#on-unix))
Expand Down
Loading

0 comments on commit 7c3664f

Please sign in to comment.