-
Notifications
You must be signed in to change notification settings - Fork 6
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
base: main
Are you sure you want to change the base?
Conversation
""" WalkthroughThis update introduces a new Changes
Sequence Diagram(s)sequenceDiagram
participant Developer
participant direnv
participant nix-direnv
participant GitHub (nix-community)
Developer->>direnv: Enter project directory
direnv->>nix-direnv: Check nix_direnv_version
alt Version unset or not 3.0.6
nix-direnv->>GitHub (nix-community): Download [email protected] (verify SHA256)
nix-direnv->>direnv: Source direnvrc
end
direnv->>nix-direnv: Watch flake.nix and flake.lock for changes
direnv->>nix-direnv: Activate flake environment (verbose, trace)
sequenceDiagram
participant Developer
participant README.md
Developer->>README.md: Read setup instructions
README.md-->>Developer: Instruct to copy .env.example to .env
Developer->>Developer: Fill PUBLIC_WALLETCONNECT_PROJECT_ID with test ID
""" 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (4)
🧰 Additional context used🧠 Learnings (1).envrc (1)
🔇 Additional comments (6)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (4)
.envrc
(1 hunks).gitignore
(1 hunks)README.md
(1 hunks)REUSE.toml
(1 hunks)
🧰 Additional context used
🪛 markdownlint-cli2 (0.17.2)
README.md
32-32: Ordered list item prefix
Expected: 3; Actual: 2; Style: 1/2/3
(MD029, ol-prefix)
⏰ Context from checks skipped due to timeout of 90000ms (9)
- GitHub Check: standard-tests (ubuntu-latest, ob-rs-test, true)
- GitHub Check: standard-tests (ubuntu-latest, rainix-sol-static)
- GitHub Check: standard-tests (ubuntu-latest, rainix-sol-test)
- GitHub Check: standard-tests (ubuntu-latest, rainix-sol-artifacts)
- GitHub Check: git-clean
- GitHub Check: test
- GitHub Check: Deploy-Preview
- GitHub Check: build-tauri (ubuntu-22.04, true)
- GitHub Check: test
🔇 Additional comments (3)
.gitignore (1)
18-18
: Appropriate addition of.direnv/
to.gitignore
Excluding the environment directory avoids committing machine-specific state. The pattern is correct and ensures.direnv/
and its contents are ignored.REUSE.toml (1)
5-5
: Register.envrc
in REUSE.toml for license compliance
Adding.envrc
ensures the new environment configuration file is covered by REUSE tooling. The entry aligns with the existing annotation list..envrc (1)
7-10
: Watch flake files and activate the Nix flake environment
The calls towatch_file flake.lock
,watch_file flake.nix
, anduse flake .
are correct and will keep the environment in sync.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (1)
README.md
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (5)
- GitHub Check: test
- GitHub Check: Deploy-Preview
- GitHub Check: git-clean
- GitHub Check: test
- GitHub Check: test
🔇 Additional comments (1)
README.md (1)
32-32
: Approve new webapp environment setup step.
The added step for copyingpackages/webapp/.env.example
ensures thatPUBLIC_WALLETCONNECT_PROJECT_ID
is properly configured before runningprep-all.sh
.
|
||
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) | ||
|
There was a problem hiding this comment.
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.
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`. |
@0xgleb please add the direnv setup instructions and config, sounds good. we can explain it's optional but helpful for devving |
Motivation
README.md
setup instructions don't include the fact that thewebapp
package needs its own.env
file that sets a value forPUBLIC_WALLETCONNECT_PROJECT_ID
, without whichprep-all.sh
fails..env
file inpackages/webapp
was calledenv.example
instead of.env.example
Solution
.env
for the web app to theREADME.md
instructions.packages/webapp/env.example
topackages/webapp/.env.example
rust-analyzer
binary from the Nix dev shell..vscode/
if that would be helpful.Checks
By submitting this for review, I'm confirming I've done the following:
Summary by CodeRabbit
Summary by CodeRabbit
Chores
.envrc
file for improved environment management and automatic reloading on configuration changes..gitignore
to exclude the.direnv/
directory from version control..envrc
in REUSE compliance configuration.Documentation
PUBLIC_WALLETCONNECT_PROJECT_ID
.