From 306732b68d018e6f47e089906c25d80b8f836709 Mon Sep 17 00:00:00 2001 From: "Matthew R. Becker" Date: Tue, 23 Mar 2021 19:31:26 -0500 Subject: [PATCH] Delete stop_me_if_needed.py --- stop_me_if_needed.py | 31 ------------------------------- 1 file changed, 31 deletions(-) delete mode 100644 stop_me_if_needed.py diff --git a/stop_me_if_needed.py b/stop_me_if_needed.py deleted file mode 100644 index a401d7fe..00000000 --- a/stop_me_if_needed.py +++ /dev/null @@ -1,31 +0,0 @@ -import os -import tempfile -import subprocess -import contextlib - - -# https://stackoverflow.com/questions/6194499/pushd-through-os-system -@contextlib.contextmanager -def pushd(new_dir): - previous_dir = os.getcwd() - os.chdir(new_dir) - try: - yield - finally: - os.chdir(previous_dir) - - -with tempfile.TemporaryDirectory() as tmpdir, pushd(tmpdir): - subprocess.run( - ["git", "clone", "--depth=1", "https://github.com/conda-forge/repodata.git"], - check=True - ) - - if os.path.exists(os.path.join("repodata", "please.go")): - go = True - else: - go = False - -if not go: - print("I could not find the file 'please.go' on master! Stopping!") - subprocess.run("echo \"CI_SKIP=true\" >> $GITHUB_ENV", shell=True)