1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-01-26 06:46:13 +01:00

set OSC_VERSION environment for source services

will be needed by new obs_scm service
This commit is contained in:
Adrian Schröter 2016-04-01 12:57:00 +02:00
parent c5f56e7f6c
commit 65201ad1bc
2 changed files with 4 additions and 1 deletions

2
NEWS
View File

@ -1,5 +1,5 @@
0.154
-
- set OSC_VERSION environment for source services
0.153
- "my sr" is using the server side request collection to get right results

View File

@ -381,6 +381,9 @@ class Serviceinfo:
data = { 'name' : singleservice, 'command' : [ singleservice ], 'mode' : '' }
allservices = [data]
# services can detect that they run via osc this way
os.putenv("OSC_VERSION", get_osc_version())
# set environment when using OBS 2.3 or later
if self.project != None:
os.putenv("OBS_SERVICE_PROJECT", self.project)