forked from facebookexperimental/MIRAI
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·23 lines (19 loc) · 713 Bytes
/
Copy pathsetup.sh
File metadata and controls
executable file
·23 lines (19 loc) · 713 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/env bash
#Copyright (c) Facebook, Inc. and its affiliates.
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
# Directory for this source file
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
TOOLCHAIN=$(cat "$DIR/rust-toolchain")
# install formatter
rustup "+$TOOLCHAIN" component add rustfmt-preview
# install linter
rustup "+$TOOLCHAIN" component add clippy-preview
# install rustc-dev
rustup "+$TOOLCHAIN" component add rustc-dev
# install llvm-tools
rustup "+$TOOLCHAIN" component add llvm-tools-preview
# install audit
cargo "+$TOOLCHAIN" install cargo-audit
# override tool chain
rustup override set $TOOLCHAIN