mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-29 19:00:57 +02:00
43080: _sys_calls: analyze recent syscall.h properly
This commit is contained in:
parent
a0233a74e3
commit
3c57f71668
2 changed files with 4 additions and 1 deletions
|
@ -5,6 +5,9 @@
|
|||
Completion/Darwin/Command/_sc_usage: new utility to complete names
|
||||
of running processes, and three new completion functions which use it.
|
||||
|
||||
* 43080: Completion/Unix/Type/_sys_calls: analyze recent syscall.h
|
||||
properly
|
||||
|
||||
2018-06-24 dana <dana@dana.is>
|
||||
|
||||
* unposted: Completion/Linux/Command/_opkg: Fix mistyped variable
|
||||
|
|
|
@ -12,7 +12,7 @@ local -au syscalls
|
|||
zparseopts -D -K -E a=all n=none
|
||||
|
||||
[[ $OSTYPE = linux* ]] && ifile=/usr/include/bits/syscall.h
|
||||
syscalls=( ${${${(M)${(f)"$(<$ifile)"}:#?define[[:blank:]]##SYS_*}#*[[:blank:]]SYS_}%%[[:blank:]]*} ) 2>/dev/null
|
||||
syscalls=( ${${${(M)${(f)"$(<$ifile)"}:#\#[[:blank:]]#define[[:blank:]]##SYS_*}#*[[:blank:]]SYS_}%%[[:blank:]]*} ) 2>/dev/null
|
||||
[[ -n $all ]] && syscalls+=( all )
|
||||
[[ -n $none ]] && syscalls+=( none )
|
||||
|
||||
|
|
Loading…
Reference in a new issue