diff options
author | Christoph Niedermaier <cniedermaier@dh-electronics.com> | 2022-02-23 10:33:36 +0100 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2022-04-07 16:50:53 -0400 |
commit | 7d79cba28ca9bb02ba589eca2e80ce837d7d0ca8 (patch) | |
tree | 36256bff8aa4dedcb3620d0cefd89007b292bc74 /scripts | |
parent | eb68ead2d3f093dfeffae68045e8921d93ff05cf (diff) | |
download | u-boot-7d79cba28ca9bb02ba589eca2e80ce837d7d0ca8.tar.gz u-boot-7d79cba28ca9bb02ba589eca2e80ce837d7d0ca8.tar.bz2 u-boot-7d79cba28ca9bb02ba589eca2e80ce837d7d0ca8.zip |
scripts/get_default_envs.sh: Remove blank lines
After sorting, unnoticed blank lines at the end move to the top.
Avoid this by removing it before sorting.
Signed-off-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>
Cc: Lukasz Majewski <lukma@denx.de>
Cc: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
Cc: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/get_default_envs.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/get_default_envs.sh b/scripts/get_default_envs.sh index 3c6fdc45e1..fedf7206fe 100755 --- a/scripts/get_default_envs.sh +++ b/scripts/get_default_envs.sh @@ -35,8 +35,8 @@ cp ${env_obj_file_path} ${ENV_OBJ_FILE_COPY} ${OBJCOPY} --dump-section .rodata.default_environment=${ENV_OBJ_FILE_COPY} \ ${env_obj_file_path} -# Replace default '\0' with '\n' and sort entries -tr '\0' '\n' < ${ENV_OBJ_FILE_COPY} | sort --field-separator== -k1,1 --stable +# Replace default '\0' with '\n' , remove blank lines and sort entries +tr '\0' '\n' < ${ENV_OBJ_FILE_COPY} | sed -e '/^\s*$/d' | sort --field-separator== -k1,1 --stable rm ${ENV_OBJ_FILE_COPY} |