chiark / gitweb /
Dgit.pm: Introduce $deliberately_re and use it everywhere
[dgit.git] / Debian / Dgit.pm
index 5953490..3f2988e 100644 (file)
@@ -17,7 +17,8 @@ BEGIN {
     @EXPORT      = qw(debiantag server_branch server_ref
                       stat_exists git_for_each_ref
                       git_for_each_tag_referring
-                      $package_re $component_re $branchprefix
+                      $package_re $component_re $deliberately_re
+                      $branchprefix
                       initdebug enabledebug enabledebuglevel
                       printdebug debugcmd
                       $debugprefix *debuglevel *DEBUG
@@ -30,6 +31,7 @@ our @EXPORT_OK;
 
 our $package_re = '[0-9a-z][-+.0-9a-z]*';
 our $component_re = '[0-9a-zA-Z][-+.0-9a-zA-Z]*';
+our $deliberately_re = "(?:TEST-)?$package_re";
 our $branchprefix = 'dgit';
 
 # policy hook exit status bits