localpkg helper script for fedpkg
Martin Langhoff
martin.langhoff at gmail.com
Tue Jan 25 16:11:13 EST 2011
If you are using or experimenting with fedpkg, I am putting some
simple helper bits in an accessory "localpkg" python script (at
http://dev.laptop.org/git/users/martin/localpkg or
git://dev.laptop.org/users/martin/localpkg ).
It currently has some helpers that allow me to build straight from a
git checkout. Useful for tiny, non-upstream codebases that pack their
own spec file.
Uses git-describe so it will build a properly named rpm if you are on
a named tag. Otherwise it builds with a version name that includes the
commit hash.
localpkg --help
usage: locakpkg [-h] [--path PATH] [-v] [-q]
{setver,git-source,help,publish-xs} ...
Local Packaging utility
optional arguments:
-h, --help show this help message and exit
--path PATH Directory to interact with instead of current dir
-v Run with verbose debug output
-q Run quietly only displaying errors
Targets:
{setver,git-source,help,publish-xs}
help Show usage
setver Set the version in spec from git describe
git-source Get the source for current HEAD from local git, and
update sources file
publish-xs Publish RPMs to XS repo
How do I use it?
- hack on the source
- commit. it is safe to ignore version change in spec file
- fixup the version in spec to match git-describe
$ localpkg setver
- get tarball from git, update 'sources' file
$ localpkg git-source
- build the rpms, locally or on koji - here I request a local build
$ fedpkg local
- copy to the right spots
$ localpkg publish-xs
These things are fairly "local" -- hence no fedpkg patches of interest
I suspect.
cheers,
m
--
martin.langhoff at gmail.com
martin at laptop.org -- School Server Architect
- ask interesting questions
- don't get distracted with shiny stuff - working code first
- http://wiki.laptop.org/go/User:Martinlanghoff
More information about the Devel
mailing list