Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Rack::TryStatic for static public files. #74

Closed
wants to merge 1 commit into from
Closed

Conversation

ntalbott
Copy link
Contributor

Rack::TryStatic will attempt to load paths from public before
passing them on to serve.

Also has more graceful handling for the case of a missing compass
config file.

Should fix #36, but I'd really appreciate review.

Rack::TryStatic will attempt to load paths from public before
passing them on to serve.

Also has more graceful handling for the case of a missing compass
config file.
@ghost ghost assigned ntalbott Apr 13, 2012
@jlong
Copy link
Owner

jlong commented Feb 23, 2013

Hey @ntalbott. What does this patch give us over just using Rack::Directory? Would moving Rack::Directory to the front of the cascade solve the same problem?

Also, I don't think this will do anything for #36. Unfortunately serve export doesn't load the middleware that you are using from config.ru. We should figure out a way to fix this.

@jlong
Copy link
Owner

jlong commented Feb 23, 2013

Oh, I see. Rack::Directory needs to go last otherwise you get directory indexes when an index file exists. I've added a version of this in master.

@jlong jlong closed this Feb 23, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

serve export overwrites html files without warning
2 participants