进行安装
有多种方法可以安装 dora:
- pip
- Linux
- MacOS
- Windows
- Nix[OS]
- Cargo
- Source
- Github Releases
- Paste the following line in a terminal
pip install dora-rs-cli
- Paste the following line in a terminal
curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/dora-rs/dora/main/install.sh | bash
- Paste the following line in a terminal
curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/dora-rs/dora/main/install.sh | bash
- Paste the following lines in a terminal
powershell -c "irm https://raw.githubusercontent.com/dora-rs/dora/main/install.ps1 | iex"
- If you use VSCode, make sure to restart VSCode for the change to happen.
- To make a base dev-shell (Recommended):
{
description = "A base dev-shell flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
dora-rs = {
url = "github:dora-rs/dora";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = {
self,
nixpkgs,
dora-rs,
}: let
system = "x86_64-linux";
# ↑ Swap it for your system as needed
pkgs = nixpkgs.legacyPackages.${system};
in {
devShells.${system}.default = pkgs.mkShell {
buildInputs = [
dora-rs.packages.${system}.dora-cli
];
};
};
}
- To add to a system-config flake:
- First, add this to your inputs
dora-rs = {
url = "github:dora-rs/dora";
inputs.nixpkgs.follows = "nixpkgs";
};
- ...and add to your packages array. E.g. adding to your home-manager config:
{
inputs,
config,
pkgs,
...
}: {
home.packages = with pkgs; [
inputs.dora-rs.packages.x86_64-linux.dora-cli
];
}
- To install (not recommended)
nix-env --install "github:dora-rs/dora"
cargo install dora-cli # In case of issues, you can try to add `--locked`
dora --help
- Clone and build source
## dora binary
git clone https://github.com/dora-rs/dora.git
cd dora
cargo build --release -p dora-cli
PATH=$PATH:$(pwd)/target/release
- To develop python library
# pip install maturin
## Python API
maturin develop -m apis/python/node/Cargo.toml
- To test dora installation
dora --help
- Go on our release page
- download both the
zip
andwhl
file corresponding to your architecture and OS. - Unzip the zip file and place it in your binary folder (e.g.:
$HOME/bin
). - Verify that dora is well installed by calling
dora --help
in your terminal.