aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSlava Bacherikov <slava@bacher09.org>2012-08-13 20:42:36 +0300
committerSlava Bacherikov <slava@bacher09.org>2012-08-13 20:42:36 +0300
commit9071abf80462b3e692089ed9eb0b51ff3ed04b96 (patch)
treee9b68f182fc73e8a417b58cceab4bfe2700500d7
parentChanges in maintainers template (diff)
downloadgentoo-packages-9071abf80462b3e692089ed9eb0b51ff3ed04b96.tar.gz
gentoo-packages-9071abf80462b3e692089ed9eb0b51ff3ed04b96.tar.bz2
gentoo-packages-9071abf80462b3e692089ed9eb0b51ff3ed04b96.zip
Add commands for some utils
-rw-r--r--gpackages/apps/packages/management/commands/addmising.py17
-rw-r--r--gpackages/apps/packages/management/commands/updateebuildmask.py17
2 files changed, 34 insertions, 0 deletions
diff --git a/gpackages/apps/packages/management/commands/addmising.py b/gpackages/apps/packages/management/commands/addmising.py
new file mode 100644
index 0000000..11e2214
--- /dev/null
+++ b/gpackages/apps/packages/management/commands/addmising.py
@@ -0,0 +1,17 @@
+from django.core.management.base import BaseCommand, CommandError
+from packages.scan import Scanner
+from optparse import make_option
+
+
+class Command(BaseCommand):
+ option_list = BaseCommand.option_list + (
+ make_option('--not-show-time',
+ action='store_false',
+ dest='show_time',
+ default=True,
+ help='Show time of scanning'),
+ )
+ args = ''
+ help = 'Will add missing ebuilds'
+ def handle(self, *args, **options):
+ Scanner(**options).add_mising_ebuilds()
diff --git a/gpackages/apps/packages/management/commands/updateebuildmask.py b/gpackages/apps/packages/management/commands/updateebuildmask.py
new file mode 100644
index 0000000..a26554d
--- /dev/null
+++ b/gpackages/apps/packages/management/commands/updateebuildmask.py
@@ -0,0 +1,17 @@
+from django.core.management.base import BaseCommand, CommandError
+from packages.scan import Scanner
+from optparse import make_option
+
+
+class Command(BaseCommand):
+ option_list = BaseCommand.option_list + (
+ make_option('--not-show-time',
+ action='store_false',
+ dest='show_time',
+ default=True,
+ help='Show time of scanning'),
+ )
+ args = ''
+ help = 'Will add missing ebuilds'
+ def handle(self, *args, **options):
+ Scanner(**options).update_ebuild_mask()