Commit graph

1748 commits

Author SHA1 Message Date
Lukas Fleischer
c82fc025e2 Move package request form to a template
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 21:34:39 +02:00
Lukas Fleischer
409d1c3ffd Allow regular users to file package requests
Move the permission check so that regular users can file requests,
whereas the request list is only available to Trusted Users and
developers.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 21:31:18 +02:00
Lukas Fleischer
65129ce9c3 Make results consistent in RPC replies
Add RPC v3 which always returns a list of objects in RPC responses,
regardless of the request type. An empty list is returned when an error
occurs. The error message is moved to a separate "error" field.

Fixes FS#40963.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 12:10:15 +02:00
Lukas Fleischer
91e6b5cb2f Add support for merge requests
This adds a new "Merge" category to the list of available request types
and also adds a new "Merge into" field that is hidden via JavaScript
when "Deletion" or "Orphan" is selected.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:38:02 +02:00
Lukas Fleischer
959c61a77d Add an accept button to the package request list
This button allows for accepting a request, disowning the affected
package or redirecting to the package deletion page. The request is
closed automatically when the action has been performed.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:36:15 +02:00
Lukas Fleischer
d8dbad0c3e Highlight package requests after 14 days
Automatically highlight package requests after a configurable period of
time. Defaults to 14 days.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:35:42 +02:00
Lukas Fleischer
fc1db28c9b Allow for closing package requests
This allows Trusted Users to close package requests via the request
list. Also, entries are now sorted such that open requests are shown
before closed requests.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:34:31 +02:00
Lukas Fleischer
8260111bcc Add a package request list
Introduce a new navigation point "Requests" that shows a list of pending
package requests. This functionality is only available to Trusted Users.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:33:29 +02:00
Lukas Fleischer
48cc8207bf Add support for filing package requests
Add a new entry to the package actions box that allows for filing
deletion and orphan requests. When choosing that action, the user is
redirected to a new page that allows for selecting a request type and
entering a comment. When submitting the request, a new entry in the
request database is created and an email is sent to a configurable
mailing list (defaults to aur-general).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:31:11 +02:00
Lukas Fleischer
e82a2b80e5 Update message catalog
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-22 12:13:53 +02:00
Lukas Fleischer
43f5167f75 Fix latest_pkgs() again
In 4cd6841 (pkgfuncs.inc.php: Fix latest_pkgs(), 2014-05-29),
latest_pkgs() was modified to work with the new database layout.
However, since all columns were selected, package names have been
overwritten by package base names since that change. Qualify the
*-shorthand to avoid this.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-07 05:24:11 +02:00
Lukas Fleischer
e37a49d726 Release 3.1.0
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:22:23 +02:00
Lukas Fleischer
fa2fe22019 Translation updates from Transifex
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:16:34 +02:00
Lukas Fleischer
5463bdeff6 acctfuncs.inc.php: Fix indentation
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:16:34 +02:00
Lukas Fleischer
1aec9f7124 acctfuncs.inc.php: Reduce nesting in several functions
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
0a66f48aa1 Do not return "None" in user functions
Return null instead of the string "None" in username_from_id(),
uid_from_email() and uid_from_username().

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
7a5bfd83c4 Increase the size of several database fields
Several fields turned out to be too small (e.g. when long package
versions are used in VCS packages). Since the type of all affected
fields is VARCHAR, there is no reason to keep them as small as possible.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
9b5271d737 Display versioned conflicts/provides/replaces
Show the specific conflicts/provides/replaces versions in the web
interface.

Implements FS#40699.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
26a0919937 Fix SQL query when searching for a missing submitter
uid_from_username() returns a non-integer value when the user does not
exist. This results in a broken SQL query when searching for a
nonexistent submitter. Fix this by explicitly converting the result of
uid_from_username() to an integer.

Fixes FS#40625.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
b1c754300a Fix links to AUR packages in optional dependencies
Extend the SQL query that tries to find a package's dependencies so that
optional dependencies with a description are correctly resolved.

Fixes FS#40700.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
13820d2b16 Collapse long source lists
In commit e582cfe (Collapse long dependency lists, 2014-04-18), we added
code to automatically collapse dependency and requirement lists with
more than 20 entries. Add the same functionality to source lists.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-05 15:12:10 +02:00
Lukas Fleischer
b30bb6f534 Merge branch 'maint' 2014-06-02 18:15:26 +02:00
Lukas Fleischer
019014a3ac Add a "Search wiki" link to package details
Implements FS#33153.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-02 18:15:12 +02:00
Lukas Fleischer
d909ffcb17 aurjson: Add a PackageBaseID field
This is useful to tools that automatically generate requests to orphan,
delete or merge packages.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-31 11:45:00 +02:00
Lukas Fleischer
e018670607 Accept upper case letters in valid_username()
In commit 0722f46 (Simplify valid_user() and valid_username(),
2014-02-06), the conversion to lower case letters was unintentionally
removed and in consequence, names with upper case letters have been
rejected since then.

Instead of reintroducing the conversion, add the "i" modifier to the
regular expression validating the name to do case-insensitive pattern
matching.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-30 09:32:48 +02:00
Lukas Fleischer
4cd6841541 pkgfuncs.inc.php: Fix latest_pkgs()
This fixes a regression introduced when adding split package support and
makes the RSS feed work again.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-29 21:19:06 +02:00
Lukas Fleischer
44268778c8 Move latest_pkgs() to pkgfuncs.inc.php
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-29 21:13:45 +02:00
Lukas Fleischer
86de2e5628 Release 3.0.0 2014-05-27 20:19:38 +02:00
Lukas Fleischer
38d4f723e9 Translation updates from Transifex
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-27 15:55:33 +02:00
Lukas Fleischer
b26b5bba47 UPGRADING: Create foreign key after modifying column
We cannot change a column after creating a foreign key:

    ERROR 1832 (HY000): Cannot change column 'PackageBaseID': used in a
    foreign key constraint 'Packages_ibfk_1'

Delay the "ADD FOREIGN KEY" command to fix this.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-27 15:34:56 +02:00
Lukas Fleischer
e5463c962c UPGRADING: Add missing column to the instructions
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-27 15:28:07 +02:00
Lukas Fleischer
d7f0b25e51 acctfuncs.inc.php: Fix typo
Replace a misplaced semicolon with the concatenation operator. This
makes the AUR insert proper Reply-to and From headers again when sending
password reset emails on registration.

Fixes a regression introduced in 94a4f59 (Set Content-type header when
sending UTF-8 mails, 2014-02-10).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-22 21:08:47 +02:00
Lukas Fleischer
d962d66d63 Add title attribute to links in updates table
As of commit ea25f98 (Avoid overflow in updates table, 2014-05-22), long
package names in the updates statistics are chopped off. Add a title
attribute so that users at least get a tooltip with the full package
name and version.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-22 20:47:32 +02:00
Lukas Fleischer
42461cc78e Release 3.0.0-rc4
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-22 20:42:05 +02:00
Lukas Fleischer
ea25f982dc Avoid overflow in updates table
Fixes FS#40206.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-22 16:01:16 +02:00
Lukas Fleischer
839bff3761 Use aur.archlinux.org in sender email addresses
Consistently use the following headers in notification emails:

    Reply-to: noreply@aur.archlinux.org
    From: notify@aur.achlinux.org

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-22 15:43:41 +02:00
Lukas Fleischer
02e7df7631 Be friendly to newly registered users
Use "Welcome to the Arch User Repository" instead of "AUR Password
Reset" as subject for the initial password reset email.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-22 15:43:41 +02:00
Lukas Fleischer
d062634ce2 Release v3.0.0-rc3
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-20 22:02:04 +02:00
Lukas Fleischer
6cbcff1ad7 Translation updates from Transifex
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-20 22:01:37 +02:00
Thomas Weißschuh
8658bf22aa Add threading headers to notification mail
It is only basic, but works in this way for other platforms.
It works because MUAs are able to reconstruct threads originating from mails
they don't know about (unknown Message-ID).

This has some drawbacks:
* MUAs might show the missing start of the thread. As a normal user of a
  package never got *all* notifications of a package anyways it only reflects
  the reality
* Missing notifications go unnoticed. This is no regression so it should be
  fine

Those could be fixed by including all previous comments in 'References:',
which would require to have predictable 'Message-ID:' for notification mails.
This would require more code and more database accesses at runtime.

Could also be used for out of date notifications.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-20 21:58:36 +02:00
Lukas Fleischer
cf6470803e aurjson: Fix multiinfo when using package IDs
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-18 12:19:29 +02:00
Lukas Fleischer
bc93e68dc7 Set language using a POST request
Fixes FS#39027.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-13 14:19:55 +02:00
Lukas Fleischer
33bdc023d6 Release 3.0.0-rc2
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-07 11:12:39 +02:00
Lukas Fleischer
d886ca825b Update message catalog
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-07 11:11:55 +02:00
Lukas Fleischer
0dd062bf07 Exclude config.inc.php from POTFILES
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-07 11:11:16 +02:00
Lukas Fleischer
ba30743398 Check permissions when uploading source packages
All files contained in the source tarball must have permissions of 644
or 755. All directories must have permissions of 755.

Implements FS#27754.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-06 21:24:56 +02:00
Lukas Fleischer
ac09e669c7 pkgsubmit.php: Style fixes
Move some elseif statements to the same line as the closing brace.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-06 21:16:31 +02:00
Lukas Fleischer
97df70daec pkgbuild-parser.inc.php: Remove stray "#"
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-06 21:13:20 +02:00
Lukas Fleischer
a93363ac08 Add a packager field to packages
Store the last packager in addition to storing the submitter and the
maintainer of a package. This allows for checking who last updated a
package, even if the package has been disowned.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-06 20:52:32 +02:00
Lukas Fleischer
0e368510f4 Update POTFILES and message catalog
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-04 23:55:27 +02:00