1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
|
# Copyright 1998-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
from django.db import models
class Categories(models.Model):
CategoryId = models.IntegerField(primary_key=True, db_column='category_id')
Category = models.CharField(max_length=150, db_column='category')
Active = models.BooleanField(db_column='active')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'categories'
def __str__(self):
return '%s %s %s %s' % (self.CategoryId, self.Category, self.Active, self.TimeStamp)
class CategoriesMetadata(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
CategoryId = models.ForeignKey(Categories, db_column='category_id')
Checksum = models.CharField(max_length=100, db_column='checksum')
Descriptions = models.TextField(db_column='descriptions')
class Meta:
db_table = 'categories_metadata'
def __str__(self):
return '%s %s %s %s' % (self.Id, self.CategoryId, self.Checksum, self.Descriptions)
class Repos(models.Model):
RepoId = models.IntegerField(primary_key=True, db_column='repo_id')
Repo = models.CharField(max_length=100, db_column='repo')
class Meta:
db_table = 'repos'
def __str__(self):
return '%s %s' % (self.RepoId, self.Repo)
class Packages(models.Model):
PackageId = models.IntegerField(primary_key=True, db_column='package_id')
CategoryId = models.ForeignKey(Categories, db_column='category_id')
Package = models.CharField(max_length=150, db_column='package')
RepoId = models.ForeignKey(Repos, db_column='repo_id')
Active = models.BooleanField(db_column='active')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'packages'
def __str__(self):
return '%s %s %s %s %s %s' % (self.PackageId, self.CategoryId, self.Package, self.RepoId, self.Active, self.TimeStamp)
class PackagesMetadata(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
PackageId = models.ForeignKey(Packages, db_column='package_id')
Gitlog = models.TextField(db_column='gitlog')
Descriptions = models.TextField(db_column='descriptions')
class Meta:
db_table = 'packages_metadata'
def __str__(self):
return '%s %s %s %s' % (self.Id, self.PackageId, self.Gitlog, self.Descriptions)
class Ebuilds(models.Model):
EbuildId = models.IntegerField(primary_key=True, db_column='ebuild_id')
PackageId = models.ForeignKey(Packages, db_column='package_id')
Version = models.CharField(max_length=150, db_column='version')
Checksum = models.CharField(max_length=100, db_column='checksum')
Active = models.BooleanField(db_column='active')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'ebuilds'
def __str__(self):
return '%s %s %s %s %s %s' % (self.EbuildId, self.PackageId, self.Version, self.Checksum, self.Active, self.TimeStamp)
class EbuildsMetadata(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
EbuildId = models.ForeignKey(Ebuilds, db_column='ebuild_id')
Commit = models.CharField(max_length=30, db_column='commit')
New = models.BooleanField(db_column='new')
Descriptions = models.CharField(max_length=200, db_column='descriptions')
class Meta:
db_table = 'ebuilds_metadata'
def __str__(self):
return '%s %s %s %s %s' % (self.Id, self.EbuildId, self,Commit, self.New, self.Descriptions)
class BuildLogs(models.Model):
BuildLogId = models.IntegerField(primary_key=True, db_column='build_log_id')
EbuildId = models.ForeignKey(Ebuilds, db_column='ebuild_id')
Fail = models.BooleanField(db_column='fail')
SummeryText = models.TextField(db_column='summery_text')
LogHash = models.CharField(max_length=100, db_column='log_hash')
BugId = models.IntegerField( db_column='bug_id')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'build_logs'
def __str__(self):
return '%s %s %s %s %s %s %s' % (self.BuildLogId, self.EbuildId, self.Fail, self.SummeryText, self.LogHash, self.BugId, self.TimeStamp)
class BuildLogsRepoman(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
BuildLogId = models.ForeignKey(BuildLogs, db_column='build_log_id')
SummeryText = models.TextField(db_column='summery_text')
class Meta:
db_table = 'build_logs_repoman'
def __str__(self):
return '%s %s %s' % (self.Id, self.BuildLogId, self.SummeryText)
class BuildLogsQa(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
BuildLogId = models.ForeignKey(BuildLogs, db_column='build_log_id')
SummeryText = models.TextField(db_column='summery_text')
class Meta:
db_table = 'build_logs_qa'
def __str__(self):
return '%s %s %s' % (self.Id, self.BuildLogId, self.SummeryText)
class PackagesRepoman(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
PackageId = models.ForeignKey(Packages, db_column='package_id')
RepomanText = models.TextField(db_column='repoman_text')
RepomanHash = models.CharField(max_length=100, db_column='repoman_hash')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'packages_repoman'
def __str__(self):
return '%s %s %s %s %s' % (self.Id, self.PackageId, self.RepomanText, self.RepomanHash, self.TimeStamp)
class ErrorsInfo(models.Model):
ErrorId = models.IntegerField(primary_key=True, db_column='error_id')
ErrorName = models.CharField(max_length=20, db_column='error_name')
ErrorSearch = models.CharField(max_length=30, db_column='error_search')
class Meta:
db_table = 'errors_info'
def __str__(self):
return '%s %s %s' % (self.ErrorId, self.ErrorName, self.ErrorSearch)
class BuildLogsErrors(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
BuildLogId = models.ForeignKey(BuildLogs, db_column='build_log_id')
ErrorId = models.ForeignKey(ErrorsInfo, db_column='error_id')
class Meta:
db_table = 'build_logs_errors'
def __str__(self):
return '%s %s %s' % (self.Id, self.BuildLogId, self.ErrorId)
class EmergeInfo(models.Model):
EInfoId = models.IntegerField(primary_key=True, db_column='einfo_id')
EmergeInfoText = models.TextField(db_column='emerge_info_text')
class Meta:
db_table = 'emerge_info'
def __str__(self):
return '%s %s %s' % (self.EInfoId, self.Checksum, self.EmergeInfoText)
class Setups(models.Model):
SetupId = models.AutoField(primary_key=True, db_column='setup_id')
Setup = models.CharField(max_length=100, db_column='setup')
Profile = models.CharField(max_length=150, db_column='profile')
class Meta:
db_table = 'setups'
def __str__(self):
return '%s %s %s' % (self.SetupId, self.Setup, self.Profile)
class Configs(models.Model):
ConfigId = models.AutoField(primary_key=True, db_column='config_id')
HostName = models.CharField(max_length=150, db_column='hostname')
SetupId = models.ForeignKey(Setups, db_column='setup_id')
DefaultConfig = models.BooleanField(db_column='default_config')
class Meta:
db_table = 'configs'
def __str__(self):
return '%s %s %s %s' % (self.ConfigId, self.HostName, self.SetupId, self.DefaultConfig)
class BuildLogsConfig(models.Model):
LogId = models.IntegerField(primary_key=True, db_column='log_id')
BuildLogId = models.ForeignKey(BuildLogs, db_column='build_log_id')
ConfigId = models.ForeignKey(Configs, db_column='config_id')
EInfoId = models.ForeignKey(EmergeInfo, db_column='einfo_id')
LogName = models.CharField(max_length=450, db_column='logname')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'build_logs_config'
def __str__(self):
return '%s %s %s %s %s %s' % (self.LogId, self.BuildLogId, self.ConfigId, self.EInfoId, self.LogName, self.TimeStamp)
class EmergeOptions(models.Model):
EmergeOptionId = models.IntegerField(primary_key=True, db_column='eoption_id')
EOption = models.CharField(max_length=45, db_column='eoption')
class Meta:
db_table = 'emerge_options'
def __str__(self):
return '%s %s' % (self.EmergeOptionId, self.EOption)
class BuildLogsEmergeOptions(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
BuildLogId = models.ForeignKey(BuildLogs, db_column='build_log_id')
EmergeOptionId = models.ForeignKey(EmergeOptions, db_column='eoption_id')
class Meta:
db_table = 'build_logs_emerge_options'
def __str__(self):
return '%s %s %s' % (self.Id, self.BuildLogId, self.EmergeOptionId)
class Uses(models.Model):
UseId = models.IntegerField(primary_key=True, db_column='use_id')
Flag = models.CharField(max_length=150, db_column='flag')
class Meta:
db_table = 'uses'
def __str__(self):
return '%s %s' % (self.UseId, self.Flag)
class BuildLogsUse(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
BuildLogId = models.ForeignKey(BuildLogs, db_column='build_log_id')
UseId = models.ForeignKey(Uses, db_column='use_id')
Status = models.BooleanField(max_length=15, db_column='status')
class Meta:
db_table = 'build_logs_use'
def __str__(self):
return '%s %s %s' % (self.BuildLogId, self.UseId, self.Status)
class BuildJobs(models.Model):
BuildJobId = models.AutoField(primary_key=True, db_column='build_job_id')
EbuildId = models.ForeignKey(Ebuilds, db_column='ebuild_id')
SetupId = models.ForeignKey(Setups, db_column='setup_id')
ConfigId = models.ForeignKey(Configs, db_column='config_id')
Status = models.CharField(max_length=21, db_column='status')
BuildNow = models.BooleanField(db_column='build_now')
RemoveBin = models.BooleanField(db_column='removebin')
TimeStamp = models.DateTimeField(db_column='time_stamp')
class Meta:
db_table = 'build_jobs'
def __str__(self):
return '%s %s %s %s %s %s %s %s' % (self.BuildJobId, self.EbuildId, self.SetupId, self.ConfigId, self.Status, self.BuildNow, self.RemoveBin, self.TimeStamp)
class BuildJobsUse(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
BuildJobId = models.ForeignKey(BuildJobs, db_column='build_job_id')
UseId = models.ForeignKey(Uses, db_column='use_id')
Status = models.BooleanField(db_column='status')
class Meta:
db_table = 'build_jobs_use'
def __str__(self):
return '%s %s %s %s' % (self.Id, self.BuildJobId, self.UseId, self.Status)
class Keywords(models.Model):
KeywordId = models.IntegerField(primary_key=True, db_column='keyword_id')
Keyword = models.CharField(max_length=45, db_column='keyword')
class Meta:
db_table = 'keywords'
def __str__(self):
return '%s %s' % (self.KeywordId, self.Keyword)
class Restrictions(models.Model):
RestrictionId = models.IntegerField(primary_key=True, db_column='restriction_id')
Restriction = models.CharField(max_length=150, db_column='restriction')
class Meta:
db_table = 'restrictions'
def __str__(self):
return '%s %s' % (self.RestrictionId, self.Restriction)
class EbuildsKeywords(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
EbuildId = models.ForeignKey(Ebuilds, db_column='ebuild_id')
KeywordId = models.ForeignKey(Keywords, db_column='keyword_id')
Status = models.CharField(max_length=24, db_column='status')
class Meta:
db_table = 'ebuilds_keywords'
def __str__(self):
return '%s %s %s' % (self.EbuildId, self.KeywordId, self.Status)
class EbuildsIuse(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
EbuildId = models.ForeignKey(Ebuilds, db_column='ebuild_id')
UseId = models.ForeignKey(Uses, db_column='use_id')
Status =models.BooleanField(db_column='status')
class Meta:
db_table = 'ebuilds_iuse'
def __str__(self):
return '%s %s %s %s' % (self.Id, self.EbuildId, self.UseId, self.Status)
class EbuildsRestrictions(models.Model):
Id = models.IntegerField(primary_key=True, db_column='id')
EbuildId = models.ForeignKey(Ebuilds, db_column='ebuild_id')
RestrictionId = models.ForeignKey(Restrictions, db_column='restriction_id')
class Meta:
db_table = 'ebuilds_restrictions'
def __str__(self):
return '%s %s' % (self.EbuildId, self.RestrictionId)
|