Truncate list history
This commit is contained in:
parent
50068ef675
commit
cb0c679cc7
1 changed files with 10 additions and 3 deletions
|
@ -25,7 +25,7 @@ echo '' > compiled/all-adblock.txt
|
||||||
#Create Header
|
#Create Header
|
||||||
echo '! Title: Mainboarder compiled
|
echo '! Title: Mainboarder compiled
|
||||||
! Description: Filters optimized for uBlock, for single list use, deduplicated
|
! Description: Filters optimized for uBlock, for single list use, deduplicated
|
||||||
! Expires: 2 days
|
! Expires: 1 days
|
||||||
! Last modified: '"$date"'
|
! Last modified: '"$date"'
|
||||||
! Homepage: https://git.mainboarder.de/Public/Adblocker
|
! Homepage: https://git.mainboarder.de/Public/Adblocker
|
||||||
!'
|
!'
|
||||||
|
@ -39,5 +39,12 @@ echo '' > compiled/all-adblock.txt
|
||||||
|
|
||||||
cd compiled
|
cd compiled
|
||||||
git add all-adblock.txt
|
git add all-adblock.txt
|
||||||
git commit -m "$date" > /dev/null
|
git commit --quiet -m "$date"
|
||||||
git push > /dev/null 2>&1
|
git push --quiet
|
||||||
|
|
||||||
|
lastcommit=$(git log --pretty=format:'%H' -n 3 | tail -n 1)
|
||||||
|
git checkout --quiet --orphan temp $lastcommit
|
||||||
|
git commit --quiet -m "Truncated history"
|
||||||
|
git rebase --quiet --onto temp $lastcommit main
|
||||||
|
git branch --quiet -D temp
|
||||||
|
git push --quiet --force
|
||||||
|
|
Loading…
Reference in a new issue