[jhbuild/jjardon/gnome-modulesets2: 5/6] remove the now obsolete use_local_modulesets config variable



commit 8fef3336d99c73a763d0e7285c85cd8d4543e5dc
Author: Javier Jardón <jjardon gnome org>
Date:   Sun Mar 22 23:02:21 2015 +0000

    remove the now obsolete use_local_modulesets config variable

 doc/C/index.docbook  |   13 +------------
 jhbuild/main.py      |    3 ---
 jhbuild/moduleset.py |   39 ---------------------------------------
 3 files changed, 1 insertions(+), 54 deletions(-)
---
diff --git a/doc/C/index.docbook b/doc/C/index.docbook
index 4e3f0c9..c6612a1 100644
--- a/doc/C/index.docbook
+++ b/doc/C/index.docbook
@@ -1581,7 +1581,7 @@ Optional packages: (JHBuild will build the missing packages)
     <para>Boolean configuration variables are set using syntax as demonstrated
       in the following example:</para>
 
-<programlisting>use_local_modulesets = True</programlisting>
+<programlisting>nonetwork = True</programlisting>
 
     <para>String configuration variables are set using syntax as demonstrated
       in the following example:</para>
@@ -2344,17 +2344,6 @@ Optional packages: (JHBuild will build the missing packages)
             </simpara>
           </listitem>
         </varlistentry>
-        <varlistentry id="cfg-use-local-modulesets">
-          <term>
-            <varname>use_local_modulesets</varname>
-          </term>
-          <listitem>
-            <simpara>A boolean value that specifies to use modulesets that
-              were checked out along the JHBuild source code; instead of
-              downloading them on-the-fly from GNOME version control system.
-              Defaults to <constant>False</constant>.</simpara>
-          </listitem>
-        </varlistentry>
         <varlistentry id="cfg-xvfbargs">
           <term>
             <varname>xvfbargs</varname>
diff --git a/jhbuild/main.py b/jhbuild/main.py
index a5cf99b..a01b12c 100644
--- a/jhbuild/main.py
+++ b/jhbuild/main.py
@@ -30,7 +30,6 @@ import jhbuild.config
 import jhbuild.commands
 from jhbuild.errors import UsageError, FatalError
 from jhbuild.utils.cmds import get_output
-from jhbuild.moduleset import warn_local_modulesets
 
 
 if sys.platform == 'darwin':
@@ -149,8 +148,6 @@ def main(args):
         command = args[0]
         args = args[1:]
 
-    warn_local_modulesets(config)
-
     try:
         rc = jhbuild.commands.run(command, config, args, help=lambda: print_help(parser))
     except UsageError as exc:
diff --git a/jhbuild/moduleset.py b/jhbuild/moduleset.py
index 6461fe4..843bf70 100644
--- a/jhbuild/moduleset.py
+++ b/jhbuild/moduleset.py
@@ -554,42 +554,3 @@ def _parse_module_set(config, uri):
         _default_repo = repositories[default_repo]
 
     return moduleset
-
-def warn_local_modulesets(config):
-    if config.use_local_modulesets:
-        return
-
-    moduleset_local_path = os.path.join(SRCDIR, 'modulesets')
-    if not os.path.exists(moduleset_local_path):
-        # moduleset-less checkout
-        return
-
-    if not os.path.exists(os.path.join(moduleset_local_path, '..', '.git')):
-        # checkout was not done via git
-        return
-
-    if type(config.moduleset) == type([]):
-        modulesets = config.moduleset
-    else:
-        modulesets = [ config.moduleset ]
-
-    if not [x for x in modulesets if x.find('/') == -1]:
-        # all modulesets have a slash; they are URI
-        return
-
-    try:
-        git_diff = get_output(['git', 'diff', 'origin/master', '--', '.'],
-                cwd=moduleset_local_path).strip()
-    except CommandError:
-        # git error, ignore
-        return
-
-    if not git_diff:
-        # no locally modified moduleset
-        return
-
-    logging.info(
-            _('Modulesets were edited locally but JHBuild is configured '\
-              'to get them from the network, perhaps you need to add '\
-              'use_local_modulesets = True to your %s.' % config.filename))
-


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]