summaryrefslogtreecommitdiffstats
path: root/packaging/windows/get-convert-licenses.sh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-11-25 14:45:37 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-11-25 14:48:03 +0000
commite55403ed71282d7bfd8b56df219de3c28a8af064 (patch)
tree524889e5becb81643bf8741e3082955dca076f09 /packaging/windows/get-convert-licenses.sh
parentReleasing debian version 1.47.5-1. (diff)
downloadnetdata-e55403ed71282d7bfd8b56df219de3c28a8af064.tar.xz
netdata-e55403ed71282d7bfd8b56df219de3c28a8af064.zip
Merging upstream version 2.0.3+dfsg:
- does not include dygraphs anymore (Closes: #923993) - does not include pako anymore (Closes: #1042533) - does not include dashboard binaries anymore (Closes: #1045145) Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'packaging/windows/get-convert-licenses.sh')
-rwxr-xr-xpackaging/windows/get-convert-licenses.sh29
1 files changed, 29 insertions, 0 deletions
diff --git a/packaging/windows/get-convert-licenses.sh b/packaging/windows/get-convert-licenses.sh
new file mode 100755
index 000000000..b5d5191de
--- /dev/null
+++ b/packaging/windows/get-convert-licenses.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+# SPDX-License-Identifier: GPL-3.0-or-later
+
+set -e
+
+function txt_to_rtf() {
+ INPUT="$1"
+ OUTPUT="$2"
+
+ echo '{\rtf1\ansi\deff0 {\fonttbl {\f0 Times New Roman;}}' > "$OUTPUT"
+ echo '\paperh15840 \paperw12240' >> "$OUTPUT"
+ echo '\margl720 \margr720 \margt720 \margb720' >> "$OUTPUT"
+ echo '\f0\fs24' >> "$OUTPUT"
+
+ sed s/\$/'\\line'/ "$INPUT" | sed s/\\f/'\\page'/ >> "$OUTPUT"
+ echo '}' >> "$OUTPUT"
+}
+
+function check_and_get_file() {
+ if [ ! -f "$1" ]; then
+ curl -o "tmp.txt" "$2"
+ txt_to_rtf "tmp.txt" "$1"
+ rm "tmp.txt"
+ fi
+}
+
+check_and_get_file "gpl-3.0.rtf" "https://www.gnu.org/licenses/gpl-3.0.txt"
+check_and_get_file "ncul1.rtf" "https://app.netdata.cloud/LICENSE.txt"
+