aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/i-data-uscf.sh
blob: 635c7fe2619de15a7bd64b5f31d86050ff3eb379 (plain)
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
#!/bin/sh
# SPDX-FileCopyrightText: 2023 Markus Uhlin <maxxe@rpblc.net>
# SPDX-License-Identifier: ISC

i_data_uscf () {
	local _src_prefix _dest _files

	_src_prefix=${1}
	_dest=${2}

	_files="
ak
al
ar
az
beginner
ca_n
ca_s
co
ct
dc
de
fl
foreign
ga
gran_prix
help
hi
ia
id
il
in
ks
ky
la
ma
md
me
mi
mn
mo
ms
mt
national
nc
nd
ne
nh
nj
nm
nv
ny
oh
ok
or
pa
ri
sc
sd
tn
tx
ut
va
vt
wa
wi
wv
wy
"

	echo "installing..."

	for file in ${_files}; do
		printf "%s -> %s: " "${_src_prefix}/${file}" "${_dest}/${file}"
		if [ -r "${_src_prefix}/${file}" ]; then
			install -m 0644 "${_src_prefix}/${file}" "${_dest}"
			if [ $? -eq 0 ]; then
				echo "ok"
			else
				echo "error"
			fi
		else
			echo "not found"
		fi
	done
}

i_data_uscf "${1}" "${2}"