]> git.parisson.com Git - deefuzzer.git/commitdiff
fix full charset to utf-8 (but need some <charset> info on the server for right descr...
authorGuillaume Pellerin <yomguy@parisson.com>
Mon, 20 Apr 2009 00:12:52 +0000 (00:12 +0000)
committerGuillaume Pellerin <yomguy@parisson.com>
Mon, 20 Apr 2009 00:12:52 +0000 (00:12 +0000)
README
deefuzz.py

diff --git a/README b/README
index 4608c195e950d14a0be1aa0c2596b22ea667046e..cea32df5c1c47383df20752c59562399e1be4157 100644 (file)
--- a/README
+++ b/README
@@ -1,7 +1,7 @@
 # README
 # ======
 
-deefuzz : an easy and light media streaming tool
+deefuzz : an easy and light media streaming tools
 
 
 # 1. Introduction
@@ -13,10 +13,10 @@ Here are the main features of the DeeFuzz Tools:
 
  * MP3 and OGG (audio & video) file streaming over internet
  * Full metadata encapsulation and management
- * RSS podcast feeding (current tracks and playlists)
- * M3U playlist feefing
- * Multi-theading architecture (multiple stations now authorized)
- * Optional random (shuffled) playlists
+ * RSS podcast generator (current tracks and playlists)
+ * M3U playlist generator
+ * Recursive, random (shuffled) or pre-defined playlists
+ * Multi-threaded architecture (multiple stations now authorized !)
  * VERY light and optimized streaming process !
 
 It is neccessary to provide a config file which sets all needed parameters
index c4c6783a3563d9a6535141fc2deef887a421af74..3f1bebf2ed651b7931781b27623c62692fb22ba4 100755 (executable)
@@ -124,6 +124,9 @@ class DeeFuzz(Thread):
         return xmltodict(conf_xml,'utf-8')
 
     def set_m3u_playlist(self):
+        m3u_dir = os.sep.join(self.m3u.split(os.sep)[:-1])
+        if not os.path.exists(m3u_dir):
+            os.makedirs(m3u_dir)
         m3u = open(self.m3u, 'w')
         i = 1
         m3u.write('#EXTM3U\n')
@@ -302,7 +305,7 @@ class Station(Thread):
 
         rss = PyRSS2Gen.RSS2(title = channel_subtitle,
                             link = self.channel.url,
-                            description = self.channel.description,
+                            description = self.channel.description.decode('utf-8'),
                             lastBuildDate = date_now,
                             items = rss_item_list,)
         f = open(rss_file, 'w')
@@ -413,9 +416,9 @@ class Station(Thread):
                 if not (title or artist):
                     song = str(self.current_media_obj[0].file_name)
                 else:
-                    song = artist + ' : ' + title.decode('utf-8')
+                    song = artist + ' : ' + title
 
-                self.channel.set_metadata({'song': str(song.encode('utf-8'))})
+                self.channel.set_metadata({'song': str(song.encode('utf-8')), 'charset': 'utf8',})
                 self.update_rss(self.current_media_obj, self.rss_current_file)
                 self.logger.write('DeeFuzzing this file on %s :  id = %s, index = %s, name = %s' \
                     % (self.short_name, self.id, self.index_list[self.id], self.current_media_obj[0].file_name))