mirror of
git://git.yoctoproject.org/layerindex-web.git
synced 2025-07-19 20:59:01 +02:00
Track PE and PR for recipes
This change is to record PE (epoch) and PR (release) values for recipes. These values will be reflected in the REST API but will not be exposed in the UI. The aim of this change is to enrich metadata availability to consumers of the feed. Signed-off-by: Pranay Mankad <pranaymankad@gmail.com> Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
This commit is contained in:
parent
db51830ab2
commit
a549f6f393
20
layerindex/migrations/0042_recipe_pe_pr.py
Normal file
20
layerindex/migrations/0042_recipe_pe_pr.py
Normal file
|
@ -0,0 +1,20 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.11.24 on 2019-09-24 21:34
|
||||
from __future__ import unicode_literals
|
||||
from django.db import migrations, models
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('layerindex', '0041_recipe_configopts'),
|
||||
]
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='recipe',
|
||||
name='pe',
|
||||
field=models.CharField(blank=True, max_length=100),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='recipe',
|
||||
name='pr',
|
||||
field=models.CharField(blank=True, max_length=100),
|
||||
),
|
||||
]
|
|
@ -461,6 +461,8 @@ class Recipe(models.Model):
|
|||
filepath = models.CharField(max_length=255, blank=True)
|
||||
pn = models.CharField(max_length=100, blank=True)
|
||||
pv = models.CharField(max_length=100, blank=True)
|
||||
pr = models.CharField(max_length=100, blank=True)
|
||||
pe = models.CharField(max_length=100, blank=True)
|
||||
summary = models.CharField(max_length=200, blank=True)
|
||||
description = models.TextField(blank=True)
|
||||
section = models.CharField(max_length=100, blank=True)
|
||||
|
|
|
@ -108,6 +108,8 @@ def update_recipe_file(tinfoil, data, path, recipe, layerdir_start, repodir, sto
|
|||
envdata.setVar('SRCPV', 'X')
|
||||
recipe.pn = envdata.getVar("PN", True)
|
||||
recipe.pv = envdata.getVar("PV", True)
|
||||
recipe.pr = envdata.getVar("PR", True) or ""
|
||||
recipe.pe = envdata.getVar("PE", True) or ""
|
||||
recipe.summary = envdata.getVar("SUMMARY", True)
|
||||
recipe.description = envdata.getVar("DESCRIPTION", True)
|
||||
recipe.section = envdata.getVar("SECTION", True)
|
||||
|
|
Loading…
Reference in New Issue
Block a user