1 |
The current bzr eclass uses EBZR_FETCH_CMD="bzr checkout --lightweight" |
2 |
to initially fetch the sources. |
3 |
The problem with this is though it saves some time and bandwidth on the |
4 |
initial fetch it actually ends up using a lot more time and bandwidth |
5 |
on every update. |
6 |
Ok great I can set EBZR_FETCH_CMD="bzr checkout". |
7 |
This solves the initial fetch problems. |
8 |
Now when I try and update the bzr eclass function bzr_fetch() has this |
9 |
bit of code in it. |
10 |
|
11 |
# Run bzr_initial_fetch() only if the branch has not been pulled |
12 |
# before or if the existing local copy is a full checkout (as did |
13 |
# an older version of bzr.eclass) |
14 |
if [[ ! -d ${EBZR_BRANCH_DIR} ]] ; then |
15 |
bzr_initial_fetch "${EBZR_REPO_URI}" "${EBZR_BRANCH_DIR}" |
16 |
elif [[ -d "${EBZR_BRANCH_DIR}"/.bzr/repository/ ]]; then |
17 |
einfo "Re-fetching the branch to save space..." |
18 |
rm -rf "${EBZR_BRANCH_DIR}" |
19 |
bzr_initial_fetch "${EBZR_REPO_URI}" "${EBZR_BRANCH_DIR}" |
20 |
else |
21 |
bzr_update "${EBZR_REPO_URI}" "${EBZR_BRANCH_DIR}" |
22 |
fi |
23 |
|
24 |
Since I did a full checkout with the EBZR_FETCH_CMD="bzr checkout" |
25 |
it now deletes the entire previous checked out branch (to save disk space ?) and proceeds to fetch the entire |
26 |
source again. |
27 |
Why would I ever want to do that ? The whole point of bzr is to save bandwidth not disk space. |
28 |
Is there a way arouund this ? |