Class: Dependabot::RustToolchain::Models::RustToolchainConfig
- Inherits:
-
T::ImmutableStruct
- Object
- T::ImmutableStruct
- Dependabot::RustToolchain::Models::RustToolchainConfig
- Extended by:
- T::Sig
- Defined in:
- lib/dependabot/rust_toolchain/models/rust_toolchain_config.rb
Overview
Typed struct for the [toolchain] section of rust-toolchain.toml files rust-lang.github.io/rustup/overrides.html#the-toolchain-file
Class Method Summary collapse
Class Method Details
.from_hash(data) ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/dependabot/rust_toolchain/models/rust_toolchain_config.rb', line 21 def self.from_hash(data) new( channel: T.cast(data["channel"], String) ) rescue TypeError => e raise Dependabot::DependencyFileNotParseable, "Invalid toolchain config: #{e.}" end |