This repository hosts the official Devcontainer image for Near Protocol development, featuring preinstalled essential tools. You can access the image on the GitHub Container Registry.
To incorporate this Devcontainer into your own repositories, follow these steps:
- Fork the NEAR Rust Stack template repo.
- Open the forked repository in Codespaces.
For integrating this Devcontainer into your repositories, create the following configuration in .devcontainer/devcontainer.json
:
{
"name": "NEAR Devcontainer Rust",
"image": "ghcr.io/near/near-devcontainer:latest",
// Uncomment and modify the following lines if necessary
// "forwardPorts": [8000],
"customizations": {
"codespaces": {
// Uncomment and modify the following lines if necessary
// "openFiles": ["README.md", "src/lib.rs", "tests/test_basics.rs"]
}
}
}
The near-cli
and cargo-near
features are available separately and can be used in other Devcontainers. Include the following configurations in your .devcontainer/devcontainer.json
:
For cargo-near
:
"features": {
"ghcr.io/near/near-devcontainers/features/cargo-near:latest": {}
}
For near-cli
:
"features": {
"ghcr.io/near/near-devcontainers/features/near-cli:latest": {}
}
Feel free to contribute to this Devcontainer repository. Any issues or improvements can be raised through the GitHub repository's issue tracker.