Skip to content

Commit

Permalink
executors/RUST: remove DMOJ_CARGO_OFFLINE
Browse files Browse the repository at this point in the history
Closes #1076.
  • Loading branch information
Riolku authored and Xyene committed Nov 13, 2022
1 parent 2519ea6 commit 6056849
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions dmoj/executors/RUST.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

from dmoj.cptbox.filesystem_policies import ExactFile, RecursiveDir
from dmoj.executors.compiled_executor import CompiledExecutor
from dmoj.utils.os_ext import bool_env

CARGO_TOML = b"""\
[package]
Expand Down Expand Up @@ -91,9 +90,7 @@ def get_versionable_commands(cls):
return [('rustc', os.path.join(os.path.dirname(cls.get_command()), 'rustc'))]

def get_compile_args(self):
args = [self.get_command(), 'build', '--release', '--target-dir', self.get_shared_target()]
if bool_env('DMOJ_CARGO_OFFLINE'):
args += ['--offline']
args = [self.get_command(), 'build', '--release', '--offline', '--target-dir', self.get_shared_target()]
return args

def get_compiled_file(self):
Expand Down

0 comments on commit 6056849

Please sign in to comment.