Browse code

* allow system specific repositories

Nat! authored on 04-09-2017 14:56:23 • Nat! committed on 06-09-2017 18:28:02
Showing 1 changed files
... ...
@@ -81,7 +81,25 @@ _bootstrap_auto_copy()
81 81
    do
82 82
       IFS="${DEFAULT_IFS}"
83 83
 
84
+      #
85
+      # os specific overrides present, skip dis
86
+      #
87
+      if [ -f "${name}.${UNAME}" ]
88
+      then
89
+         continue
90
+      fi
91
+
84 92
       filepath="${tmpdir}/${name}"
93
+
94
+      #
95
+      # cut off os specific for general name
96
+      #
97
+      case "${name}" in
98
+         *".${UNAME}")
99
+            name="${name%.*}"
100
+         ;;
101
+      esac
102
+
85 103
       dstfilepath="${dst}/${name}"
86 104
 
87 105
       # only inherit, don't override
... ...
@@ -303,18 +321,37 @@ _bootstrap_auto_merge_root_settings()
303 321
 
304 322
       settingname="`basename -- "${i}"`"
305 323
       srcfile="${directory}/.bootstrap/${settingname}"
324
+
306 325
       if [ -d "${srcfile}" ]
307 326
       then
308 327
          # log_fluff "Directory \"${srcfile}\" not copied"
309 328
          continue
310 329
       fi
311 330
 
331
+      #
332
+      # os specific overrides present, skip dis
333
+      #
334
+      if [ -f "${srcfile}.${UNAME}" ]
335
+      then
336
+         continue
337
+      fi
338
+
339
+      #
340
+      # cut off os specific for general name
341
+      #
342
+      case "${settingname}" in
343
+         *".${UNAME}")
344
+            settingname="${settingname%.*}"
345
+         ;;
346
+      esac
347
+
312 348
       dstfile="${dst}/${settingname}"
313 349
 
314 350
       #
315 351
       # "repositories" files gets special treatment
316 352
       # "additional_repositories" is just a local patch thing
317 353
       # "embedded_repositories" is not merged though
354
+      #
318 355
       case "${settingname}" in
319 356
          "embedded_repositories"|"minions")
320 357
             continue  # done by caller