aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFerass El Hafidi <vitali64pmemail@protonmail.com>2023-02-22 12:29:17 +0100
committerFerass El Hafidi <vitali64pmemail@protonmail.com>2023-02-22 12:29:17 +0100
commit0306823bba2967b78462f221315a802f92ff0aaa (patch)
tree9a00489fe188148e24fcee4ea24a2030adec5c1d
parentfdc736b1f59c620a5bb9c985f426aeb9ddb981d2 (diff)
downloadfases-0306823bba2967b78462f221315a802f92ff0aaa.tar.gz
fases-0306823bba2967b78462f221315a802f92ff0aaa.zip
Makefile: Fix box not compiling && man/: cmp.1
Signed-off-by: Ferass El Hafidi <vitali64pmemail@protonmail.com>
-rw-r--r--Makefile2
-rw-r--r--box.c2
-rw-r--r--config.mk2
-rw-r--r--man/cmp.139
4 files changed, 42 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index a8ad6b2..eebeab2 100644
--- a/Makefile
+++ b/Makefile
@@ -24,7 +24,7 @@ genbox:
cat "box-templates/box_70-73.c" >> box.c
test ${INCLUDE_CORE} == n || for u in ${CORE}; do echo " printf(\"$${u%.c} \");"; done >> box.c
test ${INCLUDE_EXTRA} == n || for u in ${EXTRA}; do echo " printf(\"$${u%.c} \");"; done >> box.c
- test ${INCLUDE_CORE} == n && test ${INCLUDE_EXTRA} == n && echo " printf(\"¯\\\\_(ツ)_/¯ No commands found.\");" >> box.c
+ test ${INCLUDE_CORE} == n && test ${INCLUDE_EXTRA} == n && echo " printf(\"¯\\\\_(ツ)_/¯ No commands found.\");" >> box.c || true
cat "box-templates/box_94-96.c" >> box.c
echo "/* Generated on $$(date) */" >> box.c
diff --git a/box.c b/box.c
index d64d2ab..16465dd 100644
--- a/box.c
+++ b/box.c
@@ -28,4 +28,4 @@ int main(int argc, char *argv[]) {
return 0;
}
/* END */
-/* Generated on Sun 19 Feb 10:22:55 CET 2023 */
+/* Generated on Tue 21 Feb 20:06:57 CET 2023 */
diff --git a/config.mk b/config.mk
index 7837b3b..3d3a4aa 100644
--- a/config.mk
+++ b/config.mk
@@ -9,8 +9,8 @@ CFLAGS=-D_POSIX_C_SOURCE=200809L -DVERSION=\"$(VERSION)\" -I. -Wall -Werror -Wex
NOLINKER=-c # C Compiler flag to disable the linker
# Core utilities
CORE=\
- basename\
[\
+ basename\
cat\
chmod\
chown\
diff --git a/man/cmp.1 b/man/cmp.1
new file mode 100644
index 0000000..5eb247d
--- /dev/null
+++ b/man/cmp.1
@@ -0,0 +1,39 @@
+CMP(1) "fases core"
+
+# NAME
+
+cmp - compare two files
+
+# SYNOPSIS
+
+*cmp* [*-l*|*-s*] *file1* *file2*
+
+# DESCRIPTION
+
+Compare two files. If the files are identical, *cmp* doesn't write anything
+to standard output and returns 0. Else, with no options, it writes to
+standard output the byte and line number at which it found the first
+difference and returns 1.
+
+*-l*
+ Write the byte number and the differing bytes for each difference in
+ decimal and octal respectively.
+
+*-s*
+ Write nothing to standard output or standard error when the files
+ differ. Only write diagnostic messages to standard error.
+
+# EXAMPLES
+
+*cmp -s foo.txt bar.txt*
+ Compare foo.txt to bar.txt and return 1 if the files are different.
+
+# AUTHOR
+
+Written by Ferass El Hafidi as part of the fases project.
+
+Source code is at http://git.vitali64.duckdns.org/utils/fases.git.
+
+# COPYRIGHT
+
+Copyright (C) 2023 Ferass El Hafidi