Skip to content

Commit

Permalink
Merge c2e6d99 into 6e9c086
Browse files Browse the repository at this point in the history
  • Loading branch information
jaumef committed Apr 3, 2017
2 parents 6e9c086 + c2e6d99 commit 663ab12
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 15 deletions.
20 changes: 15 additions & 5 deletions hookshub/hooks/github_hooks/pull_request-powerp-docs_endPR.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,19 @@ def arguments():
event = sys.argv[2]
return payload, event


# Creació i activació del virtalenv temporal
def virtualenv(venv=''):
import os
if not venv:
venv = 'foo'

os.system('virtualenv %s' % venv)

activate = join(venv, 'bin', 'activate_this.py')
execfile(activate, dict(__file__=activate))


payload, event = arguments()

output = ''
Expand Down Expand Up @@ -130,11 +143,8 @@ def arguments():

# Instalem dependencies

output += '{} OK |'.format(Util.pip_requirements(clone_dir))

# Exportem PYTHONPATH

output += '{} OK |'.format(Util.export_pythonpath(clone_dir))
virtualenv(branch_name)
output += '{} |'.format(Util.pip_requirements(clone_dir) or 'OK')

# Fem build al directori on tenim la pagina des del directori del clone
# Build en català
Expand Down
20 changes: 15 additions & 5 deletions hookshub/hooks/github_hooks/pull_request-powerp-docs_newPR.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,19 @@ def arguments():
event = sys.argv[2]
return payload, event


# Creació i activació del virtalenv temporal
def virtualenv(venv=''):
import os
if not venv:
venv = 'foo'

os.system('virtualenv %s' % venv)

activate = join(venv, 'bin', 'activate_this.py')
execfile(activate, dict(__file__=activate))


payload, event = arguments()

output = ''
Expand Down Expand Up @@ -112,11 +125,8 @@ def arguments():

# Instalem dependencies

output += '{} OK |'.format(Util.pip_requirements(clone_dir))

# Exportem PYTHONPATH

output += '{} OK |'.format(Util.export_pythonpath(clone_dir))
virtualenv(branch_name)
output += '{} |'.format(Util.pip_requirements(clone_dir) or 'OK')

# Fem build al directori on tenim la pagina des del directori del clone
# Build en català
Expand Down
19 changes: 14 additions & 5 deletions hookshub/hooks/github_hooks/push-powerp-docs.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,18 @@ def arguments():
return payload, event


# Creació i activació del virtalenv temporal
def virtualenv(venv=''):
import os
if not venv:
venv = 'foo'

os.system('virtualenv %s' % venv)

activate = join(venv, 'bin', 'activate_this.py')
execfile(activate, dict(__file__=activate))


payload, event = arguments()

output = ''
Expand Down Expand Up @@ -99,11 +111,8 @@ def arguments():

# Instalem dependencies

output += '{} OK |'.format(Util.pip_requirements(clone_dir))

# Exportem PYTHONPATH

output += '{} OK |'.format(Util.export_pythonpath(clone_dir))
virtualenv(branch_name)
output += '{} |'.format(Util.pip_requirements(clone_dir) or 'OK')

# Fem build al directori on tenim la pàgina des del directori del clone

Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ osconf
flask
raven==5.0.0
blinker
virtualenv

0 comments on commit 663ab12

Please sign in to comment.