mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
mach: Remove mach rustup
(#34287)
We don't use the nightly toolchain anymore, so this command can be removed. Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>
This commit is contained in:
parent
26748621cd
commit
5113147f80
1 changed files with 0 additions and 19 deletions
|
@ -13,7 +13,6 @@ import signal
|
|||
import subprocess
|
||||
import sys
|
||||
import tempfile
|
||||
import urllib
|
||||
|
||||
from mach.decorators import (
|
||||
CommandArgument,
|
||||
|
@ -168,24 +167,6 @@ class MachCommands(CommandBase):
|
|||
["git"] + ["grep"] + params + ['--'] + grep_paths + [':(exclude)*.min.js', ':(exclude)*.min.css'],
|
||||
env=self.build_env())
|
||||
|
||||
@Command('rustup',
|
||||
description='Update the Rust version to latest Nightly',
|
||||
category='devenv')
|
||||
def rustup(self):
|
||||
nightly_date = urllib.request.urlopen(
|
||||
"https://static.rust-lang.org/dist/channel-rust-nightly-date.txt").read()
|
||||
new_toolchain = f"nightly-{nightly_date.decode('utf-8')}"
|
||||
old_toolchain = self.rust_toolchain()
|
||||
|
||||
filename = path.join(self.context.topdir, "rust-toolchain.toml")
|
||||
with open(filename, "r", encoding="utf-8") as file:
|
||||
contents = file.read()
|
||||
contents = contents.replace(old_toolchain, new_toolchain)
|
||||
with open(filename, "w", encoding="utf-8") as file:
|
||||
file.write(contents)
|
||||
|
||||
self.ensure_bootstrapped()
|
||||
|
||||
@Command('fetch',
|
||||
description='Fetch Rust, Cargo and Cargo dependencies',
|
||||
category='devenv')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue