Skip to content

Commit

Permalink
Merge pull request #1857 from rsteube/environment-rust
Browse files Browse the repository at this point in the history
environment: added rust
  • Loading branch information
rsteube authored Sep 20, 2023
2 parents b0a0303 + cce64b6 commit 0f9b822
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions pkg/actions/env/rust.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package env

import (
"github.com/rsteube/carapace"
"github.com/rsteube/carapace/pkg/style"
)

func init() {
_bool := carapace.ActionValuesDescribed("0", "disabled", "1", "enabled").StyleF(style.ForKeyword)
knownVariables["rust"] = variables{
Condition: checkPath("rustc"),
Names: map[string]string{
"RUST_TEST_THREADS": "The test framework Rust provides executes tests in parallel",
"RUST_TEST_NOCAPTURE": "Synonym for the --nocapture flag",
"RUST_MIN_STACK": "Sets the minimum stack size for new threads",
"RUST_BACKTRACE": "Produces a backtrace in the output of a program which panics",
},
Completion: map[string]carapace.Action{
"RUST_TEST_THREADS": carapace.ActionValues(),
"RUST_TEST_NOCAPTURE": _bool,
"RUST_MIN_STACK": carapace.ActionValues(),
"RUST_BACKTRACE": _bool,
},
}

}

0 comments on commit 0f9b822

Please sign in to comment.