Centralise rsync excludes

This commit is contained in:
Kovid Goyal 2025-05-08 12:49:05 +05:30
parent 007e40b5b8
commit e370c555ba
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

17
rsync-and-build.sh Normal file
View File

@ -0,0 +1,17 @@
#!/bin/sh
# To be used via a script such as
: <<'COMMENT'
export RSYNC_PASSWORD=password
export BUILDBOT=rsync://username@server/path/to/this/directory
cd ~/calibre-src || exit 1
script=rsync-and-build.sh
if [[ -e "$script" ]]; then
source "$script"
else
rsync -a --include "$script" --exclude '*' "$BUILDBOT" . && source "$script"
fi
COMMENT
rsync -a --delete --force --exclude bypy/b --exclude src/calibre/plugins --exclude manual --exclude ".*cache" --exclude .git --exclude build --exclude dist --exclude "*.pyj-cached" --exclude "*.pyc" --exclude "*.pyo" --exclude "*.swp" --exclude "*.swo" --exclude format_docs "$BUILDBOT" .