summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoshua Ismael Haase Hernández <hahj87@gmail.com>2011-02-14 01:29:33 -0600
committerJoshua Ismael Haase Hernández <hahj87@gmail.com>2011-02-14 01:29:33 -0600
commit6203dc2fc926781db694ca2383b1e44e2c5469c7 (patch)
tree6aed6b1417578e7d35655fade98f08587a492ba3
parent2321a53d35a9736b8c5c715ca40a9af69b1bf64e (diff)
- filter.py:
* Makes a blacklist for rsync - pato2.py: * Has more functions
-rw-r--r--filter.py6
-rw-r--r--pato2.py2
2 files changed, 6 insertions, 2 deletions
diff --git a/filter.py b/filter.py
index b51dba8..14ae31e 100644
--- a/filter.py
+++ b/filter.py
@@ -1,4 +1,4 @@
-#! /usr/bin/python
+ #! /usr/bin/python
#-*- encoding: utf-8 -*-
import commands
import os
@@ -79,3 +79,7 @@ def generate_exclude_list_from_blacklist(packages_iterable, blacklisted_names,
except IOError:
printf("%s wasnt written" % blacklist_file)
+if name == "__main__":
+ a=run_rsync(rsync_list_command)
+ packages=get_file_list_from_rsync_output(a)
+ generate_exclude_list_from_blacklist(packages,listado(blacklist))
diff --git a/pato2.py b/pato2.py
index 125ae8c..97eec9d 100644
--- a/pato2.py
+++ b/pato2.py
@@ -198,7 +198,7 @@ def generate_rsync_command(base_command, dir_list, destdir=repodir,
mirror_name + mirror_path + dir_list, destdir))
return " ".join((base_command, mirror_name + mirror_path + dir_list, destdir))
-def run_rsync(base_for_rsync=rsync_list_command, dir_list_for_rsync=(repo_list + dir_list),
+def run_rsync(base_for_rsync, dir_list_for_rsync=(repo_list + dir_list),
debug=verbose):
""" Runs rsync and gets returns it's output """
cmd = str(generate_rsync_command(rsync_list_command, (repo_list + dir_list)))