Skip to content

Commit

Permalink
Merge branch 'main' into renovate/configure
Browse files Browse the repository at this point in the history
  • Loading branch information
drichar authored Apr 4, 2024
2 parents af662a6 + b42b4e7 commit 9595969
Show file tree
Hide file tree
Showing 68 changed files with 14,865 additions and 18,564 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/ci-ui.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: CI Workflow (UI)

on:
push:
branches: [ dev, main ]
pull_request:
branches: [ dev, main ]

jobs:
run-ci:
name: Lint, Typecheck, Test, and Build
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version: 20

- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 8
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm --filter ./ui install

- name: Lint
run: pnpm --filter ./ui run lint

- name: Prettier
run: pnpm --filter ./ui run prettier

- name: Typecheck
run: pnpm --filter ./ui run typecheck

- name: Run tests
run: pnpm --filter ./ui run test

- name: Build
run: pnpm --filter ./ui run build
2 changes: 1 addition & 1 deletion .idea/jsLibraryMappings.xml

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

8 changes: 8 additions & 0 deletions .idea/prettier.xml

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

7 changes: 1 addition & 6 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
{
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"typescript.tsdk": "./ui/node_modules/typescript/lib"
"typescript.tsdk": "./ui/node_modules/typescript/lib"
}
84 changes: 77 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,83 @@
# Reti Open Pooling
# Réti Open Pooling

See [Reti Open Pooling](./docs/reti-open-pooling.md) for details on the proposal this implementation is for.
Welcome to the Réti Open Pooling monorepo. This README provides instructions for running the protocol and its accompanying example UI in a local environment. Detailed protocol information and its objectives can be found in the [Gitbook documentation](https://txnlab.gitbook.io/reti-open-pooling).

## Tealscript Contracts
## Overview

See [Contracts](./contracts/README.md)
The Réti Open Pooling protocol enables the creation of decentralized staking pools on the Algorand network, promoting broader participation and enhancing network security through diversification. It is designed to be open-source, non-custodial, and fully decentralized, allowing for the creation and joining of staking pools to meet the minimum stake required for node rewards on Algorand.

## Node Daemon
## Prerequisites

## UI
Before starting, ensure you have the following installed:
- **Docker**: Required for running AlgoKit. [Installation guide](https://www.docker.com/get-started).
- **AlgoKit**: Version 2.0 or later is required. [Installation guide](https://github.com/algorandfoundation/algokit-cli#install). Verify by running `algokit --version`.
- **PNPM**: Version 8.0 or later for package management. [Installation guide](https://pnpm.io/installation). Verify by running `pnpm --version`.

See [UI](./ui/README.md)
## Quick Start

This section provides instructions for running the protocol and UI in a local AlgoKit sandbox environment.

- **Clone the repository**

```bash
git clone https://github.com/TxnLab/reti.git
```

- **Navigate to the `reti` directory**

```bash
cd reti
```

- **Install dependencies**

```bash
pnpm install
```

- **Start the local network**

```bash
algokit localnet start
```

- **Bootstrap the validator**

This command bootstraps a new master validator and funds two new test accounts. It also sets environment variables for LocalNet that will be used by the front-end.
```bash
pnpm run bootstrap
```

- **Launch the UI**

```bash
pnpm run dev
```

## TestNet Development

- **Navigate to the `ui` directory**

```bash
cd ui
```

- **Create a `.env.testnet` file**

Copy the TestNet variables from the [`.env.template`](./ui/.env.template) file into a new `.env.testnet` file. Check back often to make sure you're using the latest master validator app ID, set to `VITE_RETI_APP_ID`.

- **Launch the UI**

```bash
pnpm run dev:testnet
```

## Additional Resources

- **TEALScript Contracts**: Explore the smart contracts that power the protocol. [Read more](./contracts/README.md)
- **Node Daemon**: Learn about the CLI / service daemon which node runners will run as a background service. [Read more](./docs/technical-implementation/reti-node-daemon/README.md)
- **Example UI**: A Vite React project that serves as a dashboard for staking and validator management. [Read more](./ui/README.md)

## Discord

For questions or technical support, you can reach us in the **#reti** channel on NFD's Discord: https://discord.gg/w6vSwG5bFK
1 change: 1 addition & 0 deletions contracts/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ module.exports = {
'no-param-reassign': 'off',
'no-restricted-syntax': 'off',
'no-continue': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
},
},
{
Expand Down
Loading

0 comments on commit 9595969

Please sign in to comment.