Changeset 411 for CMT/HEAD/source/cmt_cvs.cxx
- Timestamp:
- Apr 24, 2007, 11:44:34 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
CMT/HEAD/source/cmt_cvs.cxx
r400 r411 1952 1952 const cmt_string& version_tag) 1953 1953 { 1954 if (m_verbose) 1955 { 1956 cerr << "#CMT> checkout phase1 module=" << module 1957 << " version_dir=" << version_dir << " version_tag=" << version_tag << endl; 1958 } 1959 1954 1960 add_cmtpath (m_home_dir); 1955 1961 … … 1988 1994 if (version_tag == "") 1989 1995 { 1990 Cut cut (0); 1991 1992 if (tags_top_info != "") tag = tags_top_info; 1993 else tag = tags_info; 1994 1995 cut.run (tag); 1996 1997 tag = cut.result (); 1996 // No version tag is specified 1997 // we need to discard all CVS branches 1998 // 1999 cmt_string versions = ""; 2000 2001 if (cvsversions_top_info != "") 2002 { 2003 versions = cvsversions_top_info; 2004 versions += " "; 2005 } 2006 2007 versions += cvsversions_info; 2008 2009 static CmtSystem::cmt_string_vector words; 2010 2011 // Get all <tag>:<version> items 2012 2013 CmtSystem::split (versions, " \t", words); 2014 2015 for (int i = 0; i < words.size (); i++) 2016 { 2017 // split to get <tag> and <version> separately 2018 2019 static CmtSystem::cmt_string_vector vts; 2020 CmtSystem::split (words[i], ":", vts); 2021 2022 cmt_string t = vts[0]; 2023 cmt_string v = vts[1]; 2024 2025 // Split to count the number of items for the CVS version 2026 2027 static CmtSystem::cmt_string_vector ds; 2028 CmtSystem::split (v, ".", ds); 2029 2030 if (ds.size () == 2) 2031 { 2032 tag = t; 2033 break; 2034 } 2035 } 1998 2036 } 1999 2037 else
Note: See TracChangeset
for help on using the changeset viewer.