chiark / gitweb /
cope with "NN - " as well as "NN" in track names
authorRichard Kettlewell <rjk@greenend.org.uk>
Mon, 1 Oct 2007 17:43:10 +0000 (18:43 +0100)
committerRichard Kettlewell <rjk@greenend.org.uk>
Mon, 1 Oct 2007 17:43:10 +0000 (18:43 +0100)
debian/changelog
lib/configuration.c

index d30aefb..17aae3b 100644 (file)
@@ -1,3 +1,9 @@
+disorder (1.5.99+dev3) unstable; urgency=low
+
+  * New version for newer Disobedience
+
+ -- Richard Kettlewell <rjk@greenend.org.uk>  Mon,  1 Oct 2007 18:29:43 +0100
+
 disorder (1.5.99+dev2) unstable; urgency=low
 
   * Install images for use by Disobedience
index 486a2ab..ae71d63 100644 (file)
@@ -1012,7 +1012,7 @@ static void config_postdefaults(struct config *c) {
   int n;
 
   static const char *namepart[][4] = {
-    { "title",  "/([0-9]+:)?([^/]+)\\.[a-zA-Z0-9]+$", "$2", "display" },
+    { "title",  "/([0-9]+ *[-:] *)?([^/]+)\\.[a-zA-Z0-9]+$", "$2", "display" },
     { "title",  "/([^/]+)\\.[a-zA-Z0-9]+$",           "$1", "sort" },
     { "album",  "/([^/]+)/[^/]+$",                    "$1", "*" },
     { "artist", "/([^/]+)/[^/]+/[^/]+$",              "$1", "*" },
@@ -1021,7 +1021,7 @@ static void config_postdefaults(struct config *c) {
 #define NNAMEPART (int)(sizeof namepart / sizeof *namepart)
 
   static const char *transform[][5] = {
-    { "track", "^.*/([0-9]+:)?([^/]+)\\.[a-zA-Z0-9]+$", "$2", "display", "" },
+    { "track", "^.*/([0-9]+ *[-:] *)?([^/]+)\\.[a-zA-Z0-9]+$", "$2", "display", "" },
     { "track", "^.*/([^/]+)\\.[a-zA-Z0-9]+$",           "$1", "sort", "" },
     { "dir",   "^.*/([^/]+)$",                          "$1", "*", "" },
     { "dir",   "^(the) ([^/]*)",                        "$2, $1", "sort", "i", },