mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-26 05:02:18 +00:00
main.rb features the following:
- unification of option, argument, keyword, and environment parameter parsing - auto generation of usage and help messages - support for mode/sub-commands - io redirection support - logging hooks using ruby's built-in logging mechanism - intelligent error handling and exit codes - use as dsl or library for building Main objects - parsing user defined ARGV and ENV - zero requirements for understanding the obtuse apis of any command line option parsers - leather pants In short main.rb aims to drastically lower the barrier to writing uniform command line applications. WWW: http://codeforpeople.com/lib/ruby/main/ PR: ports/128664 Submitted by: Wen Heping <wenheping at gmail.com>
This commit is contained in:
parent
6c249d26a1
commit
a23357c7a7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=222657
@ -2415,6 +2415,7 @@
|
||||
SUBDIR += rubygem-json
|
||||
SUBDIR += rubygem-json_pure
|
||||
SUBDIR += rubygem-linecache
|
||||
SUBDIR += rubygem-main
|
||||
SUBDIR += rubygem-mocha
|
||||
SUBDIR += rubygem-mojombo-grit
|
||||
SUBDIR += rubygem-needle
|
||||
|
32
devel/rubygem-main/Makefile
Normal file
32
devel/rubygem-main/Makefile
Normal file
@ -0,0 +1,32 @@
|
||||
# New ports collection makefile for: rubygem-main
|
||||
# Date created: 07, Nov 2008
|
||||
# Whom: Wen Heping <wenheping@gmail.com>
|
||||
#
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= main
|
||||
PORTVERSION= 2.8.3
|
||||
CATEGORIES= devel rubygems
|
||||
MASTER_SITES= RF/codeforpeople
|
||||
|
||||
MAINTAINER= wenheping@gmail.com
|
||||
COMMENT= A Class Factory and Dsl for Generating Command Line Programs
|
||||
|
||||
BUILD_DEPENDS= rubygem-fattr>=1.0.3:${PORTSDIR}/devel/rubygem-fattr \
|
||||
rubygem-arrayfields>=4.5.0:${PORTSDIR}/devel/rubygem-arrayfields
|
||||
RUN_DEPENDS= rubygem-fattr>=1.0.3:${PORTSDIR}/devel/rubygem-fattr \
|
||||
rubygem-arrayfields>=4.5.0:${PORTSDIR}/devel/rubygem-arrayfields
|
||||
|
||||
USE_RUBY= yes
|
||||
USE_RUBYGEMS= yes
|
||||
|
||||
post-install:
|
||||
@${ECHO} ${GEM_CACHE} > ${TMPPLIST}
|
||||
@${FIND} ${PREFIX}/${GEM_DOC_DIR} -type f | ${SED} -e 's,${PREFIX}/${GEM_DOC_DIR},${GEM_DOC_DIR},' >> ${TMPPLIST}
|
||||
@${FIND} ${PREFIX}/${GEM_LIB_DIR} -type f | ${SED} -e 's,${PREFIX}/${GEM_LIB_DIR},${GEM_LIB_DIR},' >> ${TMPPLIST}
|
||||
@${ECHO} ${GEM_SPEC} >> ${TMPPLIST}
|
||||
@${FIND} ${PREFIX}/${GEM_LIB_DIR} -type d -depth | ${SED} -e 's,${PREFIX}/${GEM_LIB_DIR},@dirrm ${GEM_LIB_DIR},' >> ${TMPPLIST}
|
||||
@${FIND} ${PREFIX}/${GEM_DOC_DIR} -type d -depth | ${SED} -e 's,${PREFIX}/${GEM_DOC_DIR},@dirrm ${GEM_DOC_DIR},' >> ${TMPPLIST}
|
||||
|
||||
.include <bsd.port.mk>
|
3
devel/rubygem-main/distinfo
Normal file
3
devel/rubygem-main/distinfo
Normal file
@ -0,0 +1,3 @@
|
||||
MD5 (rubygem/main-2.8.3.gem) = dcb344a9ad5f72cdc03c34a496400d73
|
||||
SHA256 (rubygem/main-2.8.3.gem) = 013b059565cd133ab5dfddf53c9cb265949e6d6ad717296617c3381b4fb7e05a
|
||||
SIZE (rubygem/main-2.8.3.gem) = 30720
|
18
devel/rubygem-main/pkg-descr
Normal file
18
devel/rubygem-main/pkg-descr
Normal file
@ -0,0 +1,18 @@
|
||||
main.rb features the following:
|
||||
- unification of option, argument, keyword, and environment
|
||||
parameter parsing
|
||||
- auto generation of usage and help messages
|
||||
- support for mode/sub-commands
|
||||
- io redirection support
|
||||
- logging hooks using ruby's built-in logging mechanism
|
||||
- intelligent error handling and exit codes
|
||||
- use as dsl or library for building Main objects
|
||||
- parsing user defined ARGV and ENV
|
||||
- zero requirements for understanding the obtuse apis of any
|
||||
command line option parsers
|
||||
- leather pants
|
||||
|
||||
In short main.rb aims to drastically lower the barrier to writing
|
||||
uniform command line applications.
|
||||
|
||||
WWW: http://codeforpeople.com/lib/ruby/main/
|
Loading…
Reference in New Issue
Block a user