Skip to content
GitLab
Explore
Sign in
Commits on Source (1)
During the beta, don't update the wiki automatically
· 3806feb6
ynerant
authored
Aug 06, 2020
3806feb6
Hide whitespace changes
Inline
Side-by-side
management/commands/refresh_activities.py
View file @
3806feb6
...
...
@@ -150,7 +150,7 @@ class Command(BaseCommand):
return
page
,
header
+
body
@staticmethod
def
refresh_raw_wiki_page
(
comment
=
"
refresh
"
,
debug
=
Fals
e
):
def
refresh_raw_wiki_page
(
comment
=
"
refresh
"
,
debug
=
Tru
e
):
page
,
content
=
Command
.
get_raw_page
()
if
debug
:
print
(
content
)
...
...
@@ -158,7 +158,7 @@ class Command(BaseCommand):
Command
.
edit_wiki
(
page
,
content
,
comment
)
@staticmethod
def
refresh_human_readable_wiki_page
(
comment
=
"
refresh
"
,
debug
=
Fals
e
):
def
refresh_human_readable_wiki_page
(
comment
=
"
refresh
"
,
debug
=
Tru
e
):
page
,
content
=
Command
.
get_human_readable_page
()
if
debug
:
print
(
content
)
...
...
@@ -172,9 +172,6 @@ class Command(BaseCommand):
parser
.
add_argument
(
"
--debug
"
,
"
-d
"
,
action
=
"
store_true
"
,
help
=
"
Don
'
t commit to the wiki, render in stdout
"
)
def
handle
(
self
,
*
args
,
**
options
):
with
open
(
"
/tmp/abc
"
,
"
w
"
)
as
f
:
f
.
write
(
"
lalala
"
)
f
.
write
(
str
(
options
))
if
options
[
"
raw
"
]:
Command
.
refresh_raw_wiki_page
(
options
[
"
comment
"
],
options
[
"
debug
"
])
if
options
[
"
human
"
]:
...
...