1
0
mirror of https://github.com/jordansissel/fpm synced 2025-08-26 03:34:35 +02:00
fpm/templates/deb.erb
Jordan Sissel a91dc224bf - Patch from jpluscplusm to work around misfeatures in debian's control
file regarding multiline descriptions.
2011-06-20 16:58:53 -07:00

28 lines
969 B
Plaintext

Package: <%= name %>
Version: <%= "#{epoch}:" if epoch %><%= version %><%= iteration && '-'+iteration.to_s %>
Architecture: <%= architecture %>
Maintainer: <%= maintainer or "<unknown>" %>
<% if !dependencies.empty? -%>
<% properdeps = dependencies.collect { |d| fix_dependency(d) }.flatten -%>
Depends: <%= properdeps.flatten.join(", ") %>
<% end -%>
<% if !provides.empty? -%>
Provides: <%= provides.join(", ") -%>
<% end -%>
<% if !replaces.empty? -%>
<% properrepl = replaces.collect { |d| fix_dependency(d) }.flatten -%>
Replaces: <%= properrepl.flatten.join(", ") %>
<% end -%>
Standards-Version: 3.9.1
Section: <%= category or "unknown" %>
Priority: extra
Homepage: <%= url or "http://nourlgiven.example.com/" %>
Description: <%= name %> (FPM-generated package)
<% max_len = 74 -%>
<% if description -%>
<%= description.gsub(/^$/, ".").gsub(/(.{1,#{max_len}})( +|$)\n?|(.{#{max_len}})/," \\1\\3\n") %>
<% else -%>
<%= "no description given" %>
<% end -%>