Archive for the ‘Bourne Shell’ Category

  1. Hello, Bourne Shell World!

    Posted on 12月 22nd, 2011 by cx20

    Bourne Shell

    Bourne Shell は、UNIX 系の標準のシェルである。UNIX 系のシェルは主に sh 系と csh 系に分かれる。
    sh 系のシェルとしては bash、ksh(Korn Shell)、zsh(Z Shell)等がある。

    ソースコード

    #!/bin/sh
    echo "Hello, Bourne Shell World!"

    実行方法(スクリプトファイルを指定して実行)

    $ sh hello.sh

    実行方法(実行権限を付与して実行)

    $ chmod +x hello.sh
    $ ./hello.sh

    実行結果

    Hello, Bourne Shell World!