summaryrefslogtreecommitdiffstats
path: root/extras/autoship.py
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-02-15 13:21:07 +0100
committerDavid Robillard <d@drobilla.net>2020-02-15 13:21:07 +0100
commit840098ff27e9ea68f0760a15954d8ae4407b541b (patch)
tree951e54911b2a3c0ab17f0059b3e37837901a8731 /extras/autoship.py
parent7b0a4641dfbbad287b0ea6e9ace51acaedda40d3 (diff)
downloadautowaf-840098ff27e9ea68f0760a15954d8ae4407b541b.tar.gz
autowaf-840098ff27e9ea68f0760a15954d8ae4407b541b.tar.bz2
autowaf-840098ff27e9ea68f0760a15954d8ae4407b541b.zip
Add uri argument to ttl_news command
This can be used to set the project URI when it can't be had from the wscript, or override the one found there.
Diffstat (limited to 'extras/autoship.py')
-rwxr-xr-xextras/autoship.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/extras/autoship.py b/extras/autoship.py
index a54eac1..1b817dd 100755
--- a/extras/autoship.py
+++ b/extras/autoship.py
@@ -385,13 +385,14 @@ def ttl_news_command():
ap.add_argument("--template")
ap.add_argument("--unsorted", action="store_true", help="don't sort items")
ap.add_argument("--in-format", default="NEWS", choices=["NEWS", "turtle"])
+ ap.add_argument("--uri", help="project URI")
args = ap.parse_args(sys.argv[2:])
- info = get_project_info()
entries = read_news(args.in_path, args.in_format, args.unsorted, True)
+ uri = args.uri if args.uri else get_project_info()["uri"]
write_ttl_news(
- entries, args.out_path, template=args.template, subject_uri=info["uri"]
+ entries, args.out_path, template=args.template, subject_uri=uri
)