diff options
author | Nick Mathewson <nickm@torproject.org> | 2023-10-18 08:25:38 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2023-10-18 08:25:38 -0400 |
commit | 16a65bab070f6be294d486020da19de0ce96b412 (patch) | |
tree | fa6a7fb563090c90d6ab7231b9ac8aee515dedac | |
parent | 644db3554745164d7df2c05d246aaa849a1c16b4 (diff) | |
download | torspec-16a65bab070f6be294d486020da19de0ce96b412.tar.gz torspec-16a65bab070f6be294d486020da19de0ce96b412.zip |
Move all binaries to a "bin" directory.
-rw-r--r-- | .gitlab-ci.yml | 4 | ||||
-rwxr-xr-x | bin/build_html.sh (renamed from build_html.sh) | 6 | ||||
-rwxr-xr-x | bin/check_index (renamed from proposals/check_index) | 0 | ||||
-rwxr-xr-x | bin/make_redirects.py (renamed from mdbook/spec/make_redirects.py) | 2 | ||||
-rwxr-xr-x | bin/reindex.py (renamed from proposals/reindex.py) | 3 | ||||
-rw-r--r-- | spec/README.md | 2 |
6 files changed, 10 insertions, 7 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 60eb76d..ac60298 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -7,8 +7,8 @@ build: image: hrektts/mdbook script: - apt-get update && apt-get install -y python3 git - - ./proposals/check_index - - ./build_html.sh + - ./bin/check_index + - ./bin/build_html.sh - mv html public artifacts: paths: diff --git a/build_html.sh b/bin/build_html.sh index cb33660..d58e3ed 100755 --- a/build_html.sh +++ b/bin/build_html.sh @@ -2,9 +2,9 @@ set -e -u -o pipefail -x -TOPLEVEL=$(realpath $(dirname "$0")) -cd "${TOPLEVEL}/proposals" -./reindex.py +TOPLEVEL=$(realpath $(dirname "$0"))/.. +cd "${TOPLEVEL}" +./bin/reindex.py cd "${TOPLEVEL}/mdbook/spec" mdbook build diff --git a/proposals/check_index b/bin/check_index index 61db50d..61db50d 100755 --- a/proposals/check_index +++ b/bin/check_index diff --git a/mdbook/spec/make_redirects.py b/bin/make_redirects.py index c582505..d826bcd 100755 --- a/mdbook/spec/make_redirects.py +++ b/bin/make_redirects.py @@ -44,7 +44,7 @@ def readme_redirects(rs): return "".join(lines) if __name__ == '__main__': - toplevel = os.path.join(os.path.dirname(sys.argv[0]), "..", "..") + toplevel = os.path.join(os.path.dirname(sys.argv[0]), "..") book_fname = os.path.join(toplevel, "mdbook", "spec", "book.toml") spec_dir = os.path.join(toplevel, "spec") readme_fname = os.path.join(toplevel, "spec", "README.md") diff --git a/proposals/reindex.py b/bin/reindex.py index 8bc9729..57ac403 100755 --- a/proposals/reindex.py +++ b/bin/reindex.py @@ -203,6 +203,9 @@ def writeMarkdownIndexFiles(proposals): writeMarkdownFile(prefix, format_inputs) if __name__ == '__main__': + proposal_dir = os.path.join(os.path.dirname(sys.argv[0]), "..", "proposals") + os.chdir(proposal_dir) + proposals = readProposals() try: writeTextIndexFile(proposals) diff --git a/spec/README.md b/spec/README.md index 3439afe..9bea38b 100644 --- a/spec/README.md +++ b/spec/README.md @@ -54,7 +54,7 @@ The chapter structure as a whole is defined in a special file called documentation][mdbook documentation] for more information. You can build the website locally to see how it renders. To do this, -just install mdbook and run the `./build_html.sh` script. (You will +just install mdbook and run the `./bin/build_html.sh` script. (You will need to have mdbook installed to do this.) ### Managing links |