Skip to content

Fix setup #1709

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
if ! has nix_direnv_version || ! nix_direnv_version 3.0.6; then
URL=https://raw.githubusercontent.com/nix-community/nix-direnv/3.0.6/direnvrc
HASH=sha256-RYcUJaRMf8oF5LznDrlCXbkOQrywm0HDv1VjYGaJGdM=
source_url "$URL" "$HASH"
fi

watch_file flake.lock
watch_file flake.nix

use flake . --verbose --show-trace
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ packages/orderbook/cjs.d.ts
packages/orderbook/esm.js
packages/orderbook/esm.d.ts
tauri-app/src/lib/types
.direnv/
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ This same package is [published to npm](https://www.npmjs.com/package/@rainlangu

1. Copy `.env.example` to `.env`
2. Copy `tauri-app/.env.example` to `tauri-app/.env` and fill out `VITE_WALLETCONNECT_PROJECT_ID` with a test project ID from [Reown (FKA WalletConnect)](https://cloud.reown.com/sign-in)
3. Copy `packages/webapp/.env.example` to `packages/webapp/.env` and fill out `PUBLIC_WALLETCONNECT_PROJECT_ID` with a test project ID from [Reown (FKA WalletConnect)](https://cloud.reown.com/sign-in)

Comment on lines 29 to 33
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Suggest documenting Direnv activation.
Since this PR introduces an .envrc for nix-direnv, it’s helpful to add a note instructing users to run direnv allow so their shells and editors load the environment automatically. For example:

 ### Environment Setup
 1. Copy `.env.example` to `.env`
 2. Copy `tauri-app/.env.example` to `tauri-app/.env` and fill out `VITE_WALLETCONNECT_PROJECT_ID` with a test project ID from Reown (FKA WalletConnect)
 3. Copy `packages/webapp/.env.example` to `packages/webapp/.env` and fill out `PUBLIC_WALLETCONNECT_PROJECT_ID` with a test project ID from Reown (FKA WalletConnect)
+4. Run `direnv allow` in the project root to activate the Nix environment via `nix-direnv`.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
1. Copy `.env.example` to `.env`
2. Copy `tauri-app/.env.example` to `tauri-app/.env` and fill out `VITE_WALLETCONNECT_PROJECT_ID` with a test project ID from [Reown (FKA WalletConnect)](https://cloud.reown.com/sign-in)
3. Copy `packages/webapp/.env.example` to `packages/webapp/.env` and fill out `PUBLIC_WALLETCONNECT_PROJECT_ID` with a test project ID from [Reown (FKA WalletConnect)](https://cloud.reown.com/sign-in)
### Environment Setup
1. Copy `.env.example` to `.env`
2. Copy `tauri-app/.env.example` to `tauri-app/.env` and fill out `VITE_WALLETCONNECT_PROJECT_ID` with a test project ID from [Reown (FKA WalletConnect)](https://cloud.reown.com/sign-in)
3. Copy `packages/webapp/.env.example` to `packages/webapp/.env` and fill out `PUBLIC_WALLETCONNECT_PROJECT_ID` with a test project ID from [Reown (FKA WalletConnect)](https://cloud.reown.com/sign-in)
4. Run `direnv allow` in the project root to activate the Nix environment via `nix-direnv`.

Then run the following to install dependencies and build the project:
```bash
Expand Down
1 change: 1 addition & 0 deletions REUSE.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ version = 1

[[annotations]]
path = [
".envrc",
".gas-snapshot",
".github/workflows/**/",
".gitignore",
Expand Down
File renamed without changes.