aboutsummaryrefslogtreecommitdiff
path: root/rfile
blob: 2daa06b35fd0f00d18086e08f8c7a23ee3782cdf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# rfile for rfile

# greet the polite visitor with a box!
@:! hello from rfile!

# variables
@cc=gcc
@inp=rf.c
@out=rf
@opts=-Wall -Wextra -pedantic -std=c99
@editor=$EDITOR

# build
@: building rf.. 
@cc @inp -o @out @opts

# install section
install {
    rf
    @: installing rf..
    sudo install -Dm755 @out /usr/bin/@out
    rf clean
}

# clean section
clean {
    @: removing rf binary..
    rm @out
}

edit {
    @: opening default editor..
    @editor rf.c
}