Changeset 1003


Ignore:
Timestamp:
Jan 2, 2010, 3:35:57 AM (11 years ago)
Author:
Peter Johansson
Message:

merging release 0.7.2. Delta 0.7.2 - 0.7.1

Location:
trunk
Files:
12 edited

Legend:

Unmodified
Added
Removed
  • trunk/.release_year

    r909 r1003  
    1 2009
     12010
  • trunk/Makefile.am

    r978 r1003  
    6464MAINTAINER_CHECK_LOCAL = all check
    6565# extra check in release rule
    66 #RELEASE_LOCAL =
     66RELEASE_LOCAL = check-svn_revision
     67
     68.PHONY: check-svn_revision
     69
     70check-svn_revision:
     71  @$(SVNVERSION) | $(EGREP) '^[0-9]+$$' || \
     72  { echo incorrect svn revision - expected single unmodified revision 1>&2; \
     73    exit 1; }
  • trunk/NEWS

    r978 r1003  
    1313svndigest 0.7.x series from
    1414    http://dev.thep.lu.se/svndigest/svn/branches/0.7-stable
     15
     16Version 0.7.2 (released 2 January 2010)
     17  - Author included in plot unless count is 0 for all revisions (bug #434)
     18  - Default codons in config file is now corrected. Old cache files
     19    are obsolete and are ignored by svndigest 0.7.2 (bug #431)
     20
     21  A complete list of closed tickets can be found here [[br]]
     22  http://dev.thep.lu.se/svndigest/query?status=closed&milestone=0.7.2
    1523
    1624Version 0.7.1 (released 3 December 2009)
  • trunk/lib/AddStats.cc

    r978 r1003  
    44  Copyright (C) 2005 Peter Johansson
    55  Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
    6   Copyright (C) 2009 Peter Johansson
     6  Copyright (C) 2009, 2010 Peter Johansson
    77
    88  This file is part of svndigest, http://dev.thep.lu.se/svndigest
     
    7777
    7878
     79  unsigned int AddStats::max_element(const std::vector<unsigned int>& v) const
     80  {
     81    assert(v.size());
     82    return v.back();
     83  }
     84
     85
    7986}} // end of namespace svndigest and namespace theplu
  • trunk/lib/AddStats.h

    r978 r1003  
    77  Copyright (C) 2005 Peter Johansson
    88  Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
     9  Copyright (C) 2010 Peter Johansson
    910
    1011  This file is part of svndigest, http://dev.thep.lu.se/svndigest
     
    4445  private:
    4546    void do_parse(const std::string&, svn_revnum_t);
     47    unsigned int max_element(const std::vector<unsigned int>&) const;
    4648
    4749  };
  • trunk/lib/BlameStats.cc

    r978 r1003  
    44  Copyright (C) 2005 Peter Johansson
    55  Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
    6   Copyright (C) 2009 Peter Johansson
     6  Copyright (C) 2009, 2010 Peter Johansson
    77
    88  This file is part of svndigest, http://dev.thep.lu.se/svndigest
     
    118118
    119119
     120  unsigned int BlameStats::max_element(const std::vector<unsigned int>& v) const
     121  {
     122    assert(v.size());
     123    return v.back();
     124  }
     125
    120126}} // end of namespace svndigest and namespace theplu
  • trunk/lib/BlameStats.h

    r978 r1003  
    77  Copyright (C) 2005 Peter Johansson
    88  Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
     9  Copyright (C) 2010 Peter Johansson
    910
    1011  This file is part of svndigest, http://dev.thep.lu.se/svndigest
     
    4546    void do_parse(const std::string&, svn_revnum_t);
    4647    void fill_in(Author2Vector&, svn_revnum_t rev);
     48    unsigned int max_element(const std::vector<unsigned int>&) const;
    4749
    4850  };
  • trunk/lib/Configuration.cc

    r996 r1003  
    147147  {
    148148    assert(is.good());
    149     set_default();
    150149
    151150    bool parsing_found=false;
  • trunk/lib/Stats.cc

    r978 r1003  
    3434#include <cstdlib>
    3535#include <fstream>
     36#include <iostream>
    3637#include <iterator>
    3738#include <map>
     
    277278    std::string str;
    278279    getline(is, str);
    279     if (str!=cache_check_str())
     280    if (str!=cache_check_str()) {
     281      if (str == prev_cache_check_str())
     282        std::cout << "cache file is obsolete; "
     283                  << "retrieving statistics from repository.\n";
    280284      return 0;
     285    }
    281286    svn_revnum_t rev;
    282287    is >> rev;
     
    327332      }
    328333    }
     334  }
     335
     336
     337  unsigned int Stats::max_element(const std::vector<unsigned int>& vec) const
     338  {
     339    return *std::max_element(vec.begin(), vec.end());
    329340  }
    330341
     
    374385    for (std::set<std::string>::const_iterator i=authors_.begin();
    375386         i != authors_.end(); ++i) {
    376       if (lines(*i)) {
    377         assert(stat->find(*i)!=stat->end());
    378         author_cont.push_back(std::make_pair(*i,get_vector(*stat,*i)));
     387      assert(stat->find(*i)!=stat->end());
     388      const std::vector<unsigned int>& vec = get_vector(*stat,*i);
     389      if (max_element(vec)) {
     390        author_cont.push_back(std::make_pair(*i,vec));
    379391      }
    380392    }
  • trunk/lib/Stats.h

    r978 r1003  
    77  Copyright (C) 2005 Peter Johansson
    88  Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
     9  Copyright (C) 2009, 2010 Peter Johansson
    910
    1011  This file is part of svndigest, http://dev.thep.lu.se/svndigest
     
    218219    // that all old cache files are obsolete.
    219220    inline std::string cache_check_str(void) const
     221    {return "CACHE FILE VERSION 7";}
     222
     223    inline std::string prev_cache_check_str(void) const
    220224    {return "CACHE FILE VERSION 6";}
    221225
     
    225229    unsigned int get_back(const Author2Vector&, std::string user) const;
    226230    void load(std::istream& is, Author2Vector& m);
     231    /**
     232       Finds the largets element by iterating through the entire
     233       vector. Inherited classes should implement their own version
     234       when it is possible to get the largest element in faster than
     235       in linear time.
     236
     237       \return the largest largest element in \a v.
     238    */
     239    virtual unsigned int max_element(const std::vector<unsigned int>& v) const;
     240
    227241    void print(std::ostream& os, const Author2Vector& m) const;
    228242
  • trunk/m4/version.m4

    r978 r1003  
    22#
    33# Copyright (C) 2008 Jari Häkkinen, Peter Johansson
    4 # Copyright (C) 2009 Peter Johansson
     4# Copyright (C) 2009, 2010 Peter Johansson
    55#
    66# This file is part of svndigest, http://trac.thep.lu.se/svndigest
  • trunk/test/data/AUTHORS.svndigest-cache-r61

    r792 r1003  
    1 CACHE FILE VERSION 6
     1CACHE FILE VERSION 7
    2248 1
    33jari
    4 CACHE FILE VERSION 6
     4CACHE FILE VERSION 7
    55all
    66
    77jari
    88
    9 CACHE FILE VERSION 6
     9CACHE FILE VERSION 7
    1010all
    11112 6
    1212jari
    13132 6
    14 CACHE FILE VERSION 6
     14CACHE FILE VERSION 7
    1515all
    16162 8
    1717jari
    18182 8
    19 CACHE FILE VERSION 6
     19CACHE FILE VERSION 7
    2020all
    2121
    2222jari
    2323
    24 CACHE FILE VERSION 6
     24CACHE FILE VERSION 7
    2525all
    26262 8
    2727jari
    28282 8
    29 CACHE FILE VERSION 6
     29CACHE FILE VERSION 7
    3030all
    31312 14
    3232jari
    33332 14
    34 CACHE FILE VERSION 6
    35 CACHE FILE VERSION 6
     34CACHE FILE VERSION 7
     35CACHE FILE VERSION 7
    363648 1
    3737jari
    38 CACHE FILE VERSION 6
     38CACHE FILE VERSION 7
    3939all
    4040
    4141jari
    4242
    43 CACHE FILE VERSION 6
     43CACHE FILE VERSION 7
    4444all
    45452 6 48 4294967292
    4646jari
    47472 6 48 4294967292
    48 CACHE FILE VERSION 6
     48CACHE FILE VERSION 7
    4949all
    50502 8 48 4294967293
    5151jari
    52522 8 48 4294967293
    53 CACHE FILE VERSION 6
     53CACHE FILE VERSION 7
    5454all
    5555
    5656jari
    5757
    58 CACHE FILE VERSION 6
     58CACHE FILE VERSION 7
    5959all
    60602 8 48 4294967293
    6161jari
    62622 8 48 4294967293
    63 CACHE FILE VERSION 6
     63CACHE FILE VERSION 7
    6464all
    65652 14 48 4294967289
    6666jari
    67672 14 48 4294967289
    68 CACHE FILE VERSION 6
    69 CACHE FILE VERSION 6
     68CACHE FILE VERSION 7
     69CACHE FILE VERSION 7
    707048 1
    7171jari
    72 CACHE FILE VERSION 6
     72CACHE FILE VERSION 7
    7373all
    7474
    7575jari
    7676
    77 CACHE FILE VERSION 6
     77CACHE FILE VERSION 7
    7878all
    79792 2
    8080jari
    81812 2
    82 CACHE FILE VERSION 6
     82CACHE FILE VERSION 7
    8383all
    84842 5
    8585jari
    86862 5
    87 CACHE FILE VERSION 6
     87CACHE FILE VERSION 7
    8888all
    8989
    9090jari
    9191
    92 CACHE FILE VERSION 6
     92CACHE FILE VERSION 7
    9393all
    94942 5
    9595jari
    96962 5
    97 CACHE FILE VERSION 6
     97CACHE FILE VERSION 7
    9898all
    99992 7
    100100jari
    1011012 7
    102 CACHE FILE VERSION 6
     102CACHE FILE VERSION 7
Note: See TracChangeset for help on using the changeset viewer.