First, I'll ask the obvious question - why do you want this? Is there
a feature of fpm missing?
Second, fpm implements debian package building without the use of
*any* debian tools. It doesn't use any 'debian' directory, and it
never runs dpkg-buildpackage, debuild, dh_make, or any related tools.
This allows two great benefits - first, that you can build deb
packages on any machine for any platform since there is no requirement
for debian's tools. Second, that because fpm doesn't use debian
tooling, you aren't burdened by the many (possibly invasive and
destructive) 'debian policy' decisions that are enforced and applied
by debian's package tools.
Finally, how to achieve what you ask. Currently the only file fpm will
generate is the 'control' file to put into the package during
building. Under normal circumstances for 'debuild' and
'dpkg-buildpackage' you'll need a 'rules' file and several other
things before it will know how to build a package.
You can certainly save the 'control' file somewhat hackishly using
EDITOR env var to copy the file out during package building:
EDITOR='sh -c "cp \$1 /tmp/control" -' fpm --edit -s dir -t deb -n
example /etc/motd
Example:
% EDITOR='sh -c "cp \$1 /tmp/control" -' fpm --edit -s dir -t deb -n
example /etc/motd
Created deb package {"path":"example_1.0_amd64.deb"}
% cat /tmp/control
Package: example
Version: 1.0
License: unknown
Vendor: jls@pork
Architecture: amd64
Maintainer: <jls@pork>
Installed-Size: 0
#Pre-Depends:
Section: default
Priority: extra
Homepage:
http://example.com/no-uri-given
Description: no description given
Let me know if you need any other help! :)
-Jordan