summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'versioncp')
-rwxr-xr-xversioncp/commontest24
-rw-r--r--versioncp/dump.sql21
-rw-r--r--versioncp/main.css47
-rw-r--r--versioncp/show_versions.php312
-rw-r--r--versioncp/svnupdater96
-rw-r--r--versioncp/update_versions.php494
-rwxr-xr-xversioncp/upstscripts/berlios16
-rwxr-xr-xversioncp/upstscripts/ezcomponents17
-rwxr-xr-xversioncp/upstscripts/freshmeat14
-rwxr-xr-xversioncp/upstscripts/php-pear17
-rwxr-xr-xversioncp/upstscripts/php-pecl19
-rwxr-xr-xversioncp/upstscripts/sourceforge16
12 files changed, 0 insertions, 1093 deletions
diff --git a/versioncp/commontest b/versioncp/commontest
deleted file mode 100755
index 78c4f1f..0000000
--- a/versioncp/commontest
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/bash
-
-echo "Trying the most common places for a package to be ..."
-
-# Try them ...
-pwd="`pwd`"
-sfvers="`${pwd}/upstscripts/sourceforge $1`"
-fmvers="`${pwd}/upstscripts/freshmeat $1`"
-bevers="`${pwd}/upstscripts/berlios $1`"
-
-if [[ -n "${sfvers}" ]] ; then
- echo "Package $1 found on SourceForge with version ${sfvers}"
-fi
-
-if [[ -n "${fmvers}" ]] ; then
- echo "Package $1 found on FreshMeat with version ${fmvers}"
-fi
-if [[ -n "${bevers}" ]] ; then
- echo "Package $1 found on Berlios with version ${bevers}"
-fi
-
-if [[ -z "${sfvers}" ]] && [[ -z "${fmvers}" ]] && [[ -z "${bevers}" ]] ; then
- echo "Not found anywhere ..."
-fi
diff --git a/versioncp/dump.sql b/versioncp/dump.sql
deleted file mode 100644
index e46b931..0000000
--- a/versioncp/dump.sql
+++ /dev/null
@@ -1,21 +0,0 @@
-DROP TABLE IF EXISTS `overlays`;
-
-CREATE TABLE `overlays`
-(
- `overname` VARCHAR(255) default '' NOT NULL,
- `overtype` VARCHAR(255) default '' NOT NULL,
- `overbranch` VARCHAR(255) default '' NOT NULL
-) Type=MyISAM;
-
-DROP TABLE IF EXISTS `packages`;
-
-CREATE TABLE `packages`
-(
- `name` VARCHAR(255) default '' NOT NULL,
- `versover` VARCHAR(255) default '' NOT NULL,
- `versport` VARCHAR(255) default '' NOT NULL,
- `versupst` VARCHAR(255) default '' NOT NULL,
- `upstscript` VARCHAR(255) default '' NOT NULL,
- `projtype` VARCHAR(255) default '' NOT NULL,
- `projname` VARCHAR(255) default '' NOT NULL
-) Type=MyISAM;
diff --git a/versioncp/main.css b/versioncp/main.css
deleted file mode 100644
index eb832d6..0000000
--- a/versioncp/main.css
+++ /dev/null
@@ -1,47 +0,0 @@
-.updated {
- background-color : #18EF18;
- border-color : #B7B7B7;
- border-style : solid;
- border-width : 1px;
- text-align : center;
-}
-
-.outdated {
- background-color : #F81C1C;
- border-color : #B7B7B7;
- border-style : solid;
- border-width : 1px;
- text-align : center;
-}
-
-.reference {
- background-color : #F2F3F6;
- border-color : #B7B7B7;
- border-style : solid;
- border-width : 1px;
- text-align : center;
-}
-
-.package {
- background-color : #EBECF5;
- border-color : #B7B7B7;
- border-style : solid;
- border-width : 1px;
- text-align : left;
-}
-
-.deadinfo {
- background-color : #312E2E;
- border-color : #B7B7B7;
- border-style : solid;
- border-width : 1px;
- text-align : center;
-}
-
-.brokenupst {
- background-color : #4D4A4A;
- border-color : #B7B7B7;
- border-style : solid;
- border-width : 1px;
- text-align : center;
-}
diff --git a/versioncp/show_versions.php b/versioncp/show_versions.php
deleted file mode 100644
index 325d32b..0000000
--- a/versioncp/show_versions.php
+++ /dev/null
@@ -1,312 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <meta content="text/html; charset=UTF-8" http-equiv="content-type" />
- <link rel="stylesheet" href="main.css" type="text/css" />
- <title>Version Displayer</title>
-</head>
-<body style="margin: 0; padding: 0;">
-<?php
-
-# == Settings ==
-
-$dbuser = 'root';
-$dbpass = 'root';
-$dbname = 'versioncp';
-
-# == End Settings ==
-# Connect to the database
-
-$db = mysql_connect(':/var/run/mysqld/mysqld.sock', $dbuser, $dbpass);
-mysql_select_db($dbname, $db);
-
-# Check that a type is set
-
-if(isset($_GET['type'])
- && $_GET['type'] != ''
- && ($_GET['type'] === 'proj' || $_GET['type'] === 'dev'))
-{
- echo '<br />' . "\n";
- echo '<p align="center"> Type: <b>' . $_GET['type'] . '</b> </p><br />' . "\n";
-}
-else
-{
- echo 'Please select which type of data you want to see.<br />' . "\n";
- echo 'Supported are "proj" and "dev" types, for the two<br />' . "\n";
- echo 'categories of overlays that we support.<br />' . "\n";
- echo '<br />' . "\n";
- echo '<form method="get" action="show_versions.php">' . "\n";
- echo '<select name="type">' . "\n";
- echo ' <option>proj</option>' . "\n";
- echo ' <option>dev</option>' . "\n";
- echo '</select>' . "\n";
- echo '<input type="submit" value="OK" />' . "\n";
- echo '</form>' . "\n";
- echo '</body>' . "\n";
- echo '</html>' . "\n";
- exit;
-}
-
-# Check that a name is set
-
-if(isset($_GET['name'])
- && $_GET['name'] != '')
-{
- $names_db = mysql_query('SELECT `overname` FROM `overlays` WHERE `overtype`= "' . $_GET['type'] . '"', $db);
-
- while($names = mysql_fetch_array($names_db))
- {
- if($_GET['name'] === $names['overname'])
- {
- echo '<p align="center"> Name: <b>' . $_GET['name'] . '</b> </p><br />' . "\n";
- $exitinvalid = '0';
- break;
- }
- else
- {
- $exitinvalid = '1';
- }
- }
-
- if($exitinvalid === '1')
- {
- echo 'Invalid name supplied!<br />' . "\n";
- echo '</body>' . "\n";
- echo '</html>' . "\n";
- exit;
- }
-}
-else
-{
- $names_db = mysql_query('SELECT `overname` FROM `overlays` WHERE `overtype`= "' . $_GET['type'] . '"', $db);
- echo 'Please select the name of the data you want to see.<br />' . "\n";
- echo '<br />' . "\n";
- echo '<form method="get" action="show_versions.php">' . "\n";
- echo '<input type="hidden" name="type" value="' . $_GET['type'] . '" />' . "\n";
- echo '<select name="name">' . "\n";
-
- while($names = mysql_fetch_array($names_db))
- {
- $namesarray[$names['overname']] = $names['overname'];
- }
-
- foreach($namesarray as $namename)
- {
- echo ' <option>' . $namename . '</option>' . "\n";
- }
-
- echo '</select>' . "\n";
- echo '<input type="submit" value="OK" />' . "\n";
- echo '</form>' . "\n";
- echo '</body>' . "\n";
- echo '</html>' . "\n";
- exit;
-}
-
-?>
-<table cellpadding="5" cellspacing="5" border="0" align="center">
-<tr>
- <td class="package"> Package Name </td>
- <td class="package"> Latest in Portage </td>
- <td class="package"> Latest in Overlay </td>
- <td class="package"> Latest Upstream </td>
-</tr>
-<?php
-
-# Get the packages data, and display it
-
-$pkgs_db = mysql_query('SELECT `name`,`versport`,`versover`,`versupst`,`upstscript` FROM `packages` WHERE `projtype` = "' . $_GET['type'] . '" AND `projname` = "' . $_GET['name'] . '" ORDER BY `name` ASC', $db);
-
-while($pkgs = mysql_fetch_array($pkgs_db))
-{
- # Let's reset the color data
-
- if($pkgs['upstscript'] != ''
- && $pkgs['versupst'] == '-')
- {
- $upstclass = ' class="brokenupst" title="broken upstream script ( ' . $pkgs['upstscript'] . ' )"';
- }
- else
- {
- $upstclass = ' class="reference" title="no upstream script defined"';
- }
-
- $overclass = ' class="reference"';
- $portclass = ' class="reference"';
-
- # Case 1: A def, B def, C def - A > B > C compare
-
- if($pkgs['versport'] != '-'
- && $pkgs['versover'] != '-'
- && $pkgs['versupst'] != '-')
- {
- # Let's consider upstream as being the reference here, so always up-to-date
-
- $upstclass = ' class="updated" title="from upstream script ( ' . $pkgs['upstscript'] . ' )"';
-
- # First let's check the upstream <-> overlay relation
-
- switch(version_compare($pkgs['versupst'], $pkgs['versover']))
- {
- case '-1':
- $overclass = ' class="updated"';
- break;
- case '0':
- $overclass = ' class="updated"';
- break;
- case '1':
- $overclass = ' class="outdated"';
- break;
- }
-
- # Then let's check the overlay <-> portage relation
-
- switch(version_compare($pkgs['versover'], $pkgs['versport']))
- {
- case '-1':
- $portclass = ' class="updated"';
- break;
- case '0':
- $portclass = ' class="updated"';
- break;
- case '1':
- $portclass = ' class="outdated"';
- break;
- }
- }
-
- # Case 2: A def, B undef, C undef - A
-
- if($pkgs['versport'] != '-'
- && $pkgs['versover'] == '-'
- && $pkgs['versupst'] == '-')
- {
- # Only in Portage, so it's automatically ok
-
- $portclass = ' class="updated"';
- }
-
- # Case 3: A def, B def, C undef - A > B compare
-
- if($pkgs['versport'] != '-'
- && $pkgs['versover'] != '-'
- && $pkgs['versupst'] == '-')
- {
- # Let's check the overlay <-> portage relation
-
- switch(version_compare($pkgs['versover'], $pkgs['versport']))
- {
- case '-1':
- $overclass = ' class="outdated"';
- $portclass = ' class="updated"';
- break;
- case '0':
- $overclass = ' class="updated"';
- $portclass = ' class="updated"';
- break;
- case '1':
- $overclass = ' class="updated"';
- $portclass = ' class="outdated"';
- break;
- }
- }
-
- # Case 4: A def, B undef, C def - A > C compare
-
- if($pkgs['versport'] != '-'
- && $pkgs['versover'] == '-'
- && $pkgs['versupst'] != '-')
- {
- # Let's consider upstream as being the reference here, so always up-to-date
-
- $upstclass = ' class="updated" title="from upstream script ( ' . $pkgs['upstscript'] . ' )"';
-
- # Let's check the upstream <-> portage relation
-
- switch(version_compare($pkgs['versupst'], $pkgs['versport']))
- {
- case '-1':
- $portclass = ' class="updated"';
- break;
- case '0':
- $portclass = ' class="updated"';
- break;
- case '1':
- $portclass = ' class="outdated"';
- break;
- }
- }
-
- # Case 5: A undef, B undef, C undef - nothing
-
- if($pkgs['versport'] == '-'
- && $pkgs['versover'] == '-'
- && $pkgs['versupst'] == '-')
- {
- # We have absolutely no info on this package, mark as dead
-
- $upstclass = ' class="deadinfo" title="no info available on this package at all"';
- $overclass = ' class="deadinfo" title="no info available on this package at all"';
- $portclass = ' class="deadinfo" title="no info available on this package at all"';
- }
-
- # Case 6: A undef, B def, C def - B > C compare
-
- if($pkgs['versport'] == '-'
- && $pkgs['versover'] != '-'
- && $pkgs['versupst'] != '-')
- {
- # Let's consider upstream as being the reference here, so always up-to-date
-
- $upstclass = ' class="updated" title="from upstream script ( ' . $pkgs['upstscript'] . ' )"';
-
- # Let's check the upstream <-> overlay relation
-
- switch(version_compare($pkgs['versupst'], $pkgs['versover']))
- {
- case '-1':
- $overclass = ' class="updated"';
- break;
- case '0':
- $overclass = ' class="updated"';
- break;
- case '1':
- $overclass = ' class="outdated"';
- break;
- }
- }
-
- # Case 7: A undef, B undef, C def - C
-
- if($pkgs['versport'] == '-'
- && $pkgs['versover'] == '-'
- && $pkgs['versupst'] != '-')
- {
- # Only Upstream, so it's automatically ok
-
- $upstclass = ' class="updated" title="from upstream script ( ' . $pkgs['upstscript'] . ' )"';
- }
-
- # Case 8: A undef, B def, C undef - B
-
- if($pkgs['versport'] == '-'
- && $pkgs['versover'] != '-'
- && $pkgs['versupst'] == '-')
- {
- # Only in Overlay, so it's automatically ok
-
- $overclass = ' class="updated"';
- }
-
- echo '<tr>' . "\n";
- echo ' <td class="package"> ' . $pkgs['name'] . ' </td>' . "\n";
- echo ' <td' . $portclass . '> ' . $pkgs['versport'] . ' </td>' . "\n";
- echo ' <td' . $overclass . '> ' . $pkgs['versover'] . ' </td>' . "\n";
- echo ' <td' . $upstclass . '> ' . $pkgs['versupst'] . ' </td>' . "\n";
- echo '</tr>' . "\n";
-}
-
-?>
-</table>
-</body>
-</html> \ No newline at end of file
diff --git a/versioncp/svnupdater b/versioncp/svnupdater
deleted file mode 100644
index d82479c..0000000
--- a/versioncp/svnupdater
+++ /dev/null
@@ -1,96 +0,0 @@
-#!/bin/bash
-
-overlayname="gentoo-php-overlay"
-listofpkgs="app-admin/php-toolkit app-doc/php-docs dev-db/freetds dev-lang/php dev-php dev-php4 dev-php5"
-listofeclasses="confutils.eclass depend.php.eclass php*.eclass"
-echo "Starting with ${overlayname} ..."
-
-cd /svnupdaters/${overlayname}/svnoverlay/portage/ && svn up
-
-for pkg in ${listofpkgs} ; do
- mkdir -p /svnupdaters/${overlayname}/portage-new/${pkg}/
- cp -Rf /usr/portage/${pkg}/* /svnupdaters/${overlayname}/portage-new/${pkg}/
-done
-
-for eclass in ${listofeclasses} ; do
- mkdir -p /svnupdaters/${overlayname}/portage-new/eclass/
- cp -Rf /usr/portage/eclass/${eclass} /svnupdaters/${overlayname}/portage-new/eclass/
-done
-
-find /svnupdaters/${overlayname}/svnoverlay/portage/ -type f -print > /svnupdaters/${overlayname}/old
-find /svnupdaters/${overlayname}/svnoverlay/portage/ -type d -print > /svnupdaters/${overlayname}/old-dirs
-find /svnupdaters/${overlayname}/portage-new/ -type f -print > /svnupdaters/${overlayname}/new
-find /svnupdaters/${overlayname}/portage-new/ -type d -print > /svnupdaters/${overlayname}/new-dirs
-
-sed -e "s|.*/.svn/.*||g" -i /svnupdaters/${overlayname}/old
-sed -e "s|.*/.svn.*||g" -i /svnupdaters/${overlayname}/old-dirs
-sed -e "s|^/svnupdaters/${overlayname}/svnoverlay/portage/||g" -i /svnupdaters/${overlayname}/old
-sed -e "s|^/svnupdaters/${overlayname}/svnoverlay/portage/||g" -i /svnupdaters/${overlayname}/old-dirs
-cat /svnupdaters/${overlayname}/old | sort | uniq > /svnupdaters/${overlayname}/old-fixed
-cat /svnupdaters/${overlayname}/old-dirs | sort | uniq > /svnupdaters/${overlayname}/old-fixed-dirs
-sed -e "s|^/svnupdaters/${overlayname}/portage-new/||g" -i /svnupdaters/${overlayname}/new
-sed -e "s|^/svnupdaters/${overlayname}/portage-new/||g" -i /svnupdaters/${overlayname}/new-dirs
-cat /svnupdaters/${overlayname}/new | sort | uniq > /svnupdaters/${overlayname}/new-fixed
-cat /svnupdaters/${overlayname}/new-dirs | sort | uniq > /svnupdaters/${overlayname}/new-fixed-dirs
-
-diff -au /svnupdaters/${overlayname}/old-fixed /svnupdaters/${overlayname}/new-fixed > /svnupdaters/${overlayname}/diff
-diff -au /svnupdaters/${overlayname}/old-fixed-dirs /svnupdaters/${overlayname}/new-fixed-dirs > /svnupdaters/${overlayname}/diff-dirs
-
-sed -e "s|^---.*||" -i /svnupdaters/${overlayname}/diff
-sed -e "s|^+++.*||" -i /svnupdaters/${overlayname}/diff
-sed -e "s|^---.*||" -i /svnupdaters/${overlayname}/diff-dirs
-sed -e "s|^+++.*||" -i /svnupdaters/${overlayname}/diff-dirs
-
-grep -i "^-" /svnupdaters/${overlayname}/diff > /svnupdaters/${overlayname}/pkgdel
-grep -i "^+" /svnupdaters/${overlayname}/diff > /svnupdaters/${overlayname}/pkgadd
-grep -i "^-" /svnupdaters/${overlayname}/diff-dirs > /svnupdaters/${overlayname}/pkgdel-dirs
-grep -i "^+" /svnupdaters/${overlayname}/diff-dirs > /svnupdaters/${overlayname}/pkgadd-dirs
-
-sed -e "s|^-||g" -i /svnupdaters/${overlayname}/pkgdel
-sed -e '/^$/d' -i /svnupdaters/${overlayname}/pkgdel
-sed -e "s|^+||g" -i /svnupdaters/${overlayname}/pkgadd
-sed -e '/^$/d' -i /svnupdaters/${overlayname}/pkgadd
-sed -e "s|^-||g" -i /svnupdaters/${overlayname}/pkgdel-dirs
-sed -e '/^$/d' -i /svnupdaters/${overlayname}/pkgdel-dirs
-sed -e "s|^+||g" -i /svnupdaters/${overlayname}/pkgadd-dirs
-sed -e '/^$/d' -i /svnupdaters/${overlayname}/pkgadd-dirs
-
-cp -Rf /svnupdaters/${overlayname}/portage-new/* /svnupdaters/${overlayname}/svnoverlay/portage/
-
-cd /svnupdaters/${overlayname}/svnoverlay/portage/
-
-while read line ; do
- svn del ${line}
-done < /svnupdaters/${overlayname}/pkgdel
-
-while read line ; do
- svn del ${line}
-done < /svnupdaters/${overlayname}/pkgdel-dirs
-
-while read line ; do
- svn add ${line}
-done < /svnupdaters/${overlayname}/pkgadd-dirs
-
-while read line ; do
- svn add ${line}
-done < /svnupdaters/${overlayname}/pkgadd
-
-svn commit -m 'Automatic SVN update of portage/ branch.'
-
-rm -f /svnupdaters/${overlayname}/old
-rm -f /svnupdaters/${overlayname}/old-fixed
-rm -f /svnupdaters/${overlayname}/new
-rm -f /svnupdaters/${overlayname}/new-fixed
-rm -f /svnupdaters/${overlayname}/diff
-rm -f /svnupdaters/${overlayname}/pkgdel
-rm -f /svnupdaters/${overlayname}/pkgadd
-rm -f /svnupdaters/${overlayname}/old-dirs
-rm -f /svnupdaters/${overlayname}/old-fixed-dirs
-rm -f /svnupdaters/${overlayname}/new-dirs
-rm -f /svnupdaters/${overlayname}/new-fixed-dirs
-rm -f /svnupdaters/${overlayname}/diff-dirs
-rm -f /svnupdaters/${overlayname}/pkgdel-dirs
-rm -f /svnupdaters/${overlayname}/pkgadd-dirs
-rm -Rf /svnupdaters/${overlayname}/portage-new/*
-
-echo "Run completed ..."
diff --git a/versioncp/update_versions.php b/versioncp/update_versions.php
deleted file mode 100644
index 10feedf..0000000
--- a/versioncp/update_versions.php
+++ /dev/null
@@ -1,494 +0,0 @@
-<?php
-
-# == Settings ==
-
-$dbuser = 'root';
-$dbpass = 'root';
-$dbname = 'versioncp';
-$debug = 'off';
-
-// one of 'off', 'normal', 'full'
-
-$overbasepath = '/usr/overlays';
-$upstscriptsbasepath = '/var/www/localhost/htdocs/versioncp/upstscripts';
-
-# == End Settings ==
-# Update the main Portage tree
-
-if($debug === 'normal'
- || $debug === 'full')
-{
- echo 'Running emerge --sync now ...' . "\n";
-}
-
-$emergesync = shell_exec('emerge --sync');
-
-if($debug === 'full')
-{
- echo $emergesync . "\n";
-}
-
-# Connect to the database
-
-$db = mysql_connect(':/var/run/mysqld/mysqld.sock', $dbuser, $dbpass);
-mysql_select_db($dbname, $db);
-
-# Get the overlay data, then update it
-
-$overlays_dbresult = mysql_query('SELECT `overname`,`overtype`,`overbranch` FROM `overlays`', $db);
-$alloverlayspath = '';
-
-while($overlays = mysql_fetch_array($overlays_dbresult))
-{
- $overpath = '';
- $overpath = $overbasepath . '/' . $overlays['overtype'] . '/' . $overlays['overname'] . '/' . $overlays['overbranch'] . '/';
-
- if($debug === 'normal'
- || $debug === 'full')
- {
- echo 'Working on overlay: ' . $overlays['overtype'] . ' ' . $overlays['overname'] . ', branch: ' . $overlays['overbranch'] . "\n";
- echo 'at path: ' . $overpath . "\n";
- }
-
- if(file_exists($overpath))
- {
- $overupdout = '';
- $overupdout = shell_exec('cd "' . $overpath . '" && svn up');
-
- if($debug === 'normal'
- || $debug === 'full')
- {
- echo 'Updating overlay ...' . "\n";
- }
-
- if($debug === 'full')
- {
- echo $overupdout . "\n";
- }
- }
- else
- {
- $overcotout = '';
- $overcotout = shell_exec('svn co "http://overlays.gentoo.org/svn/' . $overlays['overtype'] . '/' . $overlays['overname'] . '/' . $overlays['overbranch'] . '/" "' . $overpath . '"');
-
- if($debug === 'normal'
- || $debug === 'full')
- {
- echo 'Checking out overlay ...' . "\n";
- }
-
- if($debug === 'full')
- {
- echo $overcotout . "\n";
- }
- }
-
- $alloverlayspath = $alloverlayspath . $overpath . ' ';
-}
-
-$alloverlayspath = trim($alloverlayspath);
-exec('sed -e "s|^PORTDIR_OVERLAY=.*|PORTDIR_OVERLAY=\"' . $alloverlayspath . '\"|g" -i "/etc/make.conf"');
-
-# Generate two arrays of all the project and developer overlays
-
-$overlays_overdbresult = mysql_query('SELECT `overname`,`overtype` FROM `overlays`', $db);
-$proj_array = array();
-$dev_array = array();
-
-while($overlays_result = mysql_fetch_array($overlays_overdbresult))
-{
- if($overlays_result['overtype'] === 'proj')
- {
- $proj_temp_array = '';
- $proj_temp_array[$overlays_result['overname']] = $overlays_result['overname'];
- $proj_array = array_merge($proj_array, $proj_temp_array);
- }
- else
- {
- $dev_temp_array = '';
- $dev_temp_array[$overlays_result['overname']] = $overlays_result['overname'];
- $dev_array = array_merge($dev_array, $dev_temp_array);
- }
-}
-
-if($debug === 'full')
-{
- echo 'Proj Array:' . "\n";
- var_dump($proj_array) . "\n\n";
- echo 'Dev Array:' . "\n";
- var_dump($dev_array) . "\n\n";
-}
-
-# Work on the project overlays
-
-foreach($proj_array as $proj)
-{
- # Get the overlay data
-
- $overlays_dbresult = '';
- $overlays_dbresult = mysql_query('SELECT `overbranch` FROM `overlays` WHERE `overtype` = "proj" AND `overname` = "' . $proj . '"', $db);
-
- # Prepare the list of overlays to exclude
-
- $alloverlayspathproj = '';
- $alloverlayspathproj = $alloverlayspath;
-
- while($overlaysproj = mysql_fetch_array($overlays_dbresult))
- {
- $overpath = '';
- $overpath = $overbasepath . '/proj/' . $proj . '/' . $overlaysproj['overbranch'] . '/';
- $alloverlayspathproj = str_replace($overpath, '', $alloverlayspathproj);
- }
-
- $alloverlayspathproj = str_replace(' ', ' ', $alloverlayspathproj);
- $alloverlayspathproj = str_replace(' ', ' ', $alloverlayspathproj);
- $alloverlayspathproj = str_replace(' ', ' ', $alloverlayspathproj);
- $alloverlayspathproj = str_replace(' ', ' ', $alloverlayspathproj);
- $alloverlayspathproj = trim($alloverlayspathproj);
- $projtoexcludecmd = '--exclude-overlay /usr/portage/ ';
-
- if($alloverlayspathproj != '')
- {
- $alloverlayspathproj = explode(' ', $alloverlayspathproj);
- foreach($alloverlayspathproj as $projpaths)
- {
- $projtoexcludecmd = $projtoexcludecmd . '--exclude-overlay ' . $projpaths . ' ';
- }
- }
-
- $projtoexcludecmd = trim($projtoexcludecmd);
-
- # Update eix, excluding the other overlays and /usr/portage/
-
- $updateeix = shell_exec('update-eix ' . $projtoexcludecmd);
-
- if($debug === 'full')
- {
- echo $updateeix . "\n";
- }
-
- # Get the package data, for latest Overlay
-
- $packages_dbresult = '';
- $packages_dbresult = mysql_query('SELECT `name` FROM `packages` WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" ORDER BY `name` ASC', $db);
-
- # Get the latest version in the Overlay, and store it into MySQL
-
- while($projpkg_result = mysql_fetch_array($packages_dbresult))
- {
- $latestpkgover = shell_exec('eix -e ' . $projpkg_result['name'] . ' | grep -i available | head -n 1 | awk \'{print $NF}\'');
-
- if($latestpkgover == '')
- {
- $latestpkgover = '-';
- }
-
- $latestpkgover = str_replace('~', '', $latestpkgover);
- $latestpkgover = str_replace('!', '', $latestpkgover);
- $latestpkgover = str_replace('[M]', '', $latestpkgover);
- $latestpkgover = str_replace('_', '', $latestpkgover);
- $latestpkgover = str_replace('-r', 'pl', $latestpkgover);
- $latestpkgover = trim($latestpkgover);
-
- if($debug === 'full')
- {
- echo 'Latest in Overlay for proj ' . $proj . ': ' . $projpkg_result['name'] . ' - ' . $latestpkgover . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versover` = "' . $latestpkgover . '" WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" AND `name` = "' . $projpkg_result['name'] . '"', $db);
- }
-
- # Prepare the list of all overlays to exclude
-
- $alloverlayspathproj = '';
- $alloverlayspathproj = $alloverlayspath;
- $alloverlayspathproj = explode(' ', $alloverlayspathproj);
- $projtoexcludecmd = '';
- foreach($alloverlayspathproj as $projpaths)
- {
- $projtoexcludecmd = $projtoexcludecmd . '--exclude-overlay ' . $projpaths . ' ';
- }
-
- $projtoexcludecmd = trim($projtoexcludecmd);
-
- # Update eix, including only /usr/portage/
-
- $updateeix = shell_exec('update-eix ' . $projtoexcludecmd);
-
- if($debug === 'full')
- {
- echo $updateeix . "\n";
- }
-
- # Get the package data, for latest Portage
-
- $packages_dbresult = '';
- $packages_dbresult = mysql_query('SELECT `name` FROM `packages` WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" ORDER BY `name` ASC', $db);
-
- # Get the latest version in the Portage tree, and store it into MySQL
-
- while($projpkgp_result = mysql_fetch_array($packages_dbresult))
- {
- $latestpkgport = shell_exec('eix -e ' . $projpkgp_result['name'] . ' | grep -i available | head -n 1 | awk \'{print $NF}\'');
-
- if($latestpkgport == '')
- {
- $latestpkgport = '-';
- }
-
- $latestpkgport = str_replace('~', '', $latestpkgport);
- $latestpkgport = str_replace('!', '', $latestpkgport);
- $latestpkgport = str_replace('[M]', '', $latestpkgport);
- $latestpkgport = str_replace('_', '', $latestpkgport);
- $latestpkgport = str_replace('-r', 'pl', $latestpkgport);
- $latestpkgport = trim($latestpkgport);
-
- if($debug === 'full')
- {
- echo 'Latest in Portage for proj ' . $proj . ': ' . $projpkgp_result['name'] . ' - ' . $latestpkgport . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versport` = "' . $latestpkgport . '" WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" AND `name` = "' . $projpkgp_result['name'] . '"', $db);
- }
-
- # Get the package data, for latest Upstream
-
- $packages_dbresult = '';
- $packages_dbresult = mysql_query('SELECT `name`,`versupst`,`upstscript` FROM `packages` WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" ORDER BY `name` ASC', $db);
-
- # Get the latest version Upstream, and store it into MySQL
-
- while($projpkgu_result = mysql_fetch_array($packages_dbresult))
- {
- if($projpkgu_result['upstscript'] != '')
- {
- $latestpkgupst = shell_exec($upstscriptsbasepath . '/' . $projpkgu_result['upstscript'] . ' ' . $projpkgu_result['name']);
-
- if($latestpkgupst == '')
- {
- $latestpkgupst = '-';
- }
-
- $latestpkgupst = trim($latestpkgupst);
-
- if($latestpkgupst == '-'
- && $projpkgu_result['versupst'] != ''
- && $projpkgu_result['versupst'] != '-')
- {
- if($debug === 'full')
- {
- echo 'Latest Upstream for proj ' . $proj . ': ' . $projpkgu_result['name'] . ' - ' . $projpkgu_result['versupst'] . "\n";
- }
- }
- else
- {
- if($debug === 'full')
- {
- echo 'Latest Upstream for proj ' . $proj . ': ' . $projpkgu_result['name'] . ' - ' . $latestpkgupst . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versupst` = "' . $latestpkgupst . '" WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" AND `name` = "' . $projpkgu_result['name'] . '"', $db);
- }
- }
- else
- {
- $latestpkgupst = '-';
- $latestpkgupst = trim($latestpkgupst);
-
- if($debug === 'full')
- {
- echo 'Latest Upstream for proj ' . $proj . ': ' . $projpkgu_result['name'] . ' - ' . $latestpkgupst . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versupst` = "' . $latestpkgupst . '" WHERE `projtype` = "proj" AND `projname` = "' . $proj . '" AND `name` = "' . $projpkgu_result['name'] . '"', $db);
- }
- }
-}
-
-# Work on the developer overlays
-
-foreach($dev_array as $dev)
-{
- # Get the overlay data
-
- $overlays_dbresult = '';
- $overlays_dbresult = mysql_query('SELECT `overbranch` FROM `overlays` WHERE `overtype` = "dev" AND `overname` = "' . $dev . '"', $db);
-
- # Prepare the list of overlays to exclude
-
- $alloverlayspathdev = '';
- $alloverlayspathdev = $alloverlayspath;
-
- while($overlaysdev = mysql_fetch_array($overlays_dbresult))
- {
- $overpath = '';
- $overpath = $overbasepath . '/dev/' . $dev . '/' . $overlaysdev['overbranch'] . '/';
- $alloverlayspathdev = str_replace($overpath, '', $alloverlayspathdev);
- }
-
- $alloverlayspathdev = str_replace(' ', ' ', $alloverlayspathdev);
- $alloverlayspathdev = str_replace(' ', ' ', $alloverlayspathdev);
- $alloverlayspathdev = str_replace(' ', ' ', $alloverlayspathdev);
- $alloverlayspathdev = str_replace(' ', ' ', $alloverlayspathdev);
- $alloverlayspathdev = trim($alloverlayspathdev);
- $devtoexcludecmd = '--exclude-overlay /usr/portage/ ';
-
- if($alloverlayspathdev != '')
- {
- $alloverlayspathdev = explode(' ', $alloverlayspathdev);
- foreach($alloverlayspathdev as $devpaths)
- {
- $devtoexcludecmd = $devtoexcludecmd . '--exclude-overlay ' . $devpaths . ' ';
- }
- }
-
- $devtoexcludecmd = trim($devtoexcludecmd);
-
- # Update eix, excluding the other overlays and /usr/portage/
-
- $updateeix = shell_exec('update-eix ' . $devtoexcludecmd);
-
- if($debug === 'full')
- {
- echo $updateeix . "\n";
- }
-
- # Get the package data, for latest Overlay
-
- $packages_dbresult = '';
- $packages_dbresult = mysql_query('SELECT `name` FROM `packages` WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" ORDER BY `name` ASC', $db);
-
- # Get the latest version in the Overlay, and store it into MySQL
-
- while($devpkg_result = mysql_fetch_array($packages_dbresult))
- {
- $latestpkgover = shell_exec('eix -e ' . $devpkg_result['name'] . ' | grep -i available | head -n 1 | awk \'{print $NF}\'');
-
- if($latestpkgover == '')
- {
- $latestpkgover = '-';
- }
-
- $latestpkgover = str_replace('~', '', $latestpkgover);
- $latestpkgover = str_replace('!', '', $latestpkgover);
- $latestpkgover = str_replace('[M]', '', $latestpkgover);
- $latestpkgover = str_replace('_', '', $latestpkgover);
- $latestpkgover = str_replace('-r', 'pl', $latestpkgover);
- $latestpkgover = trim($latestpkgover);
-
- if($debug === 'full')
- {
- echo 'Latest in Overlay for dev ' . $dev . ': ' . $devpkg_result['name'] . ' - ' . $latestpkgover . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versover` = "' . $latestpkgover . '" WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" AND `name` = "' . $devpkg_result['name'] . '"', $db);
- }
-
- # Prepare the list of all overlays to exclude
-
- $alloverlayspathdev = '';
- $alloverlayspathdev = $alloverlayspath;
- $alloverlayspathdev = explode(' ', $alloverlayspathdev);
- $devtoexcludecmd = '';
- foreach($alloverlayspathdev as $devpaths)
- {
- $devtoexcludecmd = $devtoexcludecmd . '--exclude-overlay ' . $devpaths . ' ';
- }
-
- $devtoexcludecmd = trim($devtoexcludecmd);
-
- # Update eix, including only /usr/portage/
-
- $updateeix = shell_exec('update-eix ' . $devtoexcludecmd);
-
- if($debug === 'full')
- {
- echo $updateeix . "\n";
- }
-
- # Get the package data, for latest Portage
-
- $packages_dbresult = '';
- $packages_dbresult = mysql_query('SELECT `name` FROM `packages` WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" ORDER BY `name` ASC', $db);
-
- # Get the latest version in the Portage tree, and store it into MySQL
-
- while($devpkgp_result = mysql_fetch_array($packages_dbresult))
- {
- $latestpkgport = shell_exec('eix -e ' . $devpkgp_result['name'] . ' | grep -i available | head -n 1 | awk \'{print $NF}\'');
-
- if($latestpkgport == '')
- {
- $latestpkgport = '-';
- }
-
- $latestpkgport = str_replace('~', '', $latestpkgport);
- $latestpkgport = str_replace('!', '', $latestpkgport);
- $latestpkgport = str_replace('[M]', '', $latestpkgport);
- $latestpkgport = str_replace('_', '', $latestpkgport);
- $latestpkgport = str_replace('-r', 'pl', $latestpkgport);
- $latestpkgport = trim($latestpkgport);
-
- if($debug === 'full')
- {
- echo 'Latest in Portage for dev ' . $dev . ': ' . $devpkgp_result['name'] . ' - ' . $latestpkgport . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versport` = "' . $latestpkgport . '" WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" AND `name` = "' . $devpkgp_result['name'] . '"', $db);
- }
-}
-
-# Get the package data, for latest Upstream
-
-$packages_dbresult = '';
-$packages_dbresult = mysql_query('SELECT `name`,`versupst`,`upstscript` FROM `packages` WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" ORDER BY `name` ASC', $db);
-
-# Get the latest version Upstream, and store it into MySQL
-
-while($devpkgu_result = mysql_fetch_array($packages_dbresult))
-{
- if($devpkgu_result['upstscript'] != '')
- {
- $latestpkgupst = shell_exec($upstscriptsbasepath . '/' . $devpkgu_result['upstscript'] . ' ' . $devpkgu_result['name']);
-
- if($latestpkgupst == '')
- {
- $latestpkgupst = '-';
- }
-
- $latestpkgupst = trim($latestpkgupst);
-
- if($latestpkgupst == '-'
- && $devpkgu_result['versupst'] != ''
- && $devpkgu_result['versupst'] != '-')
- {
- if($debug === 'full')
- {
- echo 'Latest Upstream for dev ' . $dev . ': ' . $devpkgu_result['name'] . ' - ' . $devpkgu_result['versupst'] . "\n";
- }
- }
- else
- {
- if($debug === 'full')
- {
- echo 'Latest Upstream for dev ' . $dev . ': ' . $devpkgu_result['name'] . ' - ' . $latestpkgupst . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versupst` = "' . $latestpkgupst . '" WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" AND `name` = "' . $devpkgu_result['name'] . '"', $db);
- }
- }
- else
- {
- $latestpkgupst = '-';
- $latestpkgupst = trim($latestpkgupst);
-
- if($debug === 'full')
- {
- echo 'Latest Upstream for dev ' . $dev . ': ' . $devpkgu_result['name'] . ' - ' . $latestpkgupst . "\n";
- }
-
- mysql_query('UPDATE `packages` SET `versupst` = "' . $latestpkgupst . '" WHERE `projtype` = "dev" AND `projname` = "' . $dev . '" AND `name` = "' . $devpkgu_result['name'] . '"', $db);
- }
-}
-
-?> \ No newline at end of file
diff --git a/versioncp/upstscripts/berlios b/versioncp/upstscripts/berlios
deleted file mode 100755
index 8ed386b..0000000
--- a/versioncp/upstscripts/berlios
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/bash
-
-# Strip cat, we only need the pkg name
-berpkg="`echo ${1} | sed -e "s|^.*/||g"`"
-
-# Take care of outputting the version number
-pwd="`pwd`"
-if ! test -d "${pwd}/${berpkg}-tmp" ; then
- mkdir "${pwd}/${berpkg}-tmp"
-fi
-cd "${pwd}/${berpkg}-tmp"
-wget --quiet --tries=1 --timeout=3 "http://developer.berlios.de/projects/${berpkg}/" -O indexfile
-projnum=`grep -i 'project/filelist.php?group_id' indexfile | sed -e "s|^.*<A .*group_id=||g" | sed -e "s|\">.*||g"`
-wget --quiet --tries=1 --timeout=3 "http://developer.berlios.de/export/rss20_bsnewreleases.php?group_id=${projnum}" -O rssfeed
-grep -i "<title>${berpkg} " rssfeed | head -n 1 | sed -e "s|^.*<title>${berpkg} ||gI" | sed -e "s|</title>.*||g" | sed -e "s|^[A-Za-z _-]*||g" | sed -e "s|-[cCe-oE-OqQs-zS-Z]\{1\}.*||g"
-rm -Rf "${pwd}/${berpkg}-tmp"
diff --git a/versioncp/upstscripts/ezcomponents b/versioncp/upstscripts/ezcomponents
deleted file mode 100755
index 7f888fe..0000000
--- a/versioncp/upstscripts/ezcomponents
+++ /dev/null
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-# Strip cat, we only need the pkg name
-ezcpkg="`echo ${1} | sed -e "s|^.*/||g"`"
-
-# Take care of some strange package naming
-ezcpkg="${ezcpkg/ezc-/}"
-
-# Take care of outputting the version number
-pwd="`pwd`"
-if ! test -d "${pwd}/${ezcpkg}-tmp" ; then
- mkdir "${pwd}/${ezcpkg}-tmp"
-fi
-cd "${pwd}/${ezcpkg}-tmp"
-wget --quiet --tries=1 --timeout=3 "http://ez.no/doc/components/overview/latest"
-grep -i ">${ezcpkg}</a>" latest | sed -e "s|<li><a href=\"/doc/components.*\">${ezcpkg}</a> (||g" | sed -e "s|)</li>.*||g"
-rm -Rf "${pwd}/${ezcpkg}-tmp"
diff --git a/versioncp/upstscripts/freshmeat b/versioncp/upstscripts/freshmeat
deleted file mode 100755
index b7f6a0c..0000000
--- a/versioncp/upstscripts/freshmeat
+++ /dev/null
@@ -1,14 +0,0 @@
-#!/bin/bash
-
-# Strip cat, we only need the pkg name
-fmpkg="`echo ${1} | sed -e "s|^.*/||g"`"
-
-# Take care of outputting the version number
-pwd="`pwd`"
-if ! test -d "${pwd}/${fmpkg}-tmp" ; then
- mkdir "${pwd}/${fmpkg}-tmp"
-fi
-cd "${pwd}/${fmpkg}-tmp"
-wget --quiet --tries=1 --timeout=3 "http://freshmeat.net/projects-xml/${fmpkg}/${fmpkg}.xml"
-grep -i 'latest_release_version' ${fmpkg}.xml | sed -e "s|^.*<latest_release_version>||g" | sed -e "s|</latest_release_version>.*||g" | sed -e "s|^[A-Za-z _-]*||g" | sed -e "s|-[cCe-oE-OqQs-zS-Z]\{1\}.*||g"
-rm -Rf "${pwd}/${fmpkg}-tmp"
diff --git a/versioncp/upstscripts/php-pear b/versioncp/upstscripts/php-pear
deleted file mode 100755
index 6152e10..0000000
--- a/versioncp/upstscripts/php-pear
+++ /dev/null
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-# Strip cat, we only need the pkg name
-pearpkg="`echo ${1} | sed -e "s|^.*/||g"`"
-
-# Take care of some strange package naming
-pearpkg="${pearpkg/PEAR-/}"
-
-# Take care of outputting the version number
-pwd="`pwd`"
-if ! test -d "${pwd}/${pearpkg}-tmp" ; then
- mkdir "${pwd}/${pearpkg}-tmp"
-fi
-cd "${pwd}/${pearpkg}-tmp"
-wget --quiet --tries=1 --timeout=3 "http://pear.php.net/feeds/pkg_${pearpkg}.rss"
-grep -i title pkg_${pearpkg}.rss | sed -e "s|<title>||g" | sed -e "s|</title>||g" | head -n 2 | tail -n 1 | awk '{print $NF}'
-rm -Rf "${pwd}/${pearpkg}-tmp"
diff --git a/versioncp/upstscripts/php-pecl b/versioncp/upstscripts/php-pecl
deleted file mode 100755
index b0c1c0a..0000000
--- a/versioncp/upstscripts/php-pecl
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-# Strip cat, we only need the pkg name
-peclpkg="`echo ${1} | sed -e "s|^.*/||g"`"
-
-# Take care of some strange package naming
-peclpkg="${peclpkg/pecl-http/pecl_http}"
-peclpkg="${peclpkg/pecl-/}"
-peclpkg="${peclpkg/pdo-/pdo_}"
-
-# Take care of outputting the version number
-pwd="`pwd`"
-if ! test -d "${pwd}/${peclpkg}-tmp" ; then
- mkdir "${pwd}/${peclpkg}-tmp"
-fi
-cd "${pwd}/${peclpkg}-tmp"
-wget --quiet --tries=1 --timeout=3 "http://pecl.php.net/feeds/pkg_${peclpkg}.rss"
-grep -i title pkg_${peclpkg}.rss | sed -e "s|<title>||g" | sed -e "s|</title>||g" | head -n 2 | tail -n 1 | awk '{print $NF}'
-rm -Rf "${pwd}/${peclpkg}-tmp"
diff --git a/versioncp/upstscripts/sourceforge b/versioncp/upstscripts/sourceforge
deleted file mode 100755
index 2145464..0000000
--- a/versioncp/upstscripts/sourceforge
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/bash
-
-# Strip cat, we only need the pkg name
-sfpkg="`echo ${1} | sed -e "s|^.*/||g"`"
-
-# Take care of outputting the version number
-pwd="`pwd`"
-if ! test -d "${pwd}/${sfpkg}-tmp" ; then
- mkdir "${pwd}/${sfpkg}-tmp"
-fi
-cd "${pwd}/${sfpkg}-tmp"
-wget --quiet --tries=1 --timeout=3 "http://sourceforge.net/projects/${sfpkg}/" -O indexfile
-projnum=`grep -i 'project/showfiles.php?group_id.*Files' indexfile | sed -e "s|^<li><a href.*group_id=||g" | sed -e "s|\" >.*||g"`
-wget --quiet --tries=1 --timeout=3 "http://sourceforge.net/export/rss2_projfiles.php?group_id=${projnum}" -O rssfeed
-grep -i "<title>${sfpkg} " rssfeed | head -n 1 | sed -e "s|^.*<title>${sfpkg} ||gI" | sed -e "s| released .*</title>.*||g" | sed -e "s|^[A-Za-z _-]*||g" | sed -e "s|-[cCe-oE-OqQs-zS-Z]\{1\}.*||g"
-rm -Rf "${pwd}/${sfpkg}-tmp"