~emersion/mrsh

ref: 32aff6e15dcabde2822abd06c8aa10ddc2e7144f mrsh/test/ulimit.sh -rw-r--r-- 316 bytes
32aff6e1Drew DeVault Mostly implement break and continue builtins 1 year, 5 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh -e

mrsh_limits=`ulimit`
[ "$mrsh_limits" = "unlimited" ]
if [ -e /proc/self/limits ]
then
	grep "Max file size" /proc/self/limits | grep "unlimited"
fi

ulimit -f 100

mrsh_limits=`ulimit`
[ "$mrsh_limits" -eq 100 ]
if [ -e /proc/self/limits ]
then
	grep "Max file size" /proc/self/limits | grep 51200
fi