Git sign off previous commits?

后端 未结 8 553
没有蜡笔的小新
没有蜡笔的小新 2020-12-12 11:24

I was wondering how to sign(-s) off previous commits that I have made in the past in git?

8条回答
  •  情书的邮戳
    2020-12-12 12:01

    I had a similar issue. Here, thanks to Robin Johnson from Gentoo Linux is a trick to add the signature to all my previous unpushed commits:

    $ git pull && git rebase --gpg-sign --force-rebase origin/master && git push --signed
    Already up-to-date.
    Current branch master is up to date, rebase forced.
    First, rewinding head to replay your work on top of it...
    Applying: sci-biology/KING: new package
    Applying: dev-lang/yaggo: version bump, fix install procedure
    Applying: sci-libs/htslib: version bump
    Applying: sci-biology/bcftools: version bump
    Applying: sci-biology/samtools: version bump
    Applying: sci-biology/libBigWig: new release with io.h renamed to bigWigIO.h
    Applying: sci-biology/MaSuRCA: add more URLs to HOMEPAGE
    Applying: sci-biology/SPAdes: update comments on bundled dev-libs/boost
    Applying: sci-biology/khmer: added a comment how to proceed with src_compile()
    Applying: sci-biology/picard: version bump
    Applying: sci-biology/ruffus: pint EGIT_REPO_URI to the archive URL of code.google.com
    Applying: sci-biology/vcftools: the 0.1.15_pre release was just renamed to 0.1.15 by upstream
    Applying: sci-biology/nanopolish: new package
    Applying: sci-biology/libBigWig: version bump
    Counting objects: 75, done.
    Delta compression using up to 2 threads.
    Compressing objects: 100% (75/75), done.
    Writing objects: 100% (75/75), 14.51 KiB | 0 bytes/s, done.
    Total 75 (delta 55), reused 0 (delta 0)
    remote: To github.com:gentoo/sci.git
    remote:    29c5e3f5d..b37457700  master -> master
    To git+ssh://git.gentoo.org/proj/sci.git
       29c5e3f5d..b37457700  master -> master
    $
    

提交回复
热议问题