Previous: PSF Basics, Up: Making Distribution Tar Files



3.2 PSFs for Source Packages

Here is an example PSF for the somepackage package, version 1.0.

     distribution
     product
     title The somepackage package
     description Source package for somepackage
     tag somepackage
     revision 1.0
     control_directory ""
     fileset
     tag somepackage-sources
     control_directory ""
     file_permissions -o 0  -g 0
     directory .
     file *
     exclude catalog

swign version 0.483 and later has a attribute replacement feature for the product.tag and revision attributes. They are determined from the current directory which must have the form tag-revision. The replacement strings are %__tag and %__revision. Hence here is a file, call it PSF.in, which will work for any future revision.

     # PSF.in  -- 'swign' Input file
     distribution
     product
     title The somepackage package
     description Source package for somepackage
     tag %__tag
     revision %__revision
     control_directory ""
     fileset
     tag somepackage-sources
     control_directory ""
     file_permissions -o 0  -g 0
     directory .
     file *
     exclude catalog

Here's how to use PSF.in

     cd somepackage-1.0
     swign -s PSF.in -u "Your GPG Name" @- | tar tvf -
     	# -or -
     cat PSF.in | swign -s - -u "Your GPG Name" @- | tar tvf -