⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 swap4.tcl

📁 开放源码实时操作系统源码.
💻 TCL
字号:
#!/bin/bash
# restart using a Tcl shell \
    exec sh -c 'for tclshell in tclsh tclsh83 cygtclsh80 ; do \
            ( echo | $tclshell ) 2> /dev/null && exec $tclshell "`( cygpath -w \"$0\" ) 2> /dev/null || echo $0`" "$@" ; \
        done ; \
        echo "swap4.tcl: cannot find Tcl shell" ; exit 1' "$0" "$@"

proc filter { input_file output_file } {
    set input_fd [open $input_file  "r"]
    set output_fd  [open $output_file "w"]

    fconfigure $input_fd  -translation binary
    fconfigure $output_fd -translation binary
    while { 1 } {
	set data [read $input_fd 4]
	if { [eof $input_fd] } {
	    break
	}
	binary scan $data "i" var
	puts -nonewline $output_fd [binary format "I" $var]
    }
    close $input_fd
    close $output_fd
}

filter [lindex $argv 0] [lindex $argv 1]

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -