Re: Rules.CSV format as alternative to htaccess

I think KISS - so I would keep it just one media type per row so that
we can process it without being too clever.

It's tricky to do "proper" content-negotiation according to the HTTP
specs in .htaccess (e.g. respecting the q= parameters), so the easiest
approach is probably something like

with special handling for text/html so it becomes the default for
browsers (unless there's a row with no content-type, which would
become the default).

I think to let Apache 2 do the content negotiation properly you would
need the actual files - perhaps that would be a way, with 0-length
dummy-files and MultiViews which you could internally redirect to
first  (and have outgoing HTTP redirections for) - but then you would
put much more constraints on which paths you could support without
causing a conflict.

On 1 March 2016 at 16:35, Ian Dunlop <> wrote:
> Hello,
> That's a great start Stian. I assume that the "" example is
> predicated on the csv file being present in a top level folder called
> "example" in the github repo (which the page does hint at - I'm just trying
> to understand how it all works). Can there be more than one media-type for a
> redirect? The examples only show one for each row.
> Does each redirect rule need an owner - should we add a column for email
> addresses to contact in case of issues?
> Cheers,
> Ian
> On 1 March 2016 at 11:44, Stian Soiland-Reyes
> <> wrote:
>> So here is my suggestion for rules.csv format and mechanism:
>> In short, a CSV file (which you can edit in your favourite spreadsheet
>> editor) could be used to auto generate corresponding .htaccess (of
>> everything is in order) in a w3id folder.
>> I added an optional column for content negotiatation. i think this could
>> cover 90% of existing .htaccess files (although they would not need to
>> "upgrade")
>> Then for transitions we can simply generate there rules.csv
>> files.
>> Ideas? Suggestions? Feel free to edit in the wiki as well!

Stian Soiland-Reyes, eScience Lab
School of Computer Science
The University of Manchester

Received on Thursday, 3 March 2016 11:05:37 UTC