Permalink
Please sign in to comment.
Browse files
Add copr build integration
Builds can be found here: https://copr.fedoraproject.org/coprs/purpleidea/oh-my-vagrant/ API setup per user can be found here: https://copr.fedoraproject.org/api/
- Loading branch information...
Showing
with
35 additions
and 2 deletions.
- +10 −2 Makefile
- +25 −0 extras/copr-build.py
| @@ -0,0 +1,25 @@ | ||
| +#!/usr/bin/python | ||
| + | ||
| +# README: | ||
| +# for initial setup, browse to: https://copr.fedoraproject.org/api/ | ||
| +# and it will have a ~/.config/copr config that you can download. | ||
| +# happy hacking! | ||
| + | ||
| +import os | ||
| +import sys | ||
| +import copr | ||
| + | ||
| +COPR = 'oh-my-vagrant' | ||
| +if len(sys.argv) != 2: | ||
| + print("Usage: %s <srpm url>" % sys.argv[0]) | ||
| + sys.exit(1) | ||
| + | ||
| +url = sys.argv[1] | ||
| + | ||
| +client = copr.CoprClient.create_from_file_config(os.path.expanduser("~/.config/copr")) | ||
| + | ||
| +result = client.create_new_build(COPR, [url]) | ||
| +if result.output != "ok": | ||
| + print(result.error) | ||
| + sys.exit(1) | ||
| +print(result.message) |
0 comments on commit
6a6d1f2