forked from autonomys/subspace-docs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
1,128 additions
and
237 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
protocol_versioned_docs/version-gemini-2a-2022-oct-06/development.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
--- | ||
title: Core Protocol Development | ||
sidebar_position: 99 | ||
description: A basic guide on how to develop on the core subspace protocol utilizing substrate | ||
displayed_sidebar: masterSidebar | ||
draft: true # Meaning this will NOT be shown in Production | ||
keywords: | ||
- Getting Started | ||
- Learn | ||
- Core Protocol | ||
- Development | ||
--- | ||
|
||
## Pre-requisites | ||
|
||
In addition to Rust toolchain, LLVM and Clang are needed for build to succeed, can be installed on Ubuntu like this: | ||
```bash | ||
sudo apt-get install llvm clang | ||
``` | ||
|
||
## To Farm By Yourself (Offline) | ||
|
||
1. Download the executables for your operating system | ||
2. Open your favourite terminal, and go to the folder where you download the executables | ||
|
||
**Linux/MacOS:** | ||
1. Make them executable: `chmod +x subspace-farmer-x86_64-*-snapshot subspace-node-x86_64-*-snapshot` | ||
2. Run the node: `./subspace-node-x86_64-*-snapshot --dev --tmp` | ||
3. In macOS, it may prompt that this app is not verified. Click on `cancel` instead of moving it to trash. | ||
To allow execution, go to `System Preferences -> Security & Privacy -> General`, and click on `allow`. | ||
After this, simply repeat step 4. This time, there will be `Open` button in the prompt, click it to run node. | ||
4. Run the farmer (do this in another terminal): `./subspace-farmer-x86_64-*-snapshot farm` | ||
5. In macOS, it may prompt that this app is not verified. Click on `cancel` instead of moving it to trash. | ||
To allow execution, go to `System Preferences -> Security & Privacy -> General`, and click on `allow`. | ||
After this, simply repeat step 4. This time, there will be `Open` button in the prompt, click it to run node. | ||
|
||
**Windows** | ||
1. Run the node: `subspace-node-x86_64-*-snapshot --dev --tmp` | ||
2. After running this command, Windows may ask you for permissions related to firewall, select `allow` in this case. | ||
3. Run the farmer (do this in another terminal): `subspace-farmer-x86_64-*-snapshot farm` | ||
|
||
## To Run From The Source (primarily for developers) | ||
|
||
This is a monorepo with multiple binaries and the workflow is typical for Rust projects: | ||
|
||
- `cargo run --release --bin subspace-node -- --dev --tmp` to run [a node](/crates/subspace-node) | ||
- `cargo run --release --bin subspace-farmer farm` to [start farming](/crates/subspace-farmer) | ||
|
||
NOTE 1: You need to have `nightly` version of Rust toolchain with `wasm32-unknown-unknown` target available or else you'll get a compilation error. | ||
NOTE 2: Following the commands above, you will be farming in an offline setting (by yourself). | ||
NOTE 3: To farm in online setting, you can modify the command accordingly. | ||
|
||
You can find readme files in corresponding crates for requirements, multi-node setup and other details. |
4 changes: 4 additions & 0 deletions
4
protocol_versioned_docs/version-gemini-2a-2022-oct-06/farm/_category_.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"label": "Farm with CLI", | ||
"position": 2 | ||
} |
Oops, something went wrong.