Skip to content
Bofu Chen edited this page Jan 5, 2020 · 32 revisions

Notes

  1. Add .buildinfo into local dev repository manually

    • .buildinfo is incuded in a changes file, so you will need it when running dput with a changes.
      • E.g., you want to migrate a package from distro1 to distro2, and you do not have the original source packages on hand.
    • .buildinfo is not included in a public repository by default because
      • It's only used for verifying that package is not modified manually, so it's secure.
      • It's not necessary for downloading binary or source package (.dsc).
      • So if you do not preserve it, you might have a trouble when running dput in the future.

Build BerryNet deb

  • Steps to upgrade to 3.8.0 release for gbp repo.

    gbp clone --pristine-tar --debian-branch=debian/sid git@github.com:DT42/BerryNet.git
    cd BerryNet
    uscan
    wget -O ../berrynet_3.8.0.orig.tar.gz https://github.com/DT42/BerryNet/archive/upstream/3.8.0.tar.gz
    gbp import-orig --pristine-tar ../berrynet_3.8.0.orig.tar.gz
    gbp dch
    git commit -a -s
    gbp buildpackage
    # modify package and commit.
    debclean ; gbp buildpackage
    gbp dch --release
    git commit -a -s
    gbp buildpackage --git-tag
    

Setup Development Repository

mini-dinstall

Please use the following command to update the repo

$ mini-dinstall -v --no-db -b -c .mini-dinstall.conf

It is needed to put a sign script /tmp/sign-release.sh

#!/bin/sh

rm -f Release.gpg
echo "PASSWORD" | gpg --no-tty --batch --passphrase-fd=0 --default-key BDC8D74E641C2BC34632A5F3AB62C67FC0C4CC4C --detach-sign -o Release.gpg "$1"

Working Flow

  1. Sign changes file and push package to local dev repository

    $ debsign -m"BerryNet" <package-changes>
    $ dput berrynet <package-changes>
    
  2. Push updates (packages and repo meta) to public repository (hosted on S3)

    git-to-s3 is being hosted at https://github.com/bafu/git-to-s3.git

    # integrate with git-to-s3/berrynet.md
    $ cd git-to-s3
    # dir structure in git_to_s3_temp needs to be the same as on S3
    # distribution candidates: staging, stretch, buster
    $ mkdir -p git_to_s3_temp/<distribution>
    $ cp <repo-diffs> git_to_s3_temp/<distribution>
    $ python3 git_to_s3.py
    

Delete or Replace Package

This demand should not happen. Here are the steps if you really need to do this:

  1. Delete source and binary packages in directory.

  2. Re-generate repository files

    --no-db is necessary or package replacement. If you remove a package and dput a new one w/ the same version, <distro>.db will not be updated, and the generated Package will contain the incorrect package information (e.g. Package still contains the old dependency info, instead of the updated one).

    Of course, a better way is to bump package's Debian version, instead of replacing it w/ the same version.

    $ mini-dinstall --no-db -b -c <mini-dinstall-conf>
    
Clone this wiki locally