[pacman-dev] [PATCH] Add the ability to always build from the repo's HEAD
Allan McRae
allan at archlinux.org
Mon May 27 18:59:06 EDT 2013
On 28/05/13 02:08, Techlive Zheng wrote:
> ---
> A task has also been added:
>
> https://bugs.archlinux.org/task/35499
Am I missing something completely here? Does not specifying "ref=" etc
in the URL build from HEAD?
You will need to explain what you are trying to do.
Allan
> scripts/makepkg.sh.in | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
> index c27c74d..cd7ed48 100644
> --- a/scripts/makepkg.sh.in
> +++ b/scripts/makepkg.sh.in
> @@ -557,6 +557,9 @@ download_git() {
> if ! git fetch --all -p; then
> # only warn on failure to allow offline builds
> warning "$(gettext "Failure while updating %s %s repo")" "${repo}" "git"
> + else
> + git fetch origin HEAD
> + echo "$(git rev-parse FETCH_HEAD)" > HEAD
> fi
> fi
> }
> @@ -597,6 +600,9 @@ extract_git() {
> branch)
> ref=origin/${fragment##*=}
> ;;
> + HEAD)
> + ref=HEAD
> + ;;
> *)
> error "$(gettext "Unrecognized reference: %s")" "${fragment}"
> plain "$(gettext "Aborting...")"
> @@ -604,6 +610,8 @@ extract_git() {
> esac
> fi
>
> + ref=$(git rev-parse "$ref")
> +
> if [[ -n $ref ]]; then
> if ! git checkout -b makepkg $ref; then
> error "$(gettext "Failure while creating working copy of %s %s repo")" "${repo}" "git"
>
More information about the pacman-dev
mailing list