Skip to content
Stefan Mahnke-Hartmann edited this page Jun 12, 2023 · 5 revisions

Wiki's...

Raspberry Pi setup

Git in examples...

git clone
git fetch
git rebase
git commit --amend
git log
git log --graph --oneline --all
git branch -vv
git rebase -i --root
git tag backup [-f]

Rename branch

git branch -m <oldname> <newname>
git branch -m <newname>

Delete branch

git branch -d <name>
git branch -D <name>

Add a new remote repro

git remote add rpi https://github.com/raspberrypi/linux.git
git remote -v
git fetch rpi
git checkout rpi-5.17.y
git log
git checkout -b my-rpi-5.17.y
git log --all
git push --set-upstream origin my-rpi-5.17.y
git remote -v
git log

Change the URI (URL) for a remote Git repository

git remote set-url origin ssh://git@mygitserver.com:8080/myrepros/linux.git
git remote -v
git fetch origin
git log
git rebase rpi-5.17.y -i
git log --all
git rebase --continue

Create patches

git format-patch ${commitRange} -o ~/workspace/${commitName}

/scripts/get_maintainer.pl 0001-my-fix.patch

git send-email:
--annotate
--compose

git send-email --to maintainer1@kernel.org --to linux-integrity@vger.kernel.org --to linux-kernel@vger.kernel.org --cc maintainer2@mail.de --cc maintainer3@mail.de --annotate origin/commitA~1..origin/CommitA