Skip to contentSkip to conversation

cmd: cat: add new command

PATCH Superseded Roger Knecht 1 participant 1 message May 23, 2022

v1 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 cmd: cat: add new command

Add cat command to print file content to standard out

---
 cmd/Kconfig  |  6 ++++++
 cmd/Makefile |  1 +
 cmd/cat.c    | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 61 insertions(+)
 create mode 100644 cmd/cat.c
cmd/Kconfig +6 -0
index 69c1814d24..2cb719795c 100644
@@ -385,6 +385,12 @@ config CMD_ABOOTIMG
 
 	  See doc/android/boot-image.rst for details.
 
+config CMD_CAT
+	bool "cat"
+	default y
+	help
+	  print file to standard output
+
 config CMD_ELF
 	bool "bootelf, bootvx"
 	default y
cmd/Makefile +1 -0
index 5e43a1e022..589b9680ba 100644
@@ -38,6 +38,7 @@ obj-$(CONFIG_CMD_BOOTZ) += bootz.o
 obj-$(CONFIG_CMD_BOOTI) += booti.o
 obj-$(CONFIG_CMD_BTRFS) += btrfs.o
 obj-$(CONFIG_CMD_BUTTON) += button.o
+obj-$(CONFIG_CMD_CAT) += cat.o
 obj-$(CONFIG_CMD_CACHE) += cache.o
 obj-$(CONFIG_CMD_CBFS) += cbfs.o
 obj-$(CONFIG_CMD_CLK) += clk.o
cmd/cat.c new file +54 -0

54 lines not on this page · raw message

--
2.17.1