rust

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 27, 2026 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Overview

Package rust provides a Rust builder that downloads rustc toolchains from static.rust-lang.org.

Import this package for its side effects to register the builder:

import _ "github.com/Highload-fun/builders/rust"

Index

Constants

View Source
const BuilderId = "rust"

BuilderId is the identifier used to register and look up this builder.

Variables

This section is empty.

Functions

This section is empty.

Types

type Rust

type Rust struct {
	// contains filtered or unexported fields
}

Rust implements builders.Builder for the Rust programming language.

func (*Rust) Build

func (r *Rust) Build(ctx context.Context, sb *sandbox.Sandbox, version string, flags []string) error

Build compiles Rust source code (main.rs) inside the sandbox using rustc. If version is empty, "rust-1.47.0" is used. The toolchain is downloaded on demand and cached in builders.CompilersHostDir.

func (*Rust) GetVersions

func (r *Rust) GetVersions(ctx context.Context) ([]builders.Version, error)

GetVersions parses the Rust RELEASES.md on GitHub for available versions. Results are cached for 1 hour.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL