mirror of
https://github.com/NikitaIvanovV/ctpv.git
synced 2024-11-24 13:53:07 +01:00
Cleanup
This commit is contained in:
parent
5ef3f4ff48
commit
f2e4ad4482
4
Makefile
4
Makefile
@ -39,8 +39,8 @@ clean:
|
|||||||
$(MAKE) -C embed clean
|
$(MAKE) -C embed clean
|
||||||
|
|
||||||
docs: README.md doc/ctpv.1
|
docs: README.md doc/ctpv.1
|
||||||
./deplist.awk $(PRE) | ./deplist.md.sh | ./deplistadd.sh README.md
|
deptable/list.awk $(PRE) | deptable/markdown.sh | deptable/insert.sh README.md
|
||||||
./deplist.awk $(PRE) | ./deplist.1.sh | ./deplistadd.sh doc/ctpv.1
|
deptable/list.awk $(PRE) | deptable/roff.sh | deptable/insert.sh doc/ctpv.1
|
||||||
|
|
||||||
ctpv: $(OBJ)
|
ctpv: $(OBJ)
|
||||||
$(CC) -o $@ $+ $(LDFLAGS)
|
$(CC) -o $@ $+ $(LDFLAGS)
|
||||||
|
@ -1,11 +1,14 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
tmp="$(mktemp XXXXXX)"
|
||||||
table="$(mktemp XXXXXX)"
|
table="$(mktemp XXXXXX)"
|
||||||
trap 'rm "$table"' EXIT
|
trap 'rm "$table"' EXIT
|
||||||
|
|
||||||
cat > "$table"
|
cat > "$table"
|
||||||
|
|
||||||
sed -i "
|
sed "
|
||||||
/TABLESTART/,/TABLEEND/ {
|
/TABLESTART/,/TABLEEND/ {
|
||||||
/TABLESTART/ {
|
/TABLESTART/ {
|
||||||
r $table
|
r $table
|
||||||
@ -13,4 +16,6 @@ sed -i "
|
|||||||
}
|
}
|
||||||
/TABLEEND/!d
|
/TABLEEND/!d
|
||||||
}
|
}
|
||||||
" "$1"
|
" "$1" > "$tmp"
|
||||||
|
|
||||||
|
mv -- "$tmp" "$1"
|
Loading…
Reference in New Issue
Block a user