Debian活用/その他

提供: Medeshima wiki
ナビゲーションに移動 検索に移動
yaskkserv(サーバを1つに)
squid
webDAXSV
LDAP
docker
Clamav
vscode emacs
scp -P XXX -i id_XXX XXX.txt XXX@XXX:
Debian Backports
Debian Fast Track
chroot qemu-arm qemu-user-static debootstrap
xxd vim emacs
SpamAssassin
s/mime
DKIM
voicevox
apparmor
smartmontools
badblocks
fsck
quilt

git

初期設定

$ git config --global user.name "user"
$ git config --global user.email "user@example.com"
$ git config --global pull.rebase false

$ git config --global color.ui = auto

git config --global url.https://example.com/.insteadOf git@example.com:
git config --global --add url.https://example.com/.insteadOf ssh://git@example.com/

branch

git checkout -b test main
git push -u origin test

git commit -m ""

状態確認

status
show

git diff --name-only --cached
git diff ID
git log

patch

git format-patch --start-number NUMBER ID

git apply --check 0001-test.patch

patch -p1 < 0001-test.patch

書き換え

$ git commit --amend



$ git rebase -i HEAD~n
pickをeditに変更する
git commit --amend -s -m ""
git rebase --continue

git stash -u
git stash list
git stash apply stash@{0}
git stash apply stash@{0} --index
git stash drop stash@{0}

$ git reset --soft HEAD^
$ git reset --hard HEAD^
$ git reset HEAD FILENAME
$ git checkout HEAD FILENAME
$ git rm --cached -r FILENAME

$ git revert HEAD

$ git log --pretty=full

$ git filter-branch -f --env-filter '
  if [ "$GIT_COMMITTER_EMAIL" = "user1@example.com" ];
    then
      GIT_COMMITER_NAME="user2";
      GIT_AUTHOR_NAME="user2";
      GIT_COMMITER_EMAIL="user2@example.com";
      GIT_AUTHOR_EMAil="user2@example.com";
  fi'
$ git push -f