blob: 7506202f461e142d0a255405136a2926572e8c99 [file] [log] [blame]
George Liuff92ffe2021-02-09 15:01:53 +08001#!/bin/bash
2#
3# config: 5 1
4# @brief: Move the ramoops data file to the dreport packaging.
5#
6
Patrick Williams78942d62022-12-05 22:00:41 -06007# shellcheck source=tools/dreport.d/include.d/functions
8. "$DREPORT_INCLUDE/functions"
George Liuff92ffe2021-02-09 15:01:53 +08009
10desc="Ramoops file"
11
Patrick Williams78942d62022-12-05 22:00:41 -060012if [ -n "${optional_path}" ]; then
13 for path in "${optional_path}"/*
14 do
15 if [ -f "$path" ]; then
16 # Remove the file from path after successful copy
17 if add_copy_file "$path" "$desc"; then
18 rm "$path"
19 fi
George Liuff92ffe2021-02-09 15:01:53 +080020 fi
Patrick Williams78942d62022-12-05 22:00:41 -060021 done
22fi