1
0
Fork 0
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:
Ryan Dahl 2019-09-10 14:34:54 -04:00 committed by GitHub
parent acee1944b9
commit 49aea7abbc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 2 additions and 32 deletions

View file

@ -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.

View file

@ -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()

View file

@ -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