Bläddra i källkod

dnet: add venv instructions to README and do minor edit

lunar-mining 2 år sedan
förälder
incheckning
5cc1100b6e
1 ändrade filer med 34 tillägg och 8 borttagningar
  1. 34 8
      bin/dnet/README.md

+ 34 - 8
bin/dnet/README.md

@@ -13,21 +13,47 @@ engine that makes everything run.
 
 ## Run
 
+### Using a venv
+
+Depending on your setup you may need to install a virtual environment
+for Python. Do so as follows:
+
+```shell
+% python -m venv env
+```
+
+Then install the requirements:
+
+```shell
+% env/bin/pip install -r requirements.txt
+```
+
+Run dnet:
+
 ```shell
-% git clone https://github.com/darkrenaissance/darkfi 
-% cd darkfi/bin/dnet
+% env/bin/python main.py
+```
+
+### Without a venv
+
+If you don't require a venv, install the requirements and run dnet as follows:
+
+```shell
+% pip install -r requirements.txt
 % python main.py
 ```
 
+## Usage
+
 Navigate up and down using the arrow keys. Type `q` to quit.
 
-## Usage
+## Config
 
-The `dnet` config file can be found in `bin/dnet/config.toml`. You must
-enter the RPC ports of the nodes you want to connect to and title them as
-you see fit. You must also specify whether it is a `NORMAL` or a `LILITH`
-node. The default config file uses localhost, but you can replace this
-with hostnames or external IP addresses.
+The `dnet` config file can be found in `bin/dnet/config.toml`. Enter the
+RPC ports of the nodes you want to connect to and title them as you see
+fit. The default config file uses localhost, but you can replace this
+with hostnames or external IP addresses. You must also specify whether
+it is a `NORMAL` or a `LILITH` node.
 
 ## Logging