mirror of
https://github.com/denoland/deno.git
synced 2024-11-22 15:06:54 -05:00
Minor fixes in tools/ (#2906)
* Fix tools/docs.py * Remove dead code: sync_rust_crates.py
This commit is contained in:
parent
acee1944b9
commit
49aea7abbc
3 changed files with 2 additions and 32 deletions
|
@ -11,9 +11,9 @@ os.chdir(root_path)
|
|||
# Builds into target/doc
|
||||
run(["cargo", "doc", "--all", "--no-deps", "-vv"])
|
||||
|
||||
# 'deno types' is stored in target/debug/gen/cli/lib/lib.deno_runtime.d.ts
|
||||
# 'deno types' is stored in js/lib.deno_runtime.d.ts
|
||||
# We want to run typedoc on that declaration file only.
|
||||
os.chdir(os.path.join(target_path, "debug/gen/cli/lib/"))
|
||||
os.chdir(os.path.join(root_path, "js"))
|
||||
|
||||
# You must have typedoc installed seprately.
|
||||
# TODO Replace typedoc with something else ASAP. It's very awful.
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
# Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
|
||||
# There is a magic tool which has no documentation. It is used to update rust
|
||||
# crates in third_party. https://github.com/piscisaureus/gnargo
|
||||
import third_party
|
||||
import util
|
||||
util.enable_ansi_colors()
|
||||
third_party.run_cargo()
|
|
@ -100,28 +100,6 @@ def run_yarn():
|
|||
run(["yarn", "install"], cwd=third_party_path)
|
||||
|
||||
|
||||
# Run Cargo to install Rust dependencies.
|
||||
def run_cargo():
|
||||
# Deletes the cargo index lockfile; it appears that cargo itself doesn't do
|
||||
# it. If the lockfile ends up in the git repo, it'll make cargo hang for
|
||||
# everyone else who tries to run sync_third_party.
|
||||
def delete_lockfile():
|
||||
lockfiles = find_exts([path.join(rust_crates_path, "registry/index")],
|
||||
['.cargo-index-lock'])
|
||||
for lockfile in lockfiles:
|
||||
os.remove(lockfile)
|
||||
|
||||
# Delete the index lockfile in case someone accidentally checked it in.
|
||||
delete_lockfile()
|
||||
|
||||
run(["cargo", "fetch", "--manifest-path=" + root("Cargo.toml")],
|
||||
cwd=third_party_path,
|
||||
merge_env={'CARGO_HOME': rust_crates_path})
|
||||
|
||||
# Delete the lockfile again so it doesn't end up in the git repo.
|
||||
delete_lockfile()
|
||||
|
||||
|
||||
# Install python packages with pip.
|
||||
def run_pip():
|
||||
# Install an recent version of pip into a temporary directory. The version
|
||||
|
|
Loading…
Reference in a new issue