We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 64981f1 commit 03ec090Copy full SHA for 03ec090
scripts/build.py
@@ -1,9 +1,12 @@
1
import functools
2
import json
3
+import os
4
import re
5
import semver
6
import subprocess as sp
7
8
+BASE_URL_ENV = 'TOUR_BASE_URL'
9
+
10
def exec(*argv):
11
print("$>"," ".join(argv))
12
res = sp.run(argv, capture_output=True)
@@ -16,11 +19,16 @@ def exec(*argv):
16
19
17
20
18
21
def runHugo(outSuffix=""):
22
+ baseUrl = "http://tour.dgraph.io/"
23
+ if BASE_URL_ENV in os.environ:
24
+ baseUrl = os.environ[BASE_URL_ENV]
25
+ baseUrl += outSuffix
26
27
return exec(
28
"hugo",
29
"--destination=public/" + outSuffix,
30
"--baseURL",
- "https://tour.dgraph.io/" + outSuffix,
31
+ baseUrl,
32
"--config",
33
"config.toml,releases.json",
34
)
0 commit comments