Add ruby-shell, a Ruby library to run commands and control jobs like a

shell.  Pipes and redirections work just as expected:

  sh = Shell.cd("/foo")
  sh.cat("bar") | sh.tee("baz") > "baa"
  # or
  sh.transact do
    cat("bar") | tee("baz") > "baa"
  end
This commit is contained in:
Akinori MUSHA 2001-03-16 09:02:00 +00:00
parent 0ef6a53da1
commit f8eeebacaa
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=39912
6 changed files with 63 additions and 0 deletions

View File

@ -14,6 +14,7 @@
SUBDIR += pdksh
SUBDIR += perlsh
SUBDIR += rc
SUBDIR += ruby-shell
SUBDIR += sash
SUBDIR += scsh
SUBDIR += tcsh

View File

@ -0,0 +1,36 @@
# New ports collection makefile for: shell.rb
# Date created: 16 March 2001
# Whom: Akinori MUSHA aka knu <knu@idaemons.org>
#
# $FreeBSD$
#
PORTNAME= shell
PORTVERSION= 0.5.6
CATEGORIES= shells ruby
MASTER_SITES= ${MASTER_SITE_RUBY}
MASTER_SITE_SUBDIR= contrib
PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX}
EXTRACT_SUFX= .tgz
DIST_SUBDIR= ruby
MAINTAINER= knu@FreeBSD.org
USE_RUBY= yes
NO_BUILD= yes
DOCS_JA= doc/shell.doc
do-install:
${MKDIR} ${RUBY_SITELIBDIR}/${PORTNAME}
${INSTALL_DATA} ${WRKSRC}/shell.rb ${RUBY_SITELIBDIR}/
${INSTALL_DATA} ${WRKSRC}/shell/* ${RUBY_SITELIBDIR}/${PORTNAME}/
.if !defined(NOPORTDOCS)
${MKDIR} ${RUBY_DOCDIR}/${PORTNAME}/ja
.for f in ${DOCS_JA}
${INSTALL_DATA} ${WRKSRC}/${f} ${RUBY_DOCDIR}/${PORTNAME}/ja/
.endfor
.endif
.include <bsd.port.mk>

View File

@ -0,0 +1 @@
MD5 (ruby/shell-0.5.6.tgz) = eab033b97ee6fbcfd15fff23715adbcc

View File

@ -0,0 +1 @@
A Ruby library to run commands and control jobs like a shell

View File

@ -0,0 +1,13 @@
shell.rb is a Ruby library to run commands and control jobs like a
shell. Pipes and redirections work just as expected:
sh = Shell.cd("/foo")
sh.cat("bar") | sh.tee("baz") > "baa"
# or
sh.transact do
cat("bar") | tee("baz") > "baa"
end
Author: Keiju Ishitsuka <keiju@ishitsuka.com>
WWW: http://www.ruby-lang.org/en/raa-list.rhtml?name=Shell

View File

@ -0,0 +1,11 @@
%%RUBY_SITELIBDIR%%/shell.rb
%%RUBY_SITELIBDIR%%/shell/builtin-command.rb
%%RUBY_SITELIBDIR%%/shell/command-processor.rb
%%RUBY_SITELIBDIR%%/shell/error.rb
%%RUBY_SITELIBDIR%%/shell/filter.rb
%%RUBY_SITELIBDIR%%/shell/process-controller.rb
%%RUBY_SITELIBDIR%%/shell/system-command.rb
@dirrm %%RUBY_SITELIBDIR%%/shell
%%PORTDOCS%%%%RUBY_DOCDIR%%/shell/ja/shell.doc
%%PORTDOCS%%@dirrm %%RUBY_DOCDIR%%/shell/ja
%%PORTDOCS%%@dirrm %%RUBY_DOCDIR%%/shell