gbp-import-srpm(1)

πŸ’– gbp-import-srpm β€” git-buildpackage Manual, bestie edition πŸ’–

okay so. picture this: you got a source RPM. you want it in a Git repo. you do NOT want to do it by hand. enter gbp import-srpm, my beloved. this page is the gbp-import-srpm(1) manual, but make it make sense. πŸ¦‹


✨ NAME ✨

gbp-import-srpm β€” import source RPM packages into a Git repository. that's it. that's the whole job. slay. πŸ’…


🌸 SYNOPSIS 🌸

gbp import-srpm [--version] [--help] [--verbose] [--color=[auto|on|off]]
                [--color-scheme= COLOR_SCHEME] [--vendor= VENDOR]
                [--allow-same-versions] [--author-is-committer]
                [--packaging-branch= BRANCH-NAME] [--packaging-tag= TAG-
                FORMAT] [--skip-packaging-tag] [--packaging-dir=
                DIRECTORY] [--filter= PATTERN] [--keyid= GPG-KEYID]
                [--[no-]create-missing-branches] [--[no-]pristine-tar]
                [--[no-]sign-tags] [--upstream-branch= BRANCH-NAME]
                [--upstream-tag= TAG-FORMAT] [--upstream-vcs-tag= TAG-
                FORMAT] [--native] [--repo-user= [GIT|DEBIAN]]
                [--repo-email= [GIT|DEBIAN]] SRPM | DIRECTORY [target]
gbp import-srpm [options] URL [target]

so you literally hand it an SRPM, or a DIRECTORY, or a URL, and optionally a target. and it eats. πŸ“


πŸ‘‘ DESCRIPTION πŸ‘‘

ngl, this is the glow-up you've been waiting for. gbp import-srpm imports an RPM source package into a Git repository, notes the package version in the commit logs, and commits the change. it's giving ✨automation✨.

the way it just knows things? iconic. all information, including package name, version and upstream source, is automatically detected from the source package. but bestie, you're the main character β€” you can override the location of the new repository by optionally specifying the target argument, no cap. 🫢

the tool supports importing both archived (src.rpm files) or unpacked (directory) source RPMs. and YES it also imports from http(s)-URLs. versatile queen. 🌈


πŸ’… OPTIONS πŸ’…

here's the menu, bestie. every single one. no skipping, i would never do that to you.

  • --version β€” Print version of the program, i.e. version of the git-buildpackage suite. gotta know what era of the suite you're in. ⭐
  • -v, --verbose β€” Verbose execution. it tells you EVERYTHING. let her yap. πŸ—£οΈ
  • -h, --help β€” Print help and exit. the "wait what was that flag again" button. 😭
  • --color=[auto|on|off] β€” Whether to use colored output. aesthetic matters. πŸŽ€
  • --color-scheme=COLOR_SCHEME β€” Colors to use in output (when color is enabled). The format for COLOR_SCHEME is '<debug>:<info>:<warning>:<error>'. Numerical values and color names are accepted, empty fields imply the default color. For example, --git-color-scheme='cyan:34::' would show debug messages in cyan, info messages in blue and other messages in default (i.e. warning and error messages in red). fully customizing your terminal's vibe check fr fr. 🌈
  • --vendor=VENDOR β€” Distribution vendor name. who's your distro parent, basically. πŸ‘‘
  • --upstream-branch=BRANCH-NAME β€” The branch in the Git repository the upstream sources are put onto. Default is upstream. the classic. πŸ’œ
  • --packaging-branch=BRANCH-NAME β€” The branch in the Git repository the packaging files are put onto. Default is master. yes, master, she said what she said. πŸ’€
  • --[no-]sign-tags β€” GPG sign all created tags. put a little signature on it like a perfumed letter. πŸ’–
  • --keyid=GPG-KEYID β€” Use this keyid for gpg signing tags. which key is doing the signing today. πŸ”₯
  • --packaging-tag=TAG-FORMAT β€” Use this tag format when tagging released versions, default is %(vendor)s/%(version)s. ✨
  • --skip-packaging-tag β€” Do not create packaging tag after importing the packaging files. sometimes we simply don't tag. we skip. slay the urge. πŸ™ˆ
  • --upstream-tag=TAG-FORMAT β€” Use this tag format when tagging upstream versions, default is upstream/%(version)s. πŸ’…
  • --upstream-vcs-tag=TAG-NAME β€” Add TAG-FORMAT as an additional parent of the commit of the upstream tarball. Useful when upstream uses git and you want to link to its revision history. TAG-FORMAT can be a pattern similar to what --upstream-tag supports. it's giving connected lore. πŸ”—
  • --git-packaging-dir=DIRECTORY β€” Subdirectory where to put the RPM packaging files. tuck them away in their little room. 🏠
  • --filter=PATTERN β€” Filter out files glob-matching pattern. Can be given multiple times. bye bye unwanted files. πŸ‘‹
  • --pristine-tar β€” Generate pristine-tar delta file. ✨
  • --allow-same-version β€” Allow one to re-import a package with an already existing version. This will not re-import the upstream sources - only packaging files will be re-imported. recycling is self-care. ♻️
  • --author-is-committer β€” Use the author identity as the committer when importing upstream sources and packaging files. one person, both roles, main character energy. πŸ‘‘
  • --[no-]create-missing-branches β€” Create missing upstream and/or packaging branch if missing. if she's not there, make her. πŸ¦‹
  • --orphan-packaging β€” Import packaging files into an orphan branch that will not be based on the upstream branch. Useful if you want to maintain (non-native) package using the 'orphan-packaging' model. This option have no effect if --native is used. aka she stands alone. 🫢
  • --native β€” Treat the package as native package. No separate upstream branch or upstream tags will be created. no upstream, no tags, just the package. minimalist. 🀍
  • --repo-user=[GIT|DEBIAN] β€” When set to DEBIAN use the DEBFULLNAME environment variable to set the user.name Git configuration otherwise use Git's defaults. Only affects newly created repos. πŸ‘€
  • --repo-email=[GIT|DEBIAN] β€” When set to DEBIAN use the DEBEMAIL environment variable to set the user.email Git configuration otherwise use Git's defaults. Only affects newly created repos. πŸ“§

πŸ“š CONFIGURATION FILES πŸ“š

Several gbp.conf files are parsed to set defaults for the above command-line arguments. See the gbp.conf(5) manpage for details. your defaults live there, go visit them. 🏑


πŸ” SEE ALSO πŸ”

go read these too, bestie, we support women's wrongs and also women's documentation:


πŸŽ€ AUTHOR πŸŽ€

Markus Lehtonen <markus.lehtonen@linux.intel.com> β€” thank you for your service, king. 🫑


that's the whole page bestie!! you read every single line and i'm so proud of you. now go import an SRPM and be iconic about it. πŸ’–βœ¨

git-buildpackage Manual Β· 26 May 2026 Β· gbp-import-srpm(1) β€” mwah, go forth and commit, and remember: if the docs confuse you, it's not a you problem, it's a manpage problem. πŸ’…πŸŒΈπŸ¦‹

πŸ“¦ where this page comes from