aboutsummaryrefslogtreecommitdiff
path: root/rfile
diff options
context:
space:
mode:
Diffstat (limited to 'rfile')
-rw-r--r--rfile28
1 files changed, 23 insertions, 5 deletions
diff --git a/rfile b/rfile
index 97ba695..f38ab34 100644
--- a/rfile
+++ b/rfile
@@ -1,9 +1,27 @@
# rfile for rfile
-@: hello from rfile
-all {
- cc -o rf rf.c -Wall -Wextra -pedantic
- sudo install -Dm755 rf /usr/bin/rf
- rm ./rf
+# greet the polite visitor with a box!
+@:! hello from rfile!
+
+# variables
+@cc=gcc
+@inp=rf.c
+@out=rf
+@opts=-Wall -Wextra -pedantic -std=c99
+
+# build
+@cc @inp -o @out @opts
+
+# install section
+install {
+ rf
+ @: installing rf..
+ sudo install -Dm755 @out /usr/bin/@out
+ rf clean
+}
+
+# clean section
+clean {
+ rm @out
}