1 # SOME DESCRIPTIVE TITLE
2 # Copyright (C) YEAR Free Software Foundation, Inc.
3 # This file is distributed under the same license as the PACKAGE package.
4 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
9 "Project-Id-Version: PACKAGE VERSION\n"
10 "POT-Creation-Date: 2020-02-02 16:50+0000\n"
11 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
12 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13 "Language-Team: LANGUAGE <LL@li.org>\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
17 "Content-Transfer-Encoding: 8bit\n"
20 #: ../dgit.1:3 ../dgit.7:2 ../dgit-user.7.pod:1 ../dgit-nmu-simple.7.pod:1
21 #: ../dgit-maint-native.7.pod:1 ../dgit-maint-merge.7.pod:1
22 #: ../dgit-maint-gbp.7.pod:1 ../dgit-maint-debrebase.7.pod:1
23 #: ../dgit-downstream-dsc.7.pod:1 ../dgit-sponsorship.7.pod:1
24 #: ../dgit-maint-bpo.7.pod:1 ../git-debrebase.1.pod:1 ../git-debrebase.5.pod:1
25 #: ../git-debpush.1.pod:1
31 #: ../dgit.1:1575 ../dgit.7:23 ../dgit-user.7.pod:447
32 #: ../dgit-nmu-simple.7.pod:137 ../dgit-maint-native.7.pod:126
33 #: ../dgit-maint-merge.7.pod:524 ../dgit-maint-gbp.7.pod:136
34 #: ../dgit-maint-debrebase.7.pod:782 ../dgit-downstream-dsc.7.pod:352
35 #: ../dgit-sponsorship.7.pod:321 ../dgit-maint-bpo.7.pod:140
36 #: ../git-debrebase.1.pod:634 ../git-debrebase.5.pod:678
37 #: ../git-debpush.1.pod:261
43 #: ../dgit-user.7.pod:5 ../dgit-maint-native.7.pod:5
44 #: ../dgit-maint-merge.7.pod:5 ../dgit-maint-gbp.7.pod:5
45 #: ../dgit-maint-debrebase.7.pod:5 ../dgit-downstream-dsc.7.pod:5
46 #: ../dgit-maint-bpo.7.pod:5 ../git-debrebase.5.pod:5
51 #: ../dgit-maint-native.7.pod:37 ../dgit-maint-gbp.7.pod:16
52 #: ../dgit-maint-debrebase.7.pod:38
54 "Benefit from dgit's safety catches. In particular, ensure that your upload "
55 "always matches exactly your git HEAD."
59 #: ../dgit-maint-merge.7.pod:47 ../dgit-maint-debrebase.7.pod:61
60 msgid "INITIAL DEBIANISATION"
64 #: ../dgit-maint-merge.7.pod:49 ../dgit-maint-debrebase.7.pod:63
66 "This section explains how to start using this workflow with a new package. "
67 "It should be skipped when converting an existing package to this workflow."
71 #: ../dgit-maint-merge.7.pod:53 ../dgit-maint-merge.7.pod:362
72 #: ../dgit-maint-merge.7.pod:441 ../dgit-maint-debrebase.7.pod:67
73 #: ../dgit-maint-debrebase.7.pod:354
74 msgid "When upstream tags releases in git"
78 #: ../dgit-maint-merge.7.pod:55 ../dgit-maint-debrebase.7.pod:69
80 "Suppose that the latest stable upstream release is 1.2.2, and this has been "
81 "tagged '1.2.2' by upstream."
85 #: ../dgit-maint-merge.7.pod:60 ../dgit-maint-debrebase.7.pod:74
88 " % git clone -oupstream https://some.upstream/foo.git\n"
90 " % git verify-tag 1.2.2\n"
91 " % git reset --hard 1.2.2\n"
92 " % git branch --unset-upstream\n"
97 #: ../dgit-maint-merge.7.pod:76 ../dgit-maint-debrebase.7.pod:90
100 " % git remote add -f origin salsa.debian.org:Debian/foo.git\n"
101 " % git push --follow-tags -u origin master\n"
106 #: ../dgit-maint-merge.7.pod:93 ../dgit-maint-debrebase.7.pod:102
107 msgid "Finally, you need an orig tarball:"
111 #: ../dgit-maint-merge.7.pod:97 ../dgit-maint-merge.7.pod:435
112 #: ../dgit-maint-debrebase.7.pod:106 ../dgit-maint-debrebase.7.pod:423
120 #: ../dgit-maint-merge.7.pod:101 ../dgit-maint-debrebase.7.pod:110
121 msgid "See git-deborig(1) if this fails."
125 #: ../dgit-maint-merge.7.pod:103 ../dgit-maint-debrebase.7.pod:112
127 "This tarball is ephemeral and easily regenerated, so we don't commit it "
128 "anywhere (e.g. with tools like pristine-tar(1))."
132 #: ../dgit-maint-merge.7.pod:123 ../dgit-maint-debrebase.7.pod:137
133 msgid "Using untagged upstream commits"
137 #: ../dgit-maint-merge.7.pod:127 ../dgit-maint-debrebase.7.pod:141
139 "Sometimes upstream does not tag their releases, or you want to package an "
140 "unreleased git snapshot. In such a case you can create your own upstream "
141 "release tag, of the form B<upstream/>I<ver>, where I<ver> is the upstream "
142 "version you plan to put in I<debian/changelog>. The B<upstream/> prefix "
143 "ensures that your tag will not clash with any tags upstream later creates."
147 #: ../dgit-maint-merge.7.pod:134 ../dgit-maint-debrebase.7.pod:148
149 "For example, suppose that the latest upstream release is 1.2.2 and you want "
150 "to package git commit ab34c21 which was made on 2013-12-11. A common "
151 "convention is to use the upstream version number 1.2.2+git20131211.ab34c21 "
152 "and so you could use"
156 #: ../dgit-maint-merge.7.pod:141 ../dgit-maint-debrebase.7.pod:155
159 " % git tag -s upstream/1.2.2+git20131211.ab34c21 ab34c21\n"
164 #: ../dgit-maint-merge.7.pod:145 ../dgit-maint-debrebase.7.pod:159
165 msgid "to obtain a release tag, and then proceed as above."
169 #: ../dgit-maint-merge.7.pod:149 ../dgit-maint-merge.7.pod:374
170 #: ../dgit-maint-merge.7.pod:466 ../dgit-maint-debrebase.7.pod:163
171 #: ../dgit-maint-debrebase.7.pod:366
172 msgid "When upstream releases only tarballs"
176 #: ../dgit-maint-merge.7.pod:166 ../dgit-maint-debrebase.7.pod:208
180 " upstream-branch = upstream\n"
181 " debian-branch = master\n"
182 " upstream-tag = upstream/%(version)s\n"
187 #: ../dgit-maint-merge.7.pod:171 ../dgit-maint-debrebase.7.pod:213
190 " sign-tags = True\n"
191 " pristine-tar = False\n"
192 " pristine-tar-commit = False\n"
197 #: ../dgit-maint-merge.7.pod:207 ../dgit-maint-debrebase.7.pod:191
200 " % git remote add -f origin salsa.debian.org:Debian/foo.git\n"
201 " % git push --follow-tags -u origin master upstream\n"
206 #: ../dgit-maint-merge.7.pod:215 ../dgit-maint-debrebase.7.pod:235
207 msgid "CONVERTING AN EXISTING PACKAGE"
211 #: ../dgit-maint-merge.7.pod:217 ../dgit-maint-debrebase.7.pod:237
213 "This section explains how to convert an existing Debian package to this "
214 "workflow. It should be skipped when debianising a new package."
218 #: ../dgit-maint-merge.7.pod:256 ../dgit-maint-debrebase.7.pod:268
221 " % git remote add -f upstream https://some.upstream/foo.git\n"
226 #: ../dgit-maint-merge.7.pod:269 ../dgit-maint-debrebase.7.pod:322
228 "To achieve this, you might need to delete I<debian/source/local-options>. "
229 "One way to have dgit check your progress is to run B<dgit build-source>."
233 #: ../dgit-maint-merge.7.pod:339 ../dgit-maint-debrebase.7.pod:476
234 msgid "BUILDING AND UPLOADING"
238 #: ../dgit-maint-merge.7.pod:360 ../dgit-maint-debrebase.7.pod:352
239 msgid "Obtaining the release"
243 #: ../dgit-maint-merge.7.pod:366 ../dgit-maint-debrebase.7.pod:358
246 " % git fetch --tags upstream\n"
251 #: ../dgit-maint-merge.7.pod:370 ../dgit-maint-debrebase.7.pod:362
253 "If you want to package an untagged upstream commit (because upstream does "
254 "not tag releases or because you want to package an upstream development "
255 "snapshot), see \"Using untagged upstream commits\" above."
259 #: ../dgit-maint-merge.7.pod:376 ../dgit-maint-debrebase.7.pod:368
261 "You will need the I<debian/gbp.conf> from \"When upstream releases only "
262 "tarballs\", above. You will also need your upstream branch. Above, we "
263 "pushed this to B<salsa.debian.org>. You will need to clone or fetch from "
264 "there, instead of relying on B<dgit clone>/B<dgit fetch> alone."
268 #: ../dgit-maint-merge.7.pod:381 ../dgit-maint-debrebase.7.pod:373
273 #: ../dgit-maint-merge.7.pod:385 ../dgit-maint-debrebase.7.pod:377
276 " % gbp import-orig ../foo_1.2.3.orig.tar.xz\n"
281 #: ../dgit-maint-merge.7.pod:389 ../dgit-maint-debrebase.7.pod:381
282 msgid "or if you have a working watch file"
286 #: ../dgit-maint-merge.7.pod:393 ../dgit-maint-debrebase.7.pod:385
289 " % gbp import-orig --uscan\n"
294 #: ../dgit-maint-merge.7.pod:429 ../dgit-maint-debrebase.7.pod:417
296 "If you obtained a tarball from upstream, you are ready to try a build. If "
297 "you merged a git tag from upstream, you will first need to generate a "
302 #: ../dgit-maint-merge.7.pod:439 ../dgit-maint-debrebase.7.pod:507
303 msgid "HANDLING DFSG-NON-FREE MATERIAL"
307 #: ../dgit-maint-merge.7.pod:468 ../dgit-maint-debrebase.7.pod:581
309 "The easiest way to handle this is to add a B<Files-Excluded> field to "
310 "I<debian/copyright>, and a B<uversionmangle> setting in I<debian/watch>. "
311 "See uscan(1). Alternatively, see the I<--filter> option detailed in gbp-"
316 #: ../dgit-maint-merge.7.pod:513 ../dgit-maint-gbp.7.pod:130
317 #: ../dgit-maint-debrebase.7.pod:586
318 msgid "INCORPORATING NMUS"
322 #: ../dgit-maint-merge.7.pod:528 ../dgit-maint-gbp.7.pod:140
323 #: ../dgit-maint-debrebase.7.pod:786 ../dgit-maint-bpo.7.pod:144
324 #: ../git-debpush.1.pod:266
329 #: ../dgit-maint-merge.7.pod:530 ../dgit-maint-debrebase.7.pod:788
331 "This tutorial was written and is maintained by Sean Whitton "
332 "<spwhitton@spwhitton.name>. It contains contributions from other dgit "
333 "contributors too - see the dgit copyright file."
337 #: ../dgit-maint-gbp.7.pod:32 ../dgit-maint-debrebase.7.pod:326
338 msgid "GIT CONFIGURATION"
342 #: ../dgit-maint-debrebase.7.pod:3
344 "dgit - tutorial for package maintainers, using a workflow centered around "
349 #: ../dgit-maint-debrebase.7.pod:7
351 "This document describes elements of a workflow for maintaining a non-native "
352 "Debian package using B<dgit>. We maintain the Debian delta as a series of "
353 "git commits on our master branch. We use git-debrebase(1) to shuffle our "
354 "branch such that this series of git commits appears at the end of the "
355 "branch. All the public git history is fast-forwarding, i.e., we do not "
356 "rewrite and force-push."
360 #: ../dgit-maint-debrebase.7.pod:14
361 msgid "Some advantages of this workflow:"
365 #: ../dgit-maint-debrebase.7.pod:20
367 "Manipulate the delta queue using the full power of git-rebase(1), instead of "
368 "relying on quilt(1), and without having to switch back and forth between "
369 "patches-applied and patches-unapplied branches when committing changes and "
370 "trying to build, as with gbp-pq(1)."
374 #: ../dgit-maint-debrebase.7.pod:27
376 "If you are using 3.0 (quilt), provide your delta queue as a properly "
377 "separated series of quilt patches in the source package that you upload to "
378 "the archive (unlike with dgit-maint-merge(7))."
382 #: ../dgit-maint-debrebase.7.pod:33
384 "Avoid the git tree being dirtied by the application or unapplication of "
385 "patches, as they are always applied."
389 #: ../dgit-maint-debrebase.7.pod:43
391 "Provide your full git history in a standard format on B<dgit-repos>, where "
392 "it can benefit downstream dgit users, such as people using dgit to do an NMU "
393 "(see dgit-nmu-simple(7) and dgit-user(7))."
397 #: ../dgit-maint-debrebase.7.pod:49
399 "Minimise the amount you need to know about 3.0 (quilt) in order to maintain "
400 "Debian source packages which use that format."
404 #: ../dgit-maint-debrebase.7.pod:54
406 "This workflow is appropriate for packages where the Debian delta contains "
407 "multiple pieces which interact, or which you don't expect to be able to "
408 "upstream soon. For packages with simple and/or short-lived Debian deltas, "
409 "use of git-debrebase(1) introduces unneeded complexity. For such packages, "
410 "consider the workflow described in dgit-maint-merge(7)."
414 #: ../dgit-maint-debrebase.7.pod:82
416 "The final command detaches your master branch from the upstream remote, so "
417 "that git doesn't try to push anything there, or merge unreleased upstream "
418 "commits. To maintain a copy of your packaging branch on B<salsa.debian.org> "
419 "in addition to B<dgit-repos>, you can do something like this:"
423 #: ../dgit-maint-debrebase.7.pod:95
425 "Now go ahead and Debianise your package. Make commits on the master branch, "
426 "adding things in the I<debian/> directory, or patching the upstream source. "
427 "For technical reasons, B<it is essential that your first commit introduces "
428 "the debian/ directory containing at least one file, and does nothing else.> "
429 "In other words, make a commit introducing I<debian/> before patching the "
434 #: ../dgit-maint-debrebase.7.pod:115
435 msgid "Comparing upstream's tarball releases"
439 #: ../dgit-maint-debrebase.7.pod:119
441 "The above assumes that you know how to build the package from git and that "
442 "doing so is straightforward."
446 #: ../dgit-maint-debrebase.7.pod:122
448 "If, as a user of the upstream source, you usually build from upstream "
449 "tarball releases, rather than upstream git tags, you will sometimes find "
450 "that the git tree doesn't contain everything that is in the tarball."
454 #: ../dgit-maint-debrebase.7.pod:127
456 "Additional build steps may be needed. For example, you may need your "
457 "I<debian/rules> to run autotools."
461 #: ../dgit-maint-debrebase.7.pod:130
463 "You can compare the upstream tarball release, and upstream git tag, within "
464 "git, by importing the tarball into git as described in the next section, "
465 "using a different value for 'upstream-tag', and then using git-diff(1) to "
466 "compare the imported tarball to the release tag."
470 #: ../dgit-maint-debrebase.7.pod:165
472 "Because we want to work in git, we need a virtual upstream branch with "
473 "virtual release tags. gbp-import-orig(1) can manage this for us. To begin"
477 #: ../dgit-maint-debrebase.7.pod:171
483 " % git checkout -b upstream\n"
484 " % gbp import-orig \\\n"
485 " --upstream-branch=upstream --debian-branch=master \\\n"
486 " --upstream-tag='upstream/%(version)s' \\\n"
487 " --sign-tags --no-pristine-tar \\\n"
488 " ../foo_1.2.2.orig.tar.xz\n"
489 " % git branch -f upstream\n"
494 #: ../dgit-maint-debrebase.7.pod:184
496 "This should leave you on the master branch. Next, our upstream branch "
497 "cannot be pushed to B<dgit-repos>, but since we will need it whenever we "
498 "import a new upstream version, we must push it somewhere. The usual choice "
499 "is B<salsa.debian.org>:"
503 #: ../dgit-maint-debrebase.7.pod:196
505 "You are now ready to proceed as above, making commits to the I<debian/> "
506 "directory and to the upstream source. As above, for technical reasons, B<it "
507 "is essential that your first commit introduces the debian/ directory "
508 "containing at least one file, and does nothing else.> In other words, make a "
509 "commit introducing I<debian/> before patching the upstream source."
513 #: ../dgit-maint-debrebase.7.pod:203
515 "A convenient way to ensure this requirement is satisfied is to start by "
516 "creating I<debian/gbp.conf>:"
520 #: ../dgit-maint-debrebase.7.pod:217
529 #: ../dgit-maint-debrebase.7.pod:222
530 msgid "and commit that:"
534 #: ../dgit-maint-debrebase.7.pod:226
537 " % git add debian/gbp.conf && git commit -m \"create gbp.conf\"\n"
542 #: ../dgit-maint-debrebase.7.pod:230
544 "Note that we couldn't create I<debian/gbp.conf> before now for the same "
545 "technical reasons which require our first commit to introduce I<debian/> "
546 "without patching the upstream source. That's why we had to pass a lot of "
547 "options to our first call to gbp-import-orig(1)."
551 #: ../dgit-maint-debrebase.7.pod:240
553 "If you have an existing git history that you have pushed to an ordinary git "
554 "server like B<salsa.debian.org>, we start with that. If you don't already "
555 "have it locally, you'll need to clone it, and obtain the corresponding orig."
556 "tar from the archive:"
560 #: ../dgit-maint-debrebase.7.pod:247
563 " % git clone salsa.debian.org:Debian/foo\n"
565 " % dgit setup-new-tree\n"
571 #: ../dgit-maint-debrebase.7.pod:254
573 "If you don't have any existing git history, or you have history only on the "
574 "special B<dgit-repos> server, we start with B<dgit clone>:"
578 #: ../dgit-maint-debrebase.7.pod:259
581 " % dgit clone foo\n"
587 #: ../dgit-maint-debrebase.7.pod:264
588 msgid "Then we make new upstream tags available:"
592 #: ../dgit-maint-debrebase.7.pod:272
594 "We now use a B<git debrebase convert-from-*> command to convert your "
595 "existing history to the git-debrebase(5) data model. Which command you "
596 "should use depends on some facts about your repository:"
600 #: ../dgit-maint-debrebase.7.pod:278
601 msgid "(A) There is no delta queue."
605 #: ../dgit-maint-debrebase.7.pod:280
606 msgid "If there do not exist any Debian patches, use"
610 #: ../dgit-maint-debrebase.7.pod:284 ../dgit-maint-debrebase.7.pod:296
613 " % git debrebase convert-from-gbp\n"
618 #: ../dgit-maint-debrebase.7.pod:288
619 msgid "(B) There is a delta queue, and patches are unapplied."
623 #: ../dgit-maint-debrebase.7.pod:290
625 "This is the standard git-buildpackage(1) workflow: there are Debian patches, "
626 "but the upstream source is committed to git without those patches applied. "
631 #: ../dgit-maint-debrebase.7.pod:300
633 "If you were not previously using dgit to upload your package (i.e. you were "
634 "not using the workflow described in dgit-maint-gbp(7)), and you happen to "
635 "have run B<dgit fetch sid> in this clone of the repository, you will need to "
636 "pass I<--fdiverged> to this command."
640 #: ../dgit-maint-debrebase.7.pod:305
641 msgid "(C) There is a delta queue, and patches are applied."
645 #: ../dgit-maint-debrebase.7.pod:307
650 #: ../dgit-maint-debrebase.7.pod:311
653 " % git debrebase convert-from-dgit-view\n"
658 #: ../dgit-maint-debrebase.7.pod:317
660 "Finally, you need to ensure that your git HEAD is dgit-compatible, i.e., it "
661 "is exactly what you would get if you deleted .git, invoked B<dpkg-"
662 "buildpackage -S>, and then unpacked the resultant source package."
666 #: ../dgit-maint-debrebase.7.pod:328
668 "git-debrebase(1) does not yet support using B<git merge> to merge divergent "
669 "branches of development (see \"OTHER MERGES\" in git-debrebase(5)). You "
670 "should configure git such that B<git pull> does not try to merge:"
674 #: ../dgit-maint-debrebase.7.pod:335
677 " % git config --local pull.rebase true\n"
682 #: ../dgit-maint-debrebase.7.pod:339
684 "Now when you pull work from other Debian contributors, git will rebase your "
685 "work on top of theirs."
689 #: ../dgit-maint-debrebase.7.pod:342
691 "If you use this clone for upstream development in addition to Debian "
692 "packaging work, you may not want to set this global setting. Instead, see "
693 "the B<branch.autoSetupRebase> and B<branch.E<lt>nameE<gt>.rebase> settings "
698 #: ../dgit-maint-debrebase.7.pod:347
699 msgid "IMPORTING NEW UPSTREAM RELEASES"
703 #: ../dgit-maint-debrebase.7.pod:349
705 "There are two steps: obtaining git refs that correspond to the new release, "
706 "and importing that release using git-debrebase(1)."
710 #: ../dgit-maint-debrebase.7.pod:389
711 msgid "Importing the release"
715 #: ../dgit-maint-debrebase.7.pod:393
718 " % git debrebase new-upstream 1.2.3\n"
723 #: ../dgit-maint-debrebase.7.pod:397
724 msgid "replacing I<1.2.3> with I<upstream/1.2.3> if you imported a tarball."
728 #: ../dgit-maint-debrebase.7.pod:399
730 "This invocation of git-debrebase(1) involves a git rebase. You may need to "
731 "resolve conflicts if the Debian delta queue does not apply cleanly to the "
732 "new upstream source."
736 #: ../dgit-maint-debrebase.7.pod:403
738 "If all went well, you can now review the merge of the new upstream release:"
742 #: ../dgit-maint-debrebase.7.pod:408
745 " git diff debian/1.2.2-1..HEAD -- . ':!debian'\n"
750 #: ../dgit-maint-debrebase.7.pod:412
752 "Also, diff with I<--name-status> and I<--diff-filter=ADR> to see just the "
753 "list of added or removed files, which is useful to determine whether there "
754 "are any new or deleted files that may need accounting for in your copyright "
759 #: ../dgit-maint-debrebase.7.pod:427
760 msgid "EDITING THE DEBIAN PACKAGING"
764 #: ../dgit-maint-debrebase.7.pod:429
765 msgid "Just make commits on master that change the contents of I<debian/>."
769 #: ../dgit-maint-debrebase.7.pod:431
770 msgid "EDITING THE DELTA QUEUE"
774 #: ../dgit-maint-debrebase.7.pod:433
775 msgid "Adding new patches"
779 #: ../dgit-maint-debrebase.7.pod:435
781 "Adding new patches is straightforward: just make commits touching only files "
782 "outside of the I<debian/> directory. You can also use tools like git-"
783 "revert(1), git-am(1) and git-cherry-pick(1)."
787 #: ../dgit-maint-debrebase.7.pod:439
788 msgid "Editing patches: starting a debrebase"
792 #: ../dgit-maint-debrebase.7.pod:441
794 "git-debrebase(1) is a wrapper around git-rebase(1) which allows us to edit, "
795 "re-order and delete patches. Run"
799 #: ../dgit-maint-debrebase.7.pod:446 ../dgit-maint-debrebase.7.pod:749
802 " % git debrebase -i\n"
807 #: ../dgit-maint-debrebase.7.pod:450
809 "to start an interactive rebase. You can edit, re-order and delete commits "
810 "just as you would during B<git rebase -i>."
814 #: ../dgit-maint-debrebase.7.pod:453
815 msgid "Editing patches: finishing a debrebase"
819 #: ../dgit-maint-debrebase.7.pod:455
821 "After completing the git rebase, your branch will not be a fast-forward of "
822 "the git HEAD you had before the rebase. This means that we cannot push the "
823 "branch anywhere. If you are ready to upload, B<dgit push> or B<dgit push-"
824 "source> will take care of fixing this up for you."
828 #: ../dgit-maint-debrebase.7.pod:461
830 "If you are not yet ready to upload, and want to push your branch to a git "
831 "remote such as B<salsa.debian.org>,"
835 #: ../dgit-maint-debrebase.7.pod:466
838 " % git debrebase conclude\n"
843 #: ../dgit-maint-debrebase.7.pod:470
845 "Note that each time you conclude a debrebase you introduce a pseudomerge "
846 "into your git history, which may make it harder to read. Try to do all of "
847 "the editing of the delta queue that you think will be needed for this "
848 "editing session in a single debrebase, so that there is a single debrebase "
853 #: ../dgit-maint-debrebase.7.pod:478
855 "You can use dpkg-buildpackage(1) for test builds. When you are ready to "
856 "build for an upload, use B<dgit sbuild>, B<dgit pbuilder> or B<dgit "
861 #: ../dgit-maint-debrebase.7.pod:482
863 "Upload with B<dgit push> or B<dgit push-source>. Remember to pass I<--new> "
864 "if the package is new in the target suite."
868 #: ../dgit-maint-debrebase.7.pod:485
870 "In some cases where you used B<git debrebase convert-from-gbp> since the "
871 "last upload, it is not possible for dgit to make your history fast-"
872 "forwarding from the history on B<dgit-repos>. In such cases you will have "
873 "to pass I<--overwrite> to dgit. git-debrebase will normally tell you if "
874 "this will be needed."
878 #: ../dgit-maint-debrebase.7.pod:491
880 "Right before uploading, if you did not just already do so, you might want to "
881 "have git-debrebase(1) shuffle your branch such that the Debian delta queue "
882 "appears right at the tip of the branch you will push:"
886 #: ../dgit-maint-debrebase.7.pod:497
890 " % dgit push-source\n"
895 #: ../dgit-maint-debrebase.7.pod:502
896 msgid "Note that this will introduce a new pseudomerge."
900 #: ../dgit-maint-debrebase.7.pod:504
902 "After dgit pushing, be sure to git push to B<salsa.debian.org>, if you're "
907 #: ../dgit-maint-debrebase.7.pod:509
908 msgid "Illegal material"
912 #: ../dgit-maint-debrebase.7.pod:511
914 "Here we explain how to handle material that is merely DFSG-non-free. "
915 "Material which is legally dangerous (for example, files which are actually "
916 "illegal) cannot be handled this way."
920 #: ../dgit-maint-debrebase.7.pod:515
923 "If you encounter possibly-legally-dangerous material in the upstream\n"
924 "source code you should seek advice. It is often best not to make a\n"
925 "fuss on a public mailing list (at least, not at first). Instead,\n"
926 "email your archive administrators. For Debian that is\n"
927 " To: dgit-owner@debian.org, ftpmaster@ftp-master.debian.org\n"
932 #: ../dgit-maint-debrebase.7.pod:521
933 msgid "DFSG-non-free: When upstream tags releases in git"
937 #: ../dgit-maint-debrebase.7.pod:523
939 "Our approach is to maintain a DFSG-clean upstream branch, and create tags on "
940 "this branch for each release that we want to import. We then import those "
941 "tags per \"Importing the release\", above. In the case of a new package, we "
942 "base our initial Debianisation on our first DFSG-clean tag."
946 #: ../dgit-maint-debrebase.7.pod:529
947 msgid "For the first upstream release that requires DFSG filtering:"
951 #: ../dgit-maint-debrebase.7.pod:533
954 " % git checkout -b upstream-dfsg 1.2.3\n"
955 " % git rm evil.bin\n"
956 " % git commit -m \"upstream version 1.2.3 DFSG-cleaned\"\n"
957 " % git tag -s 1.2.3+dfsg\n"
958 " % git checkout master\n"
963 #: ../dgit-maint-debrebase.7.pod:541
965 "Now either proceed with \"Importing the release\" on the 1.2.3+dfsg tag, or "
966 "in the case of a new package,"
970 #: ../dgit-maint-debrebase.7.pod:546
973 " % git branch --unset-upstream\n"
974 " % git reset --hard 1.2.3+dfsg\n"
979 #: ../dgit-maint-debrebase.7.pod:551
980 msgid "and proceed with \"INITIAL DEBIANISATION\"."
984 #: ../dgit-maint-debrebase.7.pod:553
986 "For subsequent releases (whether or not they require additional filtering):"
990 #: ../dgit-maint-debrebase.7.pod:558
993 " % git checkout upstream-dfsg\n"
994 " % git merge 1.2.4\n"
995 " % git rm further-evil.bin # if needed\n"
996 " % git commit -m \"upstream version 1.2.4 DFSG-cleaned\" # if needed\n"
997 " % git tag -s 1.2.4+dfsg\n"
998 " % git checkout master\n"
999 " % # proceed with \"Importing the release\" on 1.2.4+dfsg tag\n"
1004 #: ../dgit-maint-debrebase.7.pod:568
1006 "Our upstream-dfsg branch cannot be pushed to B<dgit-repos>, but since we "
1007 "will need it whenever we import a new upstream version, we must push it "
1008 "somewhere. Assuming that you have already set up an origin remote per the "
1013 #: ../dgit-maint-debrebase.7.pod:575
1016 " % git push --follow-tags -u origin master upstream-dfsg\n"
1021 #: ../dgit-maint-debrebase.7.pod:579
1022 msgid "DFSG-non-free: When upstream releases only tarballs"
1026 #: ../dgit-maint-debrebase.7.pod:588
1027 msgid "In the simplest case,"
1031 #: ../dgit-maint-debrebase.7.pod:592
1035 " % git merge --ff-only dgit/dgit/sid\n"
1040 #: ../dgit-maint-debrebase.7.pod:597
1042 "If that fails, because your branch and the NMUers' work represent divergent "
1043 "branches of development, you have a number of options. Here we describe the "
1048 #: ../dgit-maint-debrebase.7.pod:601
1050 "Note that you should not try to resolve the divergent branches by editing "
1051 "files in I<debian/patches>. Changes there would either cause trouble, or be "
1052 "overwritten by git-debrebase(1)."
1056 #: ../dgit-maint-debrebase.7.pod:605
1057 msgid "Rebasing your work onto the NMU"
1061 #: ../dgit-maint-debrebase.7.pod:609
1064 " % git rebase dgit/dgit/sid\n"
1069 #: ../dgit-maint-debrebase.7.pod:613
1071 "If the NMUer added new commits modifying the upstream source, you will "
1072 "probably want to debrebase before your next upload to tidy those up."
1076 #: ../dgit-maint-debrebase.7.pod:616
1078 "For example, the NMUer might have used git-revert(1) to unapply one of your "
1079 "patches. A debrebase can be used to strip both the patch and the reversion "
1080 "from the delta queue."
1084 #: ../dgit-maint-debrebase.7.pod:620
1085 msgid "Manually applying the debdiff"
1089 #: ../dgit-maint-debrebase.7.pod:622
1091 "If you cannot rebase because you have already pushed to B<salsa.debian.org>, "
1092 "say, you can manually apply the NMU debdiff, commit and debrebase. The next "
1093 "B<dgit push> will require I<--overwrite>."
1097 #: ../dgit-maint-debrebase.7.pod:627
1098 msgid "HINTS AND TIPS"
1102 #: ../dgit-maint-debrebase.7.pod:629
1103 msgid "Minimising pseudomerges"
1107 #: ../dgit-maint-debrebase.7.pod:631
1109 "Above we noted that each time you conclude a debrebase, you introduce a "
1110 "pseudomerge into your git history, which may make it harder to read."
1114 #: ../dgit-maint-debrebase.7.pod:634
1116 "A simple convention you can use to minimise the number of pseudomerges is to "
1117 "B<git debrebase conclude> only right before you upload or push to B<salsa."
1122 #: ../dgit-maint-debrebase.7.pod:638
1124 "It is possible, though much less convenient, to reduce the number of "
1125 "pseudomerges yet further. We debrebase only (i) when importing a new "
1126 "release, and (ii) right before uploading. Instead of editing the existing "
1127 "delta queue, you append fixup commits (and reversions of commits) that alter "
1128 "the upstream source to the required state. You can push and pull to and "
1129 "from B<salsa.debian.org> during this. Just before uploading, you debrebase, "
1130 "once, to tidy everything up."
1134 #: ../dgit-maint-debrebase.7.pod:646
1135 msgid "The debian/patches directory"
1139 #: ../dgit-maint-debrebase.7.pod:648
1141 "In this workflow, I<debian/patches> is purely an output of git-"
1142 "debrebase(1). You should not make changes there. They will either cause "
1143 "trouble, or be ignored and overwritten by git-debrebase(1)."
1147 #: ../dgit-maint-debrebase.7.pod:653
1149 "I<debian/patches> will often be out-of-date because git-debrebase(1) will "
1150 "only regenerate it when it needs to. So you should not rely on the "
1151 "information in that directory. When preparing patches to forward upstream, "
1152 "you should use git-format-patch(1) on git commits, rather than sending files "
1153 "from I<debian/patches>."
1157 #: ../dgit-maint-debrebase.7.pod:659
1158 msgid "Upstream branches"
1162 #: ../dgit-maint-debrebase.7.pod:661
1163 msgid "In this workflow, we specify upstream tags rather than any branches."
1167 #: ../dgit-maint-debrebase.7.pod:663
1169 "Except when (i) upstream releases only tarballs, (ii) we require DFSG "
1170 "filtering, or (iii) you also happen to be involved in upstream development, "
1171 "we do not maintain any local branch corresponding to upstream, except "
1172 "temporary branches used to prepare patches for forwarding, and the like."
1176 #: ../dgit-maint-debrebase.7.pod:669
1178 "The idea here is that from Debian's point of view, upstream releases are "
1179 "immutable points in history. We want to make sure that we are basing our "
1180 "Debian package on a properly identified upstream version, rather than some "
1181 "arbitrary commit on some branch. Tags are more useful for this."
1185 #: ../dgit-maint-debrebase.7.pod:675
1187 "Upstream's branches remain available as the git remote tracking branches for "
1188 "your upstream remote, e.g. I<remotes/upstream/master>."
1192 #: ../dgit-maint-debrebase.7.pod:678
1193 msgid "The first ever dgit push"
1197 #: ../dgit-maint-debrebase.7.pod:680
1199 "If this is the first ever dgit push of the package, consider passing I<--"
1200 "deliberately-not-fast-forward> instead of I<--overwrite>. This avoids "
1201 "introducing a new origin commit into your git history. (This origin commit "
1202 "would represent the most recent non-dgit upload of the package, but this "
1203 "should already be represented in your git history.)"
1207 #: ../dgit-maint-debrebase.7.pod:686
1208 msgid "Inspecting the history"
1212 #: ../dgit-maint-debrebase.7.pod:688
1214 "The git history made by git-debrebase can seem complicated. Here are some "
1215 "suggestions for helpful invocations of gitk and git. They can be adapted "
1216 "for other tools like tig(1), git-log(1), magit, etc."
1220 #: ../dgit-maint-debrebase.7.pod:692
1221 msgid "History of package in Debian, disregarding history from upstream:"
1225 #: ../dgit-maint-debrebase.7.pod:696
1228 " % gitk --first-parent\n"
1233 #: ../dgit-maint-debrebase.7.pod:698
1234 msgid "In a laundered branch, the delta queue is at the top."
1238 #: ../dgit-maint-debrebase.7.pod:702
1239 msgid "History of the packaging, excluding the delta queue:"
1243 #: ../dgit-maint-debrebase.7.pod:704
1246 " % gitk :/debian :!/debian/patches\n"
1251 #: ../dgit-maint-debrebase.7.pod:706
1252 msgid "Just the delta queue (i.e. Debian's changes to upstream):"
1256 #: ../dgit-maint-debrebase.7.pod:708
1259 " % gitk --first-parent -- :/ :!/debian\n"
1264 #: ../dgit-maint-debrebase.7.pod:710
1265 msgid "Full history including old versions of the delta queue:"
1269 #: ../dgit-maint-debrebase.7.pod:714
1272 " % gitk --date-order\n"
1277 #: ../dgit-maint-debrebase.7.pod:716
1279 "The \"Declare fast forward\" commits you see have an older history (usually, "
1280 "an older delta queue) as one parent, and a newer history as the other. --"
1281 "date-order makes gitk show the delta queues in the right order."
1285 #: ../dgit-maint-debrebase.7.pod:723
1286 msgid "Complete diff since the last upload:"
1290 #: ../dgit-maint-debrebase.7.pod:727
1293 " % git diff dgit/dgit/sid..HEAD -- :/ :!/debian/patches\n"
1298 #: ../dgit-maint-debrebase.7.pod:729
1299 msgid "This includes changes to upstream files."
1303 #: ../dgit-maint-debrebase.7.pod:733
1304 msgid "Interdiff of delta queue since last upload, if you really want it:"
1308 #: ../dgit-maint-debrebase.7.pod:735
1311 " % git debrebase make-patches\n"
1312 " % git diff dgit/dgit/sid..HEAD -- debian/patches\n"
1317 #: ../dgit-maint-debrebase.7.pod:738
1318 msgid "And of course there is:"
1322 #: ../dgit-maint-debrebase.7.pod:740
1325 " % git debrebase status\n"
1330 #: ../dgit-maint-debrebase.7.pod:742
1331 msgid "Alternative ways to start a debrebase"
1335 #: ../dgit-maint-debrebase.7.pod:744
1337 "Above we started an interactive debrebase by invoking git-debrebase(1) like "
1342 #: ../dgit-maint-debrebase.7.pod:753
1343 msgid "It is also possible to perform a non-interactive rebase, like this:"
1347 #: ../dgit-maint-debrebase.7.pod:757
1350 " % git debrebase -- [git-rebase options...]\n"
1355 #: ../dgit-maint-debrebase.7.pod:762
1357 "A third alternative is to have git-debrebase(1) shuffle all the Debian "
1358 "changes to the end of your branch, and then manipulate them yourself using "
1359 "git-rebase(1) directly. For example,"
1363 #: ../dgit-maint-debrebase.7.pod:768
1366 " % git debrebase\n"
1367 " % git rebase -i HEAD~5 # there are 4 Debian patches\n"
1372 #: ../dgit-maint-debrebase.7.pod:773
1374 "If you take this approach, you should be very careful not to start the "
1375 "rebase too early, including before the most recent pseudomerge. git-rebase "
1376 "without a base argument will often start the rebase too early, and should be "
1377 "avoided. Run git-debrebase instead. See also \"ILLEGAL OPERATIONS\" in git-"
1382 #: ../dgit-maint-debrebase.7.pod:784
1383 msgid "dgit(1), dgit(7), git-debrebase(1), git-debrebase(5)"