Browse Source

Use upstream slop repo in 'main' mode

Alois Mahdal 6 years ago
parent
commit
d021ec70d2
1 changed files with 11 additions and 1 deletions
  1. 11
    1
      trigger_copr

+ 11
- 1
trigger_copr View File

@@ -96,6 +96,16 @@ choose_copr() {
96 96
     esac
97 97
 }
98 98
 
99
+choose_urlbase() {
100
+    #
101
+    # Choose COPR project based on $Mode
102
+    #
103
+    case $Mode in
104
+        scratch) echo https://github.com/AloisMahdal/slop ;;
105
+        main)    echo https://github.com/naelstrof/slop ;;
106
+    esac
107
+}
108
+
99 109
 choose_relpfx() {
100 110
     #
101 111
     # Choose COPR project based on $Mode
@@ -115,7 +125,6 @@ main() {
115 125
     local Mode=scratch  # implies COPR project and release prefix
116 126
     which copr >/dev/null \
117 127
      || die "copr not found, try 'sudo install copr-cli'"
118
-    UrlBase=https://github.com/AloisMahdal/slop
119 128
     Tmp=$(mktemp -d)
120 129
     while true; do case $1 in
121 130
         -b) Branch=$2;      shift 2 || usage ;;
@@ -133,6 +142,7 @@ main() {
133 142
         *)            usage ;;
134 143
     esac
135 144
     test -n "$CoprProject" || CoprProject=$(choose_copr)
145
+    test -n "$UrlBase"     || UrlBase=$(choose_urlbase)
136 146
     if test -n "$Branch"; then
137 147
         die "not implemented"
138 148
         test -n "$Version" || Version=$(git_guess ver)