OpenPKG CVS Repository
  http://cvs.openpkg.org/
  ____________________________________________________________________________

  Server: cvs.openpkg.org                  Name:   Ralf S. Engelschall
  Root:   /v/openpkg/cvs                   Email:  [EMAIL PROTECTED]
  Module: openpkg-src                      Date:   08-Aug-2007 11:23:14
  Branch: HEAD                             Handle: 2007080810231400

  Added files:
    openpkg-src/monotone    monotone.patch
  Modified files:
    openpkg-src/monotone    monotone.spec

  Log:
    some upstream vendor fixes since monotone 0.36

  Summary:
    Revision    Changes     Path
    1.7         +121 -0     openpkg-src/monotone/monotone.patch
    1.16        +3  -1      openpkg-src/monotone/monotone.spec
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: openpkg-src/monotone/monotone.patch
  ============================================================================
  $ cvs diff -u -r0 -r1.7 monotone.patch
  --- /dev/null 2007-08-08 11:23:01 +0200
  +++ monotone.patch    2007-08-08 11:23:14 +0200
  @@ -0,0 +1,121 @@
  +some upstream vendor fixes since monotone 0.36
  +
  +Index: automate.cc
  +--- automate.cc.orig 2007-08-03 08:15:05 +0200
  ++++ automate.cc      2007-08-08 11:03:02 +0200
  +@@ -69,12 +69,19 @@
  +   N(args.size() < 2,
  +     F("wrong argument count"));
  + 
  +-  if (args.size() ==1 ) {
  ++  system_path database_option;
  ++  branch_name branch_option;
  ++  rsa_keypair_id key_option;
  ++  system_path keydir_option;
  ++  app.work.get_ws_options(database_option, branch_option,
  ++                          key_option, keydir_option);
  ++
  ++  if (args.size() == 1 ) {
  +     // branchname was explicitly given, use that
  +-    app.opts.branchname = branch_name(idx(args, 0)());
  ++    branch_option = branch_name(idx(args, 0)());
  +   }
  +   set<revision_id> heads;
  +-  app.get_project().get_branch_heads(app.opts.branchname, heads);
  ++  app.get_project().get_branch_heads(branch_option, heads);
  +   for (set<revision_id>::const_iterator i = heads.begin(); i != 
heads.end(); ++i)
  +     output << (*i).inner()() << '\n';
  + }
  +Index: cmd_ws_commit.cc
  +--- cmd_ws_commit.cc.orig    2007-08-03 08:15:09 +0200
  ++++ cmd_ws_commit.cc 2007-08-08 11:03:02 +0200
  +@@ -444,7 +444,8 @@
  + 
  +   app.require_workspace();
  + 
  +-  file_path dst_path = file_path_external(args.back());
  ++  utf8 dstr = args.back();
  ++  file_path dst_path = file_path_external(dstr);
  + 
  +   set<file_path> src_paths;
  +   for (size_t i = 0; i < args.size()-1; i++)
  +@@ -452,6 +453,15 @@
  +       file_path s = file_path_external(idx(args, i));
  +       src_paths.insert(s);
  +     }
  ++
  ++  //this catches the case where the user specifies a directory 'by 
convention'
  ++  //that doesn't exist.  the code in perform_rename already handles the 
proper
  ++  //cases for more than one source item.
  ++  if (src_paths.size() == 1 && dstr()[dstr().size() -1] == '/')
  ++    if (get_path_status(*src_paths.begin()) != path::directory)
  ++        N(get_path_status(dst_path) == path::directory,
  ++          F(_("The specified target directory %s/ doesn't exist.")) % 
dst_path);
  ++
  +   app.work.perform_rename(src_paths, dst_path, app.opts.bookkeep_only);
  + }
  + 
  +Index: work.cc
  +--- work.cc.orig     2007-08-03 08:15:16 +0200
  ++++ work.cc  2007-08-08 11:03:02 +0200
  +@@ -1435,9 +1435,7 @@
  +     {
  +       // "rename SRC DST" case
  +       file_path const & src = *srcs.begin();
  +-
  +-      N(!directory_exists(dst),
  +-        F("destination dir %s/ is not versioned (perhaps add it?)") % dst);
  ++      file_path dpath = dst;
  + 
  +       N(!src.empty(),
  +         F("cannot rename the workspace root (try '%s pivot_root' instead)")
  +@@ -1445,20 +1443,30 @@
  +       N(new_roster.has_node(src),
  +         F("source file %s is not versioned") % src);
  + 
  +-      renames.insert(make_pair(src, dst));
  +-      add_parent_dirs(dst, new_roster, nis, db, lua);
  ++      //this allows the 'magic add' of a non-versioned directory to happen 
in
  ++      //all cases.  previously, mtn mv fileA dir/ woudl fail if dir/ wasn't
  ++      //versioned whereas mtn mv fileA dir/fileA would add dir/ if necessary
  ++      //and then reparent fileA.
  ++      if (get_path_status(dst) == path::directory)
  ++        dpath = dst / src.basename();
  ++      else
  ++        {
  ++          //this handles the case where:
  ++          // touch foo
  ++          // mtn mv foo bar/foo where bar doesn't exist
  ++          file_path parent = dst.dirname();
  ++            N(get_path_status(parent) == path::directory,
  ++              F("destination path's parent directory %s/ doesn't exist") % 
parent);
  ++        }
  ++
  ++      renames.insert(make_pair(src, dpath));
  ++      add_parent_dirs(dpath, new_roster, nis, db, lua);
  +     }
  +   else
  +     {
  +       // "rename SRC1 [SRC2 ...] DSTDIR" case
  +-      N(new_roster.has_node(dst),
  +-        F("destination dir %s/ is not versioned (perhaps add it?)") % dst);
  +-
  +-      N(is_dir_t(new_roster.get_node(dst)),
  +-        (srcs.size() > 1
  +-        ? F("destination %s is a file, not a directory")
  +-        : F("destination %s already exists in the workspace manifest"))
  +-        % dst);
  ++      N(get_path_status(dst) == path::directory,
  ++        F("destination %s/ is not a directory") % dst);
  + 
  +       for (set<file_path>::const_iterator i = srcs.begin();
  +            i != srcs.end(); i++)
  +@@ -1474,6 +1482,8 @@
  +             F("destination %s already exists in the workspace manifest") % 
d);
  + 
  +           renames.insert(make_pair(*i, d));
  ++
  ++          add_parent_dirs(d, new_roster, nis, db, lua);
  +         }
  +     }
  + 
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/monotone/monotone.spec
  ============================================================================
  $ cvs diff -u -r1.15 -r1.16 monotone.spec
  --- openpkg-src/monotone/monotone.spec        3 Aug 2007 15:07:44 -0000       
1.15
  +++ openpkg-src/monotone/monotone.spec        8 Aug 2007 09:23:14 -0000       
1.16
  @@ -33,12 +33,13 @@
   Group:        SCM
   License:      GPL
   Version:      0.36
  -Release:      20070803
  +Release:      20070808
   
   #   list of sources
   Source0:      
http://monotone.ca/downloads/%{version}/monotone-%{version}.tar.gz
   Source1:      rc.monotone
   Source3:      monotone-setup.sh
  +Patch0:       monotone.patch
   
   #   build information
   Prefix:       %{l_prefix}
  @@ -70,6 +71,7 @@
   
   %prep
       %setup -q
  +    %patch -p0
   
   %build
       #   configure program
  @@ .
______________________________________________________________________
OpenPKG                                             http://openpkg.org
CVS Repository Commit List                     openpkg-cvs@openpkg.org

Reply via email to