<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>issues/issue-3f40f8ae821055bb2ef81f250a54a25a32fbe173.yaml</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -5,8 +5,8 @@ type: :feature
 component: Ruxtape
 release: 
 reporter: ch0wda &lt;joshua.schairbaum@gmail.com&gt;
-status: :unstarted
-disposition: 
+status: :closed
+disposition: :fixed
 creation_time: 2008-09-12 13:48:26.876316 Z
 references: []
 
@@ -16,3 +16,11 @@ log_events:
   - ch0wda &lt;joshua.schairbaum@gmail.com&gt;
   - created
   - &quot;&quot;
+- - 2008-09-12 23:22:59.690314 Z
+  - ch0wda &lt;joshua.schairbaum@gmail.com&gt;
+  - changed status from unstarted to in_progress
+  - Gonna make sure that all the directories are able to be written to.
+- - 2008-09-13 12:44:14.727928 Z
+  - ch0wda &lt;joshua.schairbaum@gmail.com&gt;
+  - closed with disposition fixed
+  - just a simple check for File.writable?</diff>
      <filename>issues/issue-6282bb28aa9e2acb8fb4466067891c557115aff7.yaml</filename>
    </modified>
    <modified>
      <diff>@@ -29,6 +29,7 @@ module Ruxtape::Models
         values = self.values
         File.open(CONFIG_FILE, &quot;w&quot;) { |f| YAML.dump(values.merge(configs), f) }
       end
+      def writable?; File.writable?(CONFIG_FILE); end
       def admin?(ident)
         if setup?
           values[:openid] == ident
@@ -50,6 +51,7 @@ module Ruxtape::Models
         Dir.glob(&quot;#{Ruxtape::MP3_PATH}/*.mp3&quot;) { |mp3| songs &lt;&lt; Song.new(mp3) }
         songs.sort
       end
+      def writable?; Config.writable? &amp;&amp; Song.writable?; end
       def song_count; Dir.glob(&quot;#{Ruxtape::MP3_PATH}/*.mp3&quot;).length; end
       def length 
         minutes, seconds = 0,0
@@ -72,16 +74,13 @@ module Ruxtape::Models
         self.title, self.artist, self.length, self.tracknum = mp3.tag.title, mp3.tag.artist, mp3.length, mp3.tag.tracknum
       end
     end
-
     def self.filename_to_path(filename); File.join(Ruxtape::MP3_PATH, filename); end
-
+    def self.writable?; File.writable?(Ruxtape::MP3_PATH); end
     def delete; File.delete(self.path); end
-
     def time
       minutes = (length/60).to_i; seconds = (((length/60) - minutes) * 60).to_i
       &quot;#{minutes}:#{seconds}&quot;
     end
-
     def update(attrs)
       Mp3Info.open(self.path) do |mp3|
         mp3.tag.title = attrs[:title] if attrs[:title]
@@ -90,7 +89,6 @@ module Ruxtape::Models
       end
     end
     def url_path; &quot;/songs/#{URI.escape(File.basename(path))}&quot;; end
-
     def &lt;=&gt;(other)
       self.tracknum &lt;=&gt; other.tracknum
     end
@@ -100,11 +98,13 @@ end
 module Ruxtape::Controllers
   class Index &lt; R '/'
     def get
-      if Config.setup? 
+      if Config.setup? &amp;&amp; Mixtape.writable?
         @songs = Mixtape.playlist
         render(:index) 
-      else 
+      elsif Mixtape.writable?
         render(:setup)
+      else
+        render(:writable)
       end
     end
   end
@@ -319,6 +319,18 @@ module Ruxtape::Views
     end
   end
 
+  def writable
+    div.content! do 
+      h1 &quot;System Problem&quot;
+      p &quot;Make sure these folders are writable by the process Ruxtape runs as:&quot;
+      ul do 
+        @dirs.each do |dir|
+          li dir
+        end
+      end
+    end
+  end
+
   def admin
     link(:rel =&gt; 'stylesheet', :type =&gt; 'text/css',
          :href =&gt; '/assets/inline-player.css', :media =&gt; 'screen' )</diff>
      <filename>ruxtape.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>794c005ad65fa5484a58fe1da748dc7caea6ec16</id>
    </parent>
  </parents>
  <author>
    <name>Josh Schairbaum</name>
    <email>joshua.schairbaum@gmail.com</email>
  </author>
  <url>http://github.com/ch0wda/ruxtape/commit/aea2969fdb5d57ead69878865d29e7eb549be2ef</url>
  <id>aea2969fdb5d57ead69878865d29e7eb549be2ef</id>
  <committed-date>2008-09-13T05:44:59-07:00</committed-date>
  <authored-date>2008-09-13T05:44:59-07:00</authored-date>
  <message>checks to make sure that the proper directories are writable?</message>
  <tree>310260fce83acd24b175477a3019d3719d573854</tree>
  <committer>
    <name>Josh Schairbaum</name>
    <email>joshua.schairbaum@gmail.com</email>
  </committer>
</commit>
