File tree 1 file changed +9
-1
lines changed 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 36
36
37
37
# are we running circle CI?
38
38
CIRCLECI = 'CIRCLECI' in os .environ
39
+ # are we deploying this build to matplotlib.org/devdocs?
40
+ # This is a copy of the logic in .circleci/deploy-docs.sh
41
+ DEVDOCS = (
42
+ CIRCLECI and
43
+ (os .environ .get ("CIRCLE_PROJECT_USERNAME" ) == "matplotlib" ) and
44
+ (os .environ .get ("CIRCLE_BRANCH" ) == "main" ) and
45
+ (not os .environ .get ("CIRCLE_PULL_REQUEST" , "" ).startswith (
46
+ "https://github.com/matplotlib/matplotlib/pull" )))
39
47
40
48
41
49
def _parse_skip_subdirs_file ():
@@ -489,7 +497,7 @@ def js_tag_with_cache_busting(js):
489
497
"https://output.circle-artifacts.com/output/job/"
490
498
f"{ os .environ ['CIRCLE_WORKFLOW_JOB_ID' ]} /artifacts/"
491
499
f"{ os .environ ['CIRCLE_NODE_INDEX' ]} "
492
- "/doc/build/html/_static/switcher.json" if CIRCLECI else
500
+ "/doc/build/html/_static/switcher.json" if CIRCLECI and not DEVDOCS else
493
501
f"https://matplotlib.org/devdocs/_static/switcher.json?{ SHA } "
494
502
),
495
503
"version_match" : (
You can’t perform that action at this time.
0 commit comments