File: copr-custom-script

package info (click to toggle)
argparse-manpage 4.7-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 568 kB
  • sloc: python: 2,772; makefile: 47; sh: 18
file content (29 lines) | stat: -rw-r--r-- 626 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#! /bin/bash -x

set -e

clone_url_parent=https://github.com/praiskup/argparse-manpage

workdir=$(basename "$clone_url_parent")
workdir=${workdir%%.git}

hook_payload=$(readlink -f "${HOOK_PAYLOAD-hook_payload}")

# clone the helper scripts when needed, and add to PATH
test -d copr-ci-tooling \
    || git clone --depth 1 https://github.com/praiskup/copr-ci-tooling.git
export PATH="$PWD/copr-ci-tooling:$PATH"

# clone the tested project
git clone \
    --recursive \
    --no-single-branch \
    "$clone_url_parent"

# checkout requested revision
cd "$workdir"

webhook-checkout "$hook_payload"

cd rpm || exit 1
make srpm