Commit graph

22 commits

Author SHA1 Message Date
elij
2e444a79d5 remove mysql dependency from gendummydata
- remove need to use mysql for escaping the sql -- removing single quote
  should be enough
- instead of using sql to fetch categories from a live database, simply
  consider categories an integer range, specified to the size of that in the
  aur-schema.

Lukas: Add "CATEGORIES_COUNT" initialization. Fix random number range
used in genCategory() (AUTO_INCREMENT columns are 1-based by default,
not 0-based).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-04-12 11:56:32 +02:00
Lukas Fleischer
11366b8a1a gendummydata.py: Do not touch output file until we need it.
Ensures there's no leftover (empty) file if something during
initialization fails.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-03-30 10:27:23 +02:00
Dan McGee
abd41bbb51 Allow DB connection values to come from the environment
Stop hardcoding everything everywhere for those of us that don't use the
localhost/aur/aur/AUR setup. Also allow for the dummy data to be created
in the reload script if it does not exist. Finally, remove two
assumptions that the AUR database already exists.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-03-04 10:29:14 +01:00
Dan McGee
b9690972d0 Use a single transaction to write dummy data
This is immensely faster when using InnoDB since we don't need to sync
after each and every INSERT statement.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-03-04 10:29:13 +01:00
Lukas Fleischer
bc238965cb Fix some minor bugs in "support/schema/gendummydata.py".
The dummy data generation script used to create wrong package IDs for
both "PackageVotes" and "PackageDepends" tables which led to errors when
reloading the test data (constraints failed). This is fixed by no longer
creating entries with zero ("0") package IDs.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-27 19:46:30 +01:00
Lukas Fleischer
1e3fa38de5 Define "Packages.SubmitterUID" and "Packages.MaintainerUID" as "NULL".
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-27 19:46:19 +01:00
Lukas Fleischer
34ac351e82 Drop "PackageContents" table and references.
We don't even touch source tarballs anymore - except for extracting the
PKGBUILD, so this is no longer needed.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-01 15:16:29 +01:00
Dan McGee
7f5af61c88 Drop PackageLocations table and references
We don't need this anymore since all packages managed here are
well...managed here. Rip out all of the places we were using this field,
many of which depended on the magic value '2' anyway.

On the display side of things, we had a column that was always showing
'unsupported' that is now gone, and you can no longer sort by this column.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-01 12:41:08 +01:00
Lukas Fleischer
737268e0c2 Use "python2" shebang for "newpackage-notify" and "gendummydata.py".
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-01-24 18:12:05 +01:00
Lukas Fleischer
556de318ae Build URLs from package names (fixes FS#15308, FS#19327).
Drop the "URLPath" field from the "Packages" table, build URLs from
package names instead.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-01-24 18:08:29 +01:00
Callan Barrett
04dae8d94f Remove references to AURMaintainerUID
This (should) get rid of anything to do with the unused column AURMaintainerUID
in the scripts and schema files

Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com>
Signed-off-by: Simo Leone <simo@archlinux.org>
2008-03-27 02:34:35 -05:00
Loui Chang
e64307d8d2 Generate valid dummy data entries
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
Signed-off-by: Simo Leone <simo@archlinux.org>
2008-03-23 03:04:17 -05:00
eric
e3587ddf94 started working on pkgedit for comments 2005-03-06 21:44:56 +00:00
eric
aae43d9ad6 started working on package comments 2005-03-05 20:39:36 +00:00
eric
9641fdc735 fixed dummy-data, schema, gendummydata to use md5 passwords 2005-01-24 21:03:44 +00:00
eric
cbe2050420 started on the package submit script 2004-07-12 22:12:42 +00:00
eric
993fcb7811 still working on pkgsearch.php::do_Details 2004-07-01 22:20:09 +00:00
eric
761ddc3ddc yet another schema change 2004-06-29 21:22:31 +00:00
eric
4b80bc34ff re-working pkgsearch, NumVotes add to Packages table 2004-06-28 19:37:02 +00:00
eric
efcca46f26 working on action box for packages 2004-06-28 10:39:12 +00:00
eric
e7f806e43c improved dummy data, sorting works on package listing, still need Less/More buttons and package operations (details, manage, out-of-date) 2004-06-25 12:14:58 +00:00
eric
342d5dfce0 added dummy data for testing 2004-06-23 15:49:09 +00:00