fix vim-style foldmarker
authorDavid Kalnischkies <kalnischkies@gmail.com>
Fri, 30 Aug 2013 15:18:20 +0000 (17:18 +0200)
committerDavid Kalnischkies <kalnischkies@gmail.com>
Tue, 3 Sep 2013 21:11:58 +0000 (23:11 +0200)
Git-Dch: Ignore

apt-private/private-install.cc
apt-private/private-list.cc
apt-private/private-output.cc
apt-private/private-search.cc
apt-private/private-show.cc
apt-private/private-upgrade.cc
cmdline/apt-get.cc

index b03f131..9808c3d 100644 (file)
@@ -94,8 +94,6 @@ static bool CheckAuth(pkgAcquire& Fetcher)
    return _error->Error(_("There are problems and -y was used without --force-yes"));
 }
                                                                        /*}}}*/
-
-
 // InstallPackages - Actually download and install the packages                /*{{{*/
 // ---------------------------------------------------------------------
 /* This displays the informative messages describing what is going to 
@@ -429,8 +427,6 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask, bool Safety)
    return true;
 }
                                                                        /*}}}*/
-
-
 // DoAutomaticRemove - Remove all automatic unused packages            /*{{{*/
 // ---------------------------------------------------------------------
 /* Remove unused automatic packages */
@@ -576,7 +572,7 @@ bool DoAutomaticRemove(CacheFile &Cache)
    return true;
 }
                                                                        /*}}}*/
-
+// DoCacheManipulationFromCommandLine                                  /*{{{*/
 static const unsigned short MOD_REMOVE = 1;
 static const unsigned short MOD_INSTALL = 2;
 
@@ -585,7 +581,6 @@ bool DoCacheManipulationFromCommandLine(CommandLine &CmdL, CacheFile &Cache)
    std::map<unsigned short, APT::VersionSet> verset;
    return DoCacheManipulationFromCommandLine(CmdL, Cache, verset);
 }
-
 bool DoCacheManipulationFromCommandLine(CommandLine &CmdL, CacheFile &Cache,
                                         std::map<unsigned short, APT::VersionSet> &verset)
 {
@@ -719,8 +714,7 @@ bool DoCacheManipulationFromCommandLine(CommandLine &CmdL, CacheFile &Cache,
 
    return true;
 }
-
-
+                                                                       /*}}}*/
 // DoInstall - Install packages from the command line                  /*{{{*/
 // ---------------------------------------------------------------------
 /* Install named packages */
index c3a21aa..8c61fca 100644 (file)
@@ -42,7 +42,7 @@
 #include <apti18n.h>
                                                                        /*}}}*/
 
-struct PackageSortAlphabetic
+struct PackageSortAlphabetic                                           /*{{{*/
 {
    bool operator () (const pkgCache::PkgIterator &p_lhs, 
                      const pkgCache::PkgIterator &p_rhs)
@@ -52,12 +52,12 @@ struct PackageSortAlphabetic
        return (l_name < r_name);
     }
 };
-
+                                                                       /*}}}*/
+class PackageNameMatcher : public Matcher                              /*{{{*/
+{
 #ifdef PACKAGE_MATCHER_ABI_COMPAT
 #define PackageMatcher PackageNameMatchesFnmatch
 #endif
-class PackageNameMatcher : public Matcher
-{
   public:
    PackageNameMatcher(const char **patterns)
    {
@@ -98,9 +98,8 @@ private:
    std::vector<APT::CacheFilter::PackageMatcher*>::const_iterator J;
    #undef PackageMatcher
 };
-
-
-void ListAllVersions(pkgCacheFile &CacheFile, pkgRecords &records, 
+                                                                       /*}}}*/
+void ListAllVersions(pkgCacheFile &CacheFile, pkgRecords &records,     /*{{{*/
                      pkgCache::PkgIterator P,    
                      std::ostream &outs)
 {
@@ -108,7 +107,7 @@ void ListAllVersions(pkgCacheFile &CacheFile, pkgRecords &records,
         Ver.end() == false; Ver++) 
       ListSingleVersion(CacheFile, records, Ver, outs);
 }
-
+                                                                       /*}}}*/
 // list - list package based on criteria                               /*{{{*/
 // ---------------------------------------------------------------------
 bool List(CommandLine &Cmd)
index 6599754..6fadf72 100644 (file)
@@ -28,8 +28,7 @@ std::ostream c2out(0);
 std::ofstream devnull("/dev/null");
 unsigned int ScreenWidth = 80 - 1; /* - 1 for the cursor */
 
-
-bool InitOutput()
+bool InitOutput()                                                      /*{{{*/
 {
    c0out.rdbuf(cout.rdbuf());
    c1out.rdbuf(cout.rdbuf());
@@ -60,8 +59,8 @@ bool InitOutput()
 
    return true;
 }
-
-std::string GetArchiveSuite(pkgCacheFile &CacheFile, pkgCache::VerIterator ver)
+                                                                       /*}}}*/
+std::string GetArchiveSuite(pkgCacheFile &CacheFile, pkgCache::VerIterator ver) /*{{{*/
 {
    std::string suite = "";
    if (ver && ver.FileList() && ver.FileList())
@@ -77,8 +76,8 @@ std::string GetArchiveSuite(pkgCacheFile &CacheFile, pkgCache::VerIterator ver)
    }
    return suite;
 }
-
-std::string GetFlagsStr(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)
+                                                                       /*}}}*/
+std::string GetFlagsStr(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/
 {
    pkgDepCache *DepCache = CacheFile.GetDepCache();
    pkgDepCache::StateCache &state = (*DepCache)[P];
@@ -94,23 +93,23 @@ std::string GetFlagsStr(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)
       flags_str = "-";
    return flags_str;
 }
-
-std::string GetCandidateVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)
+                                                                       /*}}}*/
+std::string GetCandidateVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/
 {
    pkgPolicy *policy = CacheFile.GetPolicy();
    pkgCache::VerIterator cand = policy->GetCandidateVer(P);
 
    return cand ? cand.VerStr() : "(none)";
 }
-
-std::string GetInstalledVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)
+                                                                       /*}}}*/
+std::string GetInstalledVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/
 {
    pkgCache::VerIterator inst = P.CurrentVer();
 
    return inst ? inst.VerStr() : "(none)";
 }
-
-std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)
+                                                                       /*}}}*/
+std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)/*{{{*/
 {
    pkgCache::PkgIterator P = V.ParentPkg();
    if (V == P.CurrentVer())
@@ -127,8 +126,8 @@ std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)
       return DeNull(V.VerStr());
    return "(none)";
 }
-
-std::string GetArchitecture(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)
+                                                                       /*}}}*/
+std::string GetArchitecture(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/
 {
    pkgPolicy *policy = CacheFile.GetPolicy();
    pkgCache::VerIterator inst = P.CurrentVer();
@@ -136,8 +135,8 @@ std::string GetArchitecture(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)
    
    return inst ? inst.Arch() : cand.Arch();
 }
-
-std::string GetShortDescription(pkgCacheFile &CacheFile, pkgRecords &records, pkgCache::PkgIterator P)
+                                                                       /*}}}*/
+std::string GetShortDescription(pkgCacheFile &CacheFile, pkgRecords &records, pkgCache::PkgIterator P)/*{{{*/
 {
    pkgPolicy *policy = CacheFile.GetPolicy();
 
@@ -157,8 +156,8 @@ std::string GetShortDescription(pkgCacheFile &CacheFile, pkgRecords &records, pk
    }
    return ShortDescription;
 }
-
-void ListSingleVersion(pkgCacheFile &CacheFile, pkgRecords &records, 
+                                                                       /*}}}*/
+void ListSingleVersion(pkgCacheFile &CacheFile, pkgRecords &records,   /*{{{*/
                        pkgCache::VerIterator V, std::ostream &out)
 {
    pkgCache::PkgIterator P = V.ParentPkg();
@@ -230,8 +229,7 @@ void ListSingleVersion(pkgCacheFile &CacheFile, pkgRecords &records,
                 << std::endl;
    }
 }
-
-
+                                                                       /*}}}*/
 // ShowList - Show a list                                              /*{{{*/
 // ---------------------------------------------------------------------
 /* This prints out a string of space separated words with a title and 
index 6881f48..ff4140f 100644 (file)
@@ -1,3 +1,4 @@
+// Includes                                                            /*{{{*/
 #include <apt-pkg/error.h>
 #include <apt-pkg/cachefile.h>
 #include <apt-pkg/cachefilter.h>
@@ -34,9 +35,9 @@
 
 #include "private-search.h"
 #include "private-cacheset.h"
+                                                                       /*}}}*/
 
-
-bool FullTextSearch(CommandLine &CmdL)
+bool FullTextSearch(CommandLine &CmdL)                                 /*{{{*/
 {
    pkgCacheFile CacheFile;
    pkgCache *Cache = CacheFile.GetPkgCache();
@@ -97,3 +98,4 @@ bool FullTextSearch(CommandLine &CmdL)
 
    return true;
 }
+                                                                       /*}}}*/
index e26a2b3..7f4beb7 100644 (file)
@@ -1,3 +1,4 @@
+// Includes                                                            /*{{{*/
 #include <apt-pkg/error.h>
 #include <apt-pkg/cachefile.h>
 #include <apt-pkg/cachefilter.h>
@@ -23,6 +24,7 @@
 
 #include "private-output.h"
 #include "private-cacheset.h"
+                                                                       /*}}}*/
 
 namespace APT {
    namespace Cmd {
@@ -87,8 +89,7 @@ bool DisplayRecord(pkgCacheFile &CacheFile, pkgCache::VerIterator V,
    return true;
 }
                                                                        /*}}}*/
-
-bool ShowPackage(CommandLine &CmdL)
+bool ShowPackage(CommandLine &CmdL)                                    /*{{{*/
 {
    pkgCacheFile CacheFile;
    CacheSetHelperVirtuals helper(true, GlobalError::NOTICE);
index 09085c2..9a5286b 100644 (file)
@@ -1,13 +1,13 @@
-
+// Includes                                                            /*{{{*/
 #include <apt-pkg/algorithms.h>
 
 #include "private-install.h"
 #include "private-cachefile.h"
 #include "private-upgrade.h"
 #include "private-output.h"
+                                                                       /*}}}*/
 
-
-// DoUpgradeNoNewPackages - Upgrade all packages                       /*{{{*/
+// DoUpgradeNoNewPackages - Upgrade all packages                       /*{{{*/
 // ---------------------------------------------------------------------
 /* Upgrade all packages without installing new packages or erasing old
    packages */
@@ -31,7 +31,6 @@ bool DoUpgradeNoNewPackages(CommandLine &CmdL)
    return InstallPackages(Cache,true);
 }
                                                                        /*}}}*/
-
 // DoSafeUpgrade - Upgrade all packages with install but not remove    /*{{{*/
 bool DoUpgradeWithAllowNewPackages(CommandLine &CmdL)
 {
index c273dfa..8a30ac3 100644 (file)
 #include <apti18n.h>
                                                                        /*}}}*/
 
-
 using namespace std;
 
-
-
 // TryToInstallBuildDep - Try to install a single package              /*{{{*/
 // ---------------------------------------------------------------------
 /* This used to be inlined in DoInstall, but with the advent of regex package
@@ -1625,15 +1622,14 @@ void SigWinch(int)
 #endif
 }
                                                                        /*}}}*/
-
-bool DoUpgrade(CommandLine &CmdL)
+bool DoUpgrade(CommandLine &CmdL)                                      /*{{{*/
 {
    if (_config->FindB("APT::Get::UpgradeAllowNew", false) == true)
       return DoUpgradeWithAllowNewPackages(CmdL);
    else
       return DoUpgradeNoNewPackages(CmdL);
 }
-
+                                                                       /*}}}*/
 int main(int argc,const char *argv[])                                  /*{{{*/
 {
    CommandLine::Dispatch Cmds[] = {{"update",&DoUpdate},