Compare commits
No commits in common. "b0afca09a56e3046a2e218911eb1efac7190959e" and "bb787cc0cce83cbe978cf7d14f8ac16014238474" have entirely different histories.
b0afca09a5
...
bb787cc0cc
1 changed files with 6 additions and 7 deletions
13
sh/doc.awk
13
sh/doc.awk
|
@ -40,7 +40,7 @@ BEGIN {
|
|||
{
|
||||
# doc
|
||||
if (match($0, RE_SHEBANG, m)) {
|
||||
append("shebang: " m[1])
|
||||
append(m[1])
|
||||
} else if (match($0, RE_DOC, m)) {
|
||||
append(m[1])
|
||||
} else if (match($0, RE_ALIAS, m)) {
|
||||
|
@ -56,25 +56,24 @@ BEGIN {
|
|||
}
|
||||
} else if (match($0, RE_SET, m)) {
|
||||
if (m[1] == target) {
|
||||
printf "set: "
|
||||
print "set"
|
||||
output(m[1])
|
||||
} else {
|
||||
reset()
|
||||
}
|
||||
} else if (match($0, RE_FUNCTION, m)) {
|
||||
if (alias) {
|
||||
print "alias: " target
|
||||
printf "function: "
|
||||
output(m[1])
|
||||
print "alias"
|
||||
output(target)
|
||||
} else if (m[1] == target) {
|
||||
printf "function: "
|
||||
print "function"
|
||||
output(target)
|
||||
} else {
|
||||
reset()
|
||||
}
|
||||
} else {
|
||||
if (module) {
|
||||
printf "module: "
|
||||
print "module"
|
||||
output(target)
|
||||
} else {
|
||||
reset()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue