Linux man 2,3 quick reference

Linux man 2,3 quick reference

I wrote a script to extract the useful “synopsis” section, from Linux man pages in sections 2 and 3, the syscalls and library calls.  This can be good to see what calls there are, and to refresh your memory.

dpkg -L manpages-dev | grep -ie 'man[23]/' | sort |
while read file; do
	if [ -L "$file" ]; then continue; fi
	man -l "$file" | sed -n '0,/DESCRIPTION\|Feature Test/p' |
	grep -v -e '^[ \t]*$' -e '^[^ \t]' -e 'Feature Test' |
	sed 's/^[ \t]*//'
	echo
done
Advertisements
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s