Skip to content

Commit 691e91f

Browse files
committed
[DDW-1065] Added new script to start Daedalus in dev mode in Windows and added the needed documentation
1 parent 35531f8 commit 691e91f

File tree

2 files changed

+43
-28
lines changed

2 files changed

+43
-28
lines changed

README.md

Lines changed: 42 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,15 @@
88

99
Daedalus - Cryptocurrency Wallet
1010

11-
## Installation
11+
## Setup development environment
1212

13-
### Yarn
13+
### Linux/macOS
14+
15+
#### Yarn
1416

1517
[Yarn](https://yarnpkg.com/lang/en/docs/install) is required to install `npm` dependencies to build Daedalus.
1618

17-
### Nix
19+
#### Nix
1820

1921
[Nix](https://nixos.org/nix/) is needed to run Daedalus in `nix-shell`.
2022

@@ -57,22 +59,19 @@ If you get SSL error when running `nix-shell` (SSL peer certificate or SSH remot
5759
```
5860
2. Download certificate from https://docs.certifytheweb.com/docs/kb/kb-202109-letsencrypt/ and import to your keychain.
5961

60-
## Development
61-
62-
### Running Daedalus with Cardano Node
62+
#### Running Daedalus with Cardano Node
6363

64-
#### Selfnode
64+
##### Selfnode
6565

6666
1. Run `yarn nix:selfnode` from `daedalus`.
6767
2. Run `yarn dev` from the subsequent `nix-shell` (use `KEEP_LOCAL_CLUSTER_RUNNING` environment variable to keep the local cluster running after Daedalus exits: `KEEP_LOCAL_CLUSTER_RUNNING=true yarn dev`)
68-
1. Alternatively: run `yarn nix:selfnode yarn dev` to achieve the same thing in a single command. Note: after `yarn dev` exits, you will still remain in the `nix-shell`.
6968
3. Once Daedalus has started and has gotten past the loading screen run the following commands from a new terminal window if you wish to import funded wallets:
70-
- Byron wallets: `yarn byron:wallet:importer`
71-
- Shelley wallets: `yarn shelley:wallet:importer`
72-
- Mary wallets: `yarn mary:wallet:importer` (all of which contain native tokens which are visible once selfnode enters Mary era)
73-
- Yoroi Byron wallets: `yarn yoroi:wallet:importer`
74-
- _ITN Byron wallets:_ `yarn itn:byron:wallet:importer` **[Deprecated]**
75-
- _ITN Shelley wallets:_ `yarn itn:shelley:wallet:importer` **[Deprecated]**
69+
- Byron wallets: `yarn byron:wallet:importer`
70+
- Shelley wallets: `yarn shelley:wallet:importer`
71+
- Mary wallets: `yarn mary:wallet:importer` (all of which contain native tokens which are visible once selfnode enters Mary era)
72+
- Yoroi Byron wallets: `yarn yoroi:wallet:importer`
73+
- _ITN Byron wallets:_ `yarn itn:byron:wallet:importer` **[Deprecated]**
74+
- _ITN Shelley wallets:_ `yarn itn:shelley:wallet:importer` **[Deprecated]**
7675

7776
These scripts import 3 wallets by default. You can import up to 10 wallets by supplying `WALLET_COUNT` environment variable (e.g. `WALLET_COUNT=10 yarn mary:wallet:importer`).
7877

@@ -91,43 +90,37 @@ If you get SSL error when running `nix-shell` (SSL peer certificate or SSH remot
9190
| desiredPoolNumber | 3
9291
| minimumUtxoValue | 1 ADA
9392

94-
#### Mainnet
93+
##### Mainnet
9594

9695
1. Run `yarn nix:mainnet` from `daedalus`.
9796
2. Run `yarn dev` from the subsequent `nix-shell`
98-
3. Or in one command: `yarn nix:mainnet yarn dev`
9997

100-
#### Flight
98+
##### Flight
10199

102100
1. Run `yarn nix:flight` from `daedalus`.
103101
2. Run `yarn dev` from the subsequent `nix-shell`
104-
3. Or in one command: `yarn nix:flight yarn dev`
105102

106-
#### Testnet
103+
##### Testnet
107104

108105
1. Run `yarn nix:testnet` from `daedalus`.
109106
2. Run `yarn dev` from the subsequent `nix-shell`
110-
3. Or in one command: `yarn nix:testnet yarn dev`
111107

112-
#### Staging
108+
##### Staging
113109

114110
1. Run `yarn nix:staging` from `daedalus`.
115111
2. Run `yarn dev` from the subsequent `nix-shell`
116-
3. Or in one command: `yarn nix:staging yarn dev`
117112

118-
#### Shelley QA
113+
##### Shelley QA
119114

120115
1. Run `yarn nix:shelley_qa` from `daedalus`.
121116
2. Run `yarn dev` from the subsequent `nix-shell`
122-
3. Or in one command: `yarn nix:shelley_qa yarn dev`
123117

124-
#### Alonzo Purple
118+
##### Alonzo Purple
125119

126120
1. Run `yarn nix:alonzo_purple` from `daedalus`.
127121
2. Run `yarn dev` from the subsequent `nix-shell`
128-
3. Or in one command: `yarn nix:alonzo_purple yarn dev`
129122

130-
#### Native token metadata server
123+
##### Native token metadata server
131124

132125
Daedalus, by default, uses the following metadata server for all networks except for the mainnet: `https://metadata.cardano-testnet.iohkdev.io/`.
133126

@@ -158,7 +151,28 @@ http://localhost:65432/metadata/query
158151
```
159152
... and expect a "200 OK" response.
160153

161-
### Updating upstream dependencies (cardano-wallet, cardano-node, and iohk-nix)
154+
### Windows
155+
156+
This option is only for troubleshooting windows specific issues with hardware wallets. It is not recommended to use Windows as a developer environment.
157+
Most of the commands need `nix` and will run only on Linux or macOS.
158+
159+
#### Requisites
160+
- Windows 10/11
161+
- Daedalus testnet installation (similar version used in branch) in `C:\Program Files\Daedalus Testnet`
162+
- NodeJS 16
163+
- Python2 *
164+
- `yarn global add windows-build-tools` * (if this does not work extract daedalus\nix\windows-usb-libs.zip under daedalus\build folder)
165+
- Microsoft Build Tools 2015 *
166+
- Microsoft Visual Studio 2017 (Include Desktop development with C++) *
167+
- `yarn config set msvsversion 2015 --global`
168+
169+
*needed for compiling [email protected] on Windows
170+
171+
#### Steps
172+
- `yarn install`
173+
- `yarn dev:windows`
174+
175+
#### Updating upstream dependencies (cardano-wallet, cardano-node, and iohk-nix)
162176

163177
`Niv` is used to manage the version of upstream dependencies. The versions of these dependencies can be seen in `nix/sources.json`.
164178

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
"start": "gulp start",
1212
"start:dev": "NODE_ENV=development gulp start",
1313
"dev": "IS_WATCH_MODE=true gulp dev",
14+
"dev:windows": "cross-env DAEDALUS_INSTALL_DIRECTORY=\"C:\\Program Files\\Daedalus Testnet\" LAUNCHER_CONFIG=\"C:\\Program Files\\Daedalus Testnet\\launcher-config.yaml\" gulp dev",
1415
"test": "NODE_ENV=test yarn build && yarn test:unit && yarn test:e2e:fail-fast",
1516
"test:jest": "NODE_OPTIONS=--experimental-vm-modules jest",
1617
"test:generate:report": "ts-node tests/reporter.ts",

0 commit comments

Comments
 (0)