X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=daklib%2Fextensions.py;h=88de8700a9d16d2a5060c8623909bfc463b136c5;hb=cd5b29ddfd8de263c085f494b9573d683913f6f3;hp=9befa7bf6c427984968b9ad42c336c1d9ef9ffee;hpb=06b17e68fd4a76e7a12f741f26654e55bff05c79;p=dak.git diff --git a/daklib/extensions.py b/daklib/extensions.py old mode 100644 new mode 100755 index 9befa7bf..88de8700 --- a/daklib/extensions.py +++ b/daklib/extensions.py @@ -1,9 +1,12 @@ #!/usr/bin/env python -# Utility functions for extensions -# Copyright (C) 2008 Anthony Towns +""" +Utility functions for extensions -################################################################################ +@contact: Debian FTP Master +@copyright: 2008 Anthony Towns +@license: GNU General Public License version 2 or later +""" # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -19,15 +22,20 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -################################################################################ - dak_functions_to_replace = {} dak_replaced_functions = {} -def replace_dak_function(module,name): - """Decorator to make a function replace a standard dak function - in a given module. The replaced function will be provided as - the first argument.""" +def replace_dak_function(module, name): + """ + Decorator to make a function replace a standard dak function + in a given module. + + @type module: string + @param module: name of module where replaced function is in + + @type name: string + @param name: name of the function to replace + """ def x(f): def myfunc(*a,**kw):