HEX
Server: Apache
System: Linux vps38548 6.8.0-83-generic #83~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Sep 9 18:19:47 UTC 2 x86_64
User: siamesebasil (5727853)
PHP: 8.1.32
Disabled: NONE
Upload Files
File: //bin/timed-run
#!/bin/sh
# -*- tcl -*-
# The next line is executed by /bin/sh, but not tcl \
exec tclsh8.6 "$0" ${1+"$@"}

package require Expect

# run a program for a given amount of time
# i.e. time 20 long_running_program

set timeout [lindex $argv 0]
eval spawn [lrange $argv 1 end]
expect