Skip to content

Commit 8da5d62

Browse files
Update copilot-instructions.md (#1550)
### What Remove unused deps from Copilot instructions: rust-src, cargo-watch, cargo-nextest. ### Why They aren't required tools. Telling Copilot to use rust-src is likely to send it on tangents we don't want it to take. Recompiling rust-src and relying on features that Rust provides only through rust-src would harm the developer experience of folks using the soroban-sdk, requiring them to also use rust-src which is a not a common Rust developer experience. cargo-watch is a deprecated tool and not recommended to use. Unclear to me why Copilot would benefit from it since it is more likely to benefit from choosing to run appropriate test commands after each change, which the instructions already detail. cargo-nextest is not needed. It may speed up test runs, but we don't use it in the Makefile and Copilot will benefit from using the test targets in the Makefile to ensure that the test vectors build before tests.
1 parent daa1724 commit 8da5d62

2 files changed

Lines changed: 2 additions & 17 deletions

File tree

.github/copilot-instructions.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,11 @@ Always reference these instructions first and fallback to search or bash command
1111
- `curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh`
1212
- `rustup install stable`
1313
- `rustup +stable target add wasm32v1-none`
14-
- `rustup +stable component add rust-src`
1514
- Install Rust nightly (required for documentation):
1615
- `rustup install nightly`
1716
- `rustup +nightly target add wasm32v1-none`
18-
- `rustup +nightly component add rust-src`
1917
- Install required cargo tools:
2018
- `cargo install --locked cargo-hack`
21-
- `cargo install --locked cargo-nextest`
22-
- `cargo install --locked cargo-watch`
2319

2420
### Build Commands
2521
- **CRITICAL**: Format code first: `make fmt` -- takes ~1 second
@@ -54,7 +50,7 @@ After making changes to the SDK, always validate with these scenarios:
5450
- Use `log!` macro for debugging in tests
5551

5652
3. **Contract Compilation Validation**:
57-
- Build all test contracts: `make build` or `cargo hack build --target wasm32v1-none --release --workspace --exclude soroban-spec --exclude soroban-spec-rust --exclude soroban-ledger-snapshot`
53+
- Build all test contracts: `make build`
5854
- Verify all Wasm files are generated correctly
5955
- Check that Wasm file sizes are reasonable (200B-3KB range)
6056
- Ensure no compilation warnings for the main SDK packages
@@ -111,8 +107,6 @@ After making changes to the SDK, always validate with these scenarios:
111107

112108
### Cargo Tools Usage
113109
- `cargo-hack` - Feature powerset testing and multi-target builds
114-
- `cargo-nextest` - Fast test execution (alternative to `cargo test`)
115-
- `cargo-watch` - File watching for development
116110

117111
### Build Artifacts
118112
- Wasm contracts output to `target/wasm32v1-none/release/*.wasm`
@@ -173,4 +167,4 @@ After creating a contract:
173167
1. Build Wasm: `cargo build --target wasm32v1-none --release`
174168
2. Test: `cargo test` (tests run on native target with std)
175169
3. Verify Wasm output in `target/wasm32v1-none/release/` (typically 500B-3KB)
176-
4. Check contract functions work as expected in test environment
170+
4. Check contract functions work as expected in test environment

CONTRIBUTING.md

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,26 +14,17 @@ Install rust stable:
1414
```
1515
rustup install stable
1616
rustup +stable target add wasm32v1-none
17-
rustup +stable component add rust-src
1817
```
1918

2019
Install rust nightly:
2120
```
2221
rustup install nightly
2322
rustup +nightly target add wasm32v1-none
24-
rustup +nightly component add rust-src
2523
```
2624

2725
Install cargo tools:
2826
```
2927
cargo install --locked cargo-hack
30-
cargo install --locked cargo-nextest
31-
cargo install --locked cargo-watch
32-
```
33-
34-
Install binaryen (for `wasm-opt`):
35-
```
36-
brew install binaryen
3728
```
3829

3930
## Command Cheatsheet

0 commit comments

Comments
 (0)