Commit f629d055 authored by Kai Willadsen's avatar Kai Willadsen

maint: Prepend to NEWS and open for editing

parent affb87bc
......@@ -252,7 +252,15 @@ def cli():
@cli.command()
def news():
rendered = render_template(NEWS_TEMPLATE)
click.echo(rendered)
with open('NEWS', 'r') as f:
current_news = f.read()
new_news = rendered + current_news
with open('NEWS', 'w') as f:
f.write(new_news)
message = click.edit(filename='NEWS')
return message
@cli.command()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment