From cf121cd31bf8ef9ddb6f48e10d2a7685ae6ed87b Mon Sep 17 00:00:00 2001 From: desktop Date: Wed, 6 Dec 2023 22:50:30 +0300 Subject: [PATCH] git : add ggc. --- .README.md | 1 + .config/bash/module/git.sh | 5 +++++ .local/share/flatpak/overrides/com.usebottles.bottles | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.README.md b/.README.md index fd06ca0..6ee33fa 100644 --- a/.README.md +++ b/.README.md @@ -534,6 +534,7 @@ Command|Description `gr [COUNT]`|Git rebase. 2 last commits by default. 0 means from root. `gu `|Configure git user as Dmitry Voronin with specified email (project). `gg `|Get git repo from my own git. +`ggc`|Run git garbage collection. ## Ls. diff --git a/.config/bash/module/git.sh b/.config/bash/module/git.sh index 3af98c6..ad9466e 100644 --- a/.config/bash/module/git.sh +++ b/.config/bash/module/git.sh @@ -18,6 +18,11 @@ alias gi="git ls-files -ci --exclude-standard -z | xargs -0 git rm --cached" alias gpc="git diff >" alias gp="git apply" +# Run git garbage collection. +ggc() { + git gc --aggressive --no-cruft --prune=now +} + # alias to preview diff while adding. adds current dir by default. # usage: ga [FILES] ga() { diff --git a/.local/share/flatpak/overrides/com.usebottles.bottles b/.local/share/flatpak/overrides/com.usebottles.bottles index 433f029..dd279eb 100644 --- a/.local/share/flatpak/overrides/com.usebottles.bottles +++ b/.local/share/flatpak/overrides/com.usebottles.bottles @@ -1,5 +1,5 @@ [Context] -filesystems=!xdg-download;~/.config/MangoHud:ro;~/media/bottle;/var/mnt/storage/cold_1/tmp:ro;/var/mnt/storage/hot/media/bottle;/var/mnt/storage/hot/media/game;~/download:ro;/var/mnt/storage/cold_1/media/game/:ro +filesystems=!xdg-download;/var/mnt/storage/hot/media/save;/var/mnt/storage/cold_1/media/game/:ro;~/download:ro;/var/mnt/storage/hot/media/game;/var/mnt/storage/hot/media/bottle;/var/mnt/storage/cold_1/tmp:ro;~/media/bottle;~/.config/MangoHud:ro [Environment] MANGOHUD=1