DevHeads.net

Postings by botp

ruby 1.9.3p237 in cygwin

definitely not a ruby-core dev here, so hope this is ok to post.
my cygwin compile for latest ruby is failing with the ff msg...

file.o:file.c:(.text+0x4342): undefined reference to `_wcsicmp'
collect2: ld returned 1 exit status

I just hope ruby-core is not abandoning cygwin env since cygwin is my only
link to win environs..

thanks and best regards to ruby team,
-botp

looking for a ruby equivalent of python's ply

Hi all, subject says all. am looking a ruby equivalent of python's ply
(lex-yacc). cant google it, so hoping it's just hidden somewhere...

thanks and best regards -botp

looking for a ruby idiom : r=foo; return r if r

Hi All,

am looking for a ruby idiom on the ff

# some code here....

r=foo
return r if r

# some code here..

tried it w

return r if (r=foo)

but ruby complains w undefined r

so ended up w

if r=foo
return r
end

would be nice if modifiers can act like normal if

thanks for the read

kind regards -botp

request for default length/position on string index

Issue #6445 has been reported by botp (bot pena).

Author: botp (bot pena)
Status: Open
Priority: Normal
Assignee:
Category:
Target version: 2.0.0

would be nice if ruby has default for "rest or up to end of string"

eg

"hello"[2,] => should default to "hello"[2..-1]
or
"hello"[2..] => should default to "hello"[2..-1]

alias for String#index

Issue #6444 has been reported by botp (bot pena).

Author: botp (bot pena)
Status: Open
Priority: Normal
Assignee:
Category:
Target version: 2.0.0

would be nice if there is an alias for String#index

possible names:

String#find
String#search
String#pos

gem feature request: gem update should update system if needed

Hi,

would be nice if rubygem updates itself (first) if needed before any
gem is updated or downloaded..

eg,
gem update

would be equiv to

gem update --system
gem update

thanks for rubygems
kind regards -botp

nested method should only be visible by nesting/enclosing method

Issue #6287 has been reported by botp (bot pena).

Author: botp (bot pena)
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: 2.0.0

request for feature: nested methods should be private on nesting method

Hi ,

would be nice if nested methods are made private for the nesting
method only, eg

def test1
def test2
p "i am test2"
end
test2
end

test1
test2 <== this one should fail; ie only test1 should see test2

maybe to invoke test2 from outside, we may need to do test1::test2

kind regards -botp

request: rubygem to be *not* case sensitive

$ gem install redcloth
ERROR: Could not find a valid gem 'redcloth' (>= 0) in any repository
ERROR: Possible alternatives: RedCloth

thank you gem builders
kind regards -botp

my mailbox is being bombarded from an auto reply

can any ruby-talk admin unsub <a href="mailto:luca. ... at email dot it">luca. ... at email dot it</a>
for a while while the subscriber has yet to fix his/her email..

thanks
-botp

seg fault report on rdoc and ruby 1.9.2p290

while updating gems, i got the ff...

/usr/local/lib/ruby/gems/1.9.1/gems/rdoc-3.9.4/lib/rdoc/markup/attribute_manager.rb:190:
[BUG] Segmentation fault
ruby 1.9.2p290 (2011-07-09 revision 32553) [i686-linux]

c:0059 p:0028 s:0241 b:0241 l:000240 d:000240 METHOD
/usr/local/lib/ruby/gems/1.9.1/gems/rdoc-3.9.4/lib/rdoc/markup/attribute_manager.rb:190
c:0058 p:0103 s:0238 b:0238 l:000237 d:000237 METHOD
/usr/local/lib/ruby/gems/1.9.1/gems/rdoc-3.9.4/lib/rdoc/markup/attribute_manager.rb:250
c:0057 p:0018 s:0234 b:0232 l:000231 d:000231 METHOD
/usr/local/lib/ruby/gems/1.9

OT: rvm install 1.8.6 and rubygems

installing 1.8.6 using rvm fails on rubygems part.
would be nice if rvm just just skips the rubygems part for 1.8.6, or
maybe just display "note: skipping rubygems >1.4 is not supported.."
or something along that line..

best regards -botp

ps: long live 1.8.6, you served us well..

scripting an rvm command

Hi All,

sorry for this dumb question, but i'm getting zero iq as of this moment :)

i cannot seem to run properly an rvm command inside a script file. my
objective is to run a ruby script on all rvm versions installed.

eg, the ff runs fine when run thru the cli,

for i in `rvm list strings`; do rvm use "$i"; ruby -v; done

but when the above code is placed inside a script file, and then the
script is run, you wont get the expected output.

wmi client gem for linux

Hi, just trying my luck to daniel's group & friends.
Is someone working on a wmi client gem that runs on *nix, similar to
python or zens wmi client?
just found out the ubuntu has remove the wmi client in its 10.04 repository :(
thanks -botp

gems should *not be case sensitive.. or should they?

why are gem names case sensitive?

ie, gem rubyinline != gem RubyInline ??

if it's an os/arch limitation, then i'd suggest they'd be all downcased :)

eg,

$ gem list --remote | grep -i rubyinline
rogerdpack-RubyInline (3.8.2.1 ruby)
RubyInline (3.8.6)
RubyInlineAcceleration (0.0.1)
scottmotte-RubyInline (3.8.1 ruby)

botp@bg-mis-u10:~
$ sudo gem install rubyinline
[sudo] password for botp:
ERROR: Could not find a valid gem 'rubyinline' (>= 0) in any repository
botp@bg-mis-u10:~
$ sudo gem install rubyinline
ERROR: Could not find a valid gem 'rubyinline' (>= 0) in any repository
botp@bg-mi

rcr: request for __DATA__ besides __END__ ..

Hi,

in ruby there is __END__, and one can put data after that line. now
what if i want to put non-data related info thereafter..

my request would be that ruby use __DATA__ as complement to __END__
. DATA word is very easy to remember.

if __DATA__ is placed before __END__, it will not usurp __END__ and
lines below it. very handy. no clashing.

thank you and best regards
-botp

gem list --remote does not work on windows running ruby 1.9.2p0

Title says all.
This q is mainly for LuisL, but maybe someone has encountered it already...
I plan to modify gem.bat, but maybe there is a better way, so the q...

many thanks to Luis for a great ruby package for windows.

best regards -botp

sample run...

C:\downloads>gem list --remote

*** REMOTE GEMS ***

ERROR: While executing gem ...

rubygem dependencies autoremoval

Hi all, this is rubygems specific question.