🐛 check that we're posting from the mediawiki directory
This commit is contained in:
parent
8519b97a1d
commit
568e1fee07
1 changed files with 2 additions and 0 deletions
|
@ -28,6 +28,8 @@ def post(files):
|
||||||
files.append(filepath)
|
files.append(filepath)
|
||||||
|
|
||||||
for filepath in files:
|
for filepath in files:
|
||||||
|
if OUTDIR_MEDIAWIKI not in filepath:
|
||||||
|
raise ValueError("{filepath} not in {OUTDIR_MEDIAWIKI}")
|
||||||
filename = os.path.basename(filepath)
|
filename = os.path.basename(filepath)
|
||||||
|
|
||||||
article_name = WIKI_ARTICLE_PREFIX + filename.replace(".mediawiki", "")
|
article_name = WIKI_ARTICLE_PREFIX + filename.replace(".mediawiki", "")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue