remove source-lit docs 2 (#15527)

This commit is contained in:
Carlos Mocholí 2022-11-04 18:01:04 +01:00 committed by GitHub
parent 39c6ec9ce3
commit 0c63534b7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 1 additions and 44 deletions

View File

@ -31,7 +31,7 @@ jobs:
strategy:
fail-fast: false
matrix:
pkg-name: ["app", "pytorch"] # TODO: , "lit"
pkg-name: ["app", "pytorch"]
env:
FREEZE_REQUIREMENTS: "1"
steps:

3
.gitignore vendored
View File

@ -9,9 +9,6 @@ lightning_logs/
# Documentations
docs/source-app/generated
docs/source-app/*/generated
docs/source-lit/generated
docs/source-lit/*/generated
docs/source-lit/api
docs/source-pytorch/api
docs/source-pytorch/*.md
docs/source-pytorch/generated

View File

@ -22,9 +22,6 @@ clean:
rm -rf ./docs/source-pytorch/api
rm -rf ./docs/source-app/generated
rm -rf ./docs/source-app/*/generated
rm -rf ./docs/source-lit/api
rm -rf ./docs/source-lit/generated
rm -rf ./docs/source-lit/*/generated
rm -rf build
rm -rf dist
rm -rf *.egg-info

View File

@ -1,27 +0,0 @@
import glob
import os
def symlink_folder(source_dir, target_dir: str = "source-lit") -> None:
assert os.path.isdir(source_dir)
assert os.path.isdir(target_dir)
ls = glob.glob(os.path.join(source_dir, "**"), recursive=True)
for path_ in ls:
path_target = path_.replace(source_dir, target_dir)
if os.path.isdir(path_) or os.path.exists(path_target):
continue
if os.path.islink(path_target):
print(path_target)
continue
path_dir = os.path.dirname(path_target)
os.makedirs(path_dir, exist_ok=True)
depth = path_.count(os.path.sep)
path_root = os.path.sep.join([".."] * depth)
path_source = os.path.join(path_root, path_)
# print(path_source, path_target, os.path.exists(path_target))
os.symlink(path_source, path_target)
if __name__ == "__main__":
for name in ("app", "pytorch"):
symlink_folder(f"source-{name}")

View File

@ -1 +0,0 @@
# this is just compatibility placeholder for the future fused docs

View File

@ -1 +0,0 @@
-r ../pytorch/examples.txt

View File

@ -1,8 +0,0 @@
-r ../docs.txt
ipython[notebook]
ipython_genutils
lai-sphinx-theme
-r ../../_notebooks/.actions/requirements.txt