📄 psize.sh
字号:
#! /bin/sh## psize.sh -- determine this system's pipe size, and write a define to# pipesize.h so ulimit.c can use it.: ${TMPDIR:=/tmp}# try to use mktemp(1) if the system supports it{ TMPFILE="`mktemp $TMPDIR/pipsize.XXXXXX 2>/dev/null`"; } 2>/dev/nullused_mktemp=trueif [ -z "$TMPFILE" ]; then TMPNAME=pipsize.$$ TMPFILE=$TMPDIR/$TMPNAME used_mktemp=falsefitrap 'rm -f "$TMPFILE" ; exit 1' 1 2 3 6 15trap 'rm -f "$TMPFILE"' 0echo "/*"echo " * pipesize.h"echo " *"echo " * This file is automatically generated by psize.sh"echo " * Do not edit!"echo " */"echo ""## Try to avoid tempfile races. We can't really check for the file's# existance before we run psize.aux, because `test -e' is not portable,# `test -h' (test for symlinks) is not portable, and `test -f' only# checks for regular files. If we used mktemp(1), we're ahead of the# game.#$used_mktemp || rm -f "$TMPFILE"./psize.aux 2>"$TMPFILE" | sleep 3if [ -s "$TMPFILE" ]; then echo "#define PIPESIZE `cat "$TMPFILE"`"else echo "#define PIPESIZE 512"fiexit 0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -