Skip to content

Commit

Permalink
Merge pull request #274 from projecthydra/append_mime_types
Browse files Browse the repository at this point in the history
Append MIME types in the install generator. Fixes samvera/hydra-pcdm#132
  • Loading branch information
jcoyne committed Jul 17, 2015
2 parents 4c8263e + 39fd28f commit ad7644e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions hydra-core/lib/generators/hydra/head_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ def create_configuration_files

def create_conneg_configuration
file_path = "config/initializers/mime_types.rb"
inject_into_file file_path, :before => /\Z/ do
"\nMime::Type.register \"application/n-triples\", :nt" +
"\nMime::Type.register \"application/json\", :jsonld" +
"\nMime::Type.register \"text/turtle\", :ttl"
append_to_file file_path do
"Mime::Type.register \"application/n-triples\", :nt\n" +
"Mime::Type.register \"application/json\", :jsonld\n" +
"Mime::Type.register \"text/turtle\", :ttl"
end
end

Expand Down

0 comments on commit ad7644e

Please sign in to comment.