[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[commit-womb] gnumaint/fsd gnufsd-psql
From: |
Kaloian Doganov |
Subject: |
[commit-womb] gnumaint/fsd gnufsd-psql |
Date: |
Thu, 04 Jun 2009 10:45:24 +0000 |
CVSROOT: /sources/womb
Module name: gnumaint
Changes by: Kaloian Doganov <kaloian> 09/06/04 10:45:24
Modified files:
fsd : gnufsd-psql
Log message:
Better adherence to the GNU Coding Standards.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnumaint/fsd/gnufsd-psql?cvsroot=womb&r1=1.3&r2=1.4
Patches:
Index: gnufsd-psql
===================================================================
RCS file: /sources/womb/gnumaint/fsd/gnufsd-psql,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- gnufsd-psql 4 Jun 2009 10:44:26 -0000 1.3
+++ gnufsd-psql 4 Jun 2009 10:45:24 -0000 1.4
@@ -1,5 +1,5 @@
#!/usr/bin/env perl
-# $Id: gnufsd-psql,v 1.3 2009/06/04 10:44:26 kaloian Exp $
+# $Id: gnufsd-psql,v 1.4 2009/06/04 10:45:24 kaloian Exp $
# Extract information about GNU packages from the Free Software
# Directory's PostgreSQL database.
#
@@ -141,21 +141,21 @@
}
# Fetch all rows resulted from a SELECT statement.
-sub all($)
+sub all ($)
{
my ($sql) = @_;
return trim_whitespace ($dbh->selectall_arrayref ($sql, {Slice=>{}}));
}
# Fetch one row resulted from a SELECT statement.
-sub row($)
+sub row ($)
{
my ($sql) = @_;
return trim_whitespace ($dbh->selectrow_hashref ($sql));
}
# Fetch all values in one COLUMN resulted from a SELECT statement.
-sub all_col($$)
+sub all_col ($$)
{
my ($sql, $col) = @_;
my @result;
@@ -168,7 +168,7 @@
# Fetch one COLUMN from the first row resulted from a SELECT
# statement.
-sub col($$)
+sub col ($$)
{
my ($sql, $col) = @_;
my $value = row ($sql);
@@ -176,7 +176,7 @@
}
# Fetch all GNU projects.
-sub projects()
+sub projects ()
{
return all ("SELECT id, name, slug, user_level, short_description,
full_description, entry_compiled_by, updated,
@@ -187,7 +187,7 @@
# Return mundane-name for a project. Returns an empty string if the
# `mundane-name' field should be ommited for this project.
-sub mundane_name(\%)
+sub mundane_name (\%)
{
my ($project) = @_;
my $slug = $project->{"slug"};
@@ -202,7 +202,7 @@
# Fetch homepage (if any) for a project. Returns an empty string if
# the `homepage' field should be omitted for this project.
-sub homepage(\%)
+sub homepage (\%)
{
my ($project) = @_;
my $id = $project->{"id"};
@@ -223,7 +223,7 @@
# Fetch download-url (if any) for a project. Returns an empty string
# if the `download-url' field should be omitted for this project.
-sub download_url(\%)
+sub download_url (\%)
{
my ($project) = @_;
my $id = $project->{"id"};
@@ -242,7 +242,7 @@
}
# Converts SQL ISO date format (YYYY-MM-DD) to Date::Calc YMD.
-sub iso_date_to_ymd($)
+sub iso_date_to_ymd ($)
{
my ($iso_date) = @_;
my ($year, $month, $day) = split (/-/, $iso_date);
@@ -251,14 +251,14 @@
}
# Converts Date::Calc YMD to string.
-sub iso_date_to_str($) {
+sub iso_date_to_str ($) {
my ($date) = @_;
$date =~ s/-//g;
return $date;
}
# Fetch activity-status for a project.
-sub activity_status(\%)
+sub activity_status (\%)
{
my ($project) = @_;
my $id = $project->{"id"};
@@ -297,7 +297,7 @@
}
# Formats a category_id to be suitable for dumping.
-sub format_category($)
+sub format_category ($)
{
my ($id) = @_;
my @name_chain;
@@ -317,7 +317,7 @@
}
# Fetch categories for a project.
-sub categories(\%)
+sub categories (\%)
{
my ($project) = @_;
my $id = $project->{"id"};
@@ -357,7 +357,7 @@
}
# Formats long muliparagraph text to be suitable for dumping.
-sub format_full_descr($)
+sub format_full_descr ($)
{
my ($descr) = @_;
my $out = fmt ($descr);
@@ -367,7 +367,7 @@
}
# Fetch licenses for a project version.
-sub licenses(\%)
+sub licenses (\%)
{
my ($version) = @_;
my $id = $version->{"id"};
@@ -376,7 +376,7 @@
}
# Fetch interfaces for a project version.
-sub interfaces(\%)
+sub interfaces (\%)
{
my ($version) = @_;
my $id = $version->{"id"};
@@ -385,7 +385,7 @@
}
# Fetch versions for a project.
-sub versions(\%)
+sub versions (\%)
{
my ($project) = @_;
my $id = $project->{"id"};
@@ -394,7 +394,7 @@
}
# Dump a version.
-sub version(\%)
+sub version (\%)
{
my ($version) = @_;
my $name = $version->{"name"};
@@ -420,7 +420,7 @@
}
# Dump a project to STDOUT.
-sub project(\%)
+sub project (\%)
{
my ($project) = @_;
my $id = $project->{"id"};
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/04
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/04
- [commit-womb] gnumaint/fsd gnufsd-psql,
Kaloian Doganov <=
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/04
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/06
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/06
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/06
- [commit-womb] gnumaint/fsd gnufsd-psql, Kaloian Doganov, 2009/06/06