Annotation of embedaddon/pciutils/maint/release, revision 1.1

1.1     ! misho       1: #!/usr/bin/perl
        !             2: # A simple script for making releases of the pciutils
        !             3: # (c) 2003--2012 Martin Mares <mj@ucw.cz>
        !             4: 
        !             5: use strict;
        !             6: use warnings;
        !             7: require "maint/release.pm";
        !             8: 
        !             9: # Check API version
        !            10: my $apiver = "???";
        !            11: open X, "lib/pci.h" or die;
        !            12: while (<X>) {
        !            13:        /^#define PCI_LIB_VERSION 0x(.{6})$/ and $apiver = $1;
        !            14: }
        !            15: print "API version is $apiver ... <confirm> "; <STDIN>;
        !            16: 
        !            17: print "Updating public GIT tree\n";
        !            18: `git push --tags public`; die if $?;
        !            19: 
        !            20: my $r = new UCW::Release("pciutils");
        !            21: my $ver = $r->GetVersionFromFile("Makefile", "VERSION=(.*)");
        !            22: $r->GetVersionsFromChangelog("ChangeLog", "Released as (.*)\.");
        !            23: push @{$r->{"rules"}}, '^win32/config.h' => 's';
        !            24: if ($ver =~ /-/) {
        !            25:        $r->{"ALPHADIR"} = "alpha/";
        !            26:        $r->{"conditions"}->{"ALPHA_VERSION"} = 1;
        !            27: } else {
        !            28:        $r->{"ALPHADIR"} = "";
        !            29:        $r->{"conditions"}->{"ALPHA_VERSION"} = -1;
        !            30: }
        !            31: push @{$r->{"uploads"}}, {
        !            32:        "url" => "scp://atrey.karlin.mff.cuni.cz/~ftp/pub/linux/pci/" . $r->{"ALPHADIR"}
        !            33: ##     },{
        !            34: ##     "url" => "scp://master.kernel.org/pub/software/utils/pciutils/" . $r->{"ALPHADIR"}
        !            35:        };
        !            36: push @{$r->{"uploads"}}, {
        !            37:        "url" => "ftp://metalab.unc.edu/incoming/linux/",
        !            38:        "filter" => '(\.tar\.gz|\.lsm)$'
        !            39:        } if $r->{"ALPHADIR"} eq "";
        !            40: $r->ParseOptions;
        !            41: $r->InitDist("maint/dist");
        !            42: my $reldir = $r->GenPackage;
        !            43: $r->GenFile("README");
        !            44: $r->GenFile("pciutils.lsm");
        !            45: $r->Dispatch;
        !            46: if ($r->{"do_upload"}) {
        !            47:        print "Uploading pci.ids to Jabberwock\n";
        !            48:        `scp -C pci.ids pciids\@jabberwock.ucw.cz:05-pciutils.new`; die if $?;
        !            49:        `ssh pciids\@jabberwock.ucw.cz mv 05-pciutils.new origs/05-pciutils`; die if $?;
        !            50: }

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>