mirror of
https://github.com/frappe/bench.git
synced 2025-01-24 15:38:25 +00:00
require configuration for release
This commit is contained in:
parent
c830eda3bf
commit
98c1949120
@ -102,6 +102,9 @@ def update(pull=False, patch=False, build=False, bench=False, auto=False, restar
|
|||||||
pull, patch, build, bench, requirements = True, True, True, True, True
|
pull, patch, build, bench, requirements = True, True, True, True, True
|
||||||
|
|
||||||
conf = get_config()
|
conf = get_config()
|
||||||
|
if conf.get('release_bench'):
|
||||||
|
print 'Release bench, cannot update'
|
||||||
|
sys.exit(1)
|
||||||
if auto and not conf.get('auto_update'):
|
if auto and not conf.get('auto_update'):
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
if bench and conf.get('update_bench_on_update'):
|
if bench and conf.get('update_bench_on_update'):
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
#! env python
|
#! env python
|
||||||
import json
|
import json
|
||||||
import os
|
import os
|
||||||
|
import sys
|
||||||
import semantic_version
|
import semantic_version
|
||||||
import git
|
import git
|
||||||
import json
|
import json
|
||||||
@ -11,6 +12,7 @@ import re
|
|||||||
from requests.auth import HTTPBasicAuth
|
from requests.auth import HTTPBasicAuth
|
||||||
import requests.exceptions
|
import requests.exceptions
|
||||||
from time import sleep
|
from time import sleep
|
||||||
|
from .utils import get_config
|
||||||
|
|
||||||
github_username = None
|
github_username = None
|
||||||
github_password = None
|
github_password = None
|
||||||
@ -154,6 +156,9 @@ def bump(repo, bump_type):
|
|||||||
print 'Released {tag} for {repo}'.format(tag=tag_name, repo=repo)
|
print 'Released {tag} for {repo}'.format(tag=tag_name, repo=repo)
|
||||||
|
|
||||||
def release(repo, bump_type):
|
def release(repo, bump_type):
|
||||||
|
if not get_config().get('release_bench'):
|
||||||
|
print 'bench not configured to release'
|
||||||
|
sys.exit(1)
|
||||||
global github_username, github_password
|
global github_username, github_password
|
||||||
github_username = raw_input('username:')
|
github_username = raw_input('username:')
|
||||||
github_password = getpass.getpass()
|
github_password = getpass.getpass()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user