[#393699] Missing messages — Eric Christopherson <echristopherson@...>
I've been missing a lot of messages in my Gmail the past few days that
[#393725] Inconsistent behaviour when working with a string — Tris Hoar <trishoar@...>
Hi List,
[#393730] Configuration Convention — Intransition <transfire@...>
This is probably one of this topics that will get little attention.
[#393738] How to detect Linux Kernel and glibc version? — Iñaki Baz Castillo <ibc@...>
Hi, for a Ruby C extension I need to check in extconf.rb the Linux
I単aki Baz Castillo <ibc@aliax.net> wrote:
2012/3/7 Eric Wong <normalperson@yhbt.net>:
[#393742] Getting the class of an object. — Ralph Shnelvar <ralphs@...32.com>
Consider;
On Tue, Mar 6, 2012 at 5:34 PM, Ralph Shnelvar <ralphs@dos32.com> wrote:
On 07/03/12 07:15, Robert Klemme wrote:
[#393759] http://ruby-doc.org/docs/keywords/1.9/ : (Object) — Ralph Shnelvar <ralphs@...32.com>
What is the purpose of
Object is their class, and the root object in Ruby. (Well,
[#393767] Re: Time. to_military_time? — Robert Klemme <shortcutter@...>
Mario Trento wrote in post #1050518:
[#393772] Proc.new v. lambda — Ralph Shnelvar <ralphs@...32.com>
Is there a way to programmatically determine if an object was generated by Proc.new versus lambda?
[#393798] Lightrail 0.99.0: minimalist Rails 3 stack for JSON APIs — Tony Arcieri <tony.arcieri@...>
One of the great advancements of Rails 3 brought to the table was enough
[#393810] Re: Problem replacing $data[abc] with $data['abc'] using gsub — "Jan E." <jan.e@...>
The part ".*?" of the regular expression is very inefficient, because it
Jan E. wrote in post #1051180:
[#393815] arcadia IDE requires tcl/tk and ruby-tk — Thufir Hawat <hawat.thufir@...>
which or where tcl and tk does arcadia require? Is this a gem which I
[#393820] Re: Any function similar to PHP's file_get_contents() ? — "Jan E." <jan.e@...>
To avoid this, you could simply write
2012/3/13 Jan E. <jan.e@online.de>:
You need to require 'open-uri' first, then it will work. But
2012/3/13 Bartosz Dziewo=C5=84ski <matma.rex@gmail.com>:
On Tue, Mar 13, 2012 at 5:41 PM, I=C3=B1aki Baz Castillo <ibc@aliax.net> wr=
[#393867] Converting Bignum into bytes — Victor Blaga <vic.blaga@...>
Hi all,
[#393889] noob: http script to google finance — Sean Felipe Wolfe <ether.joe@...>
Hello everybody, I'm learning Ruby, coming from Java and Python.
Hi,
[#393903] Re: why no decreasing enumerations? — "Jan E." <jan.e@...>
Hi,
[#393906] Re: why no decreasing enumerations? — "Jan E." <jan.e@...>
Well, I'm glad for his objections. I don't think we need another PHP
[#393909] SCRIPT_LINES__ — Xavier Noria <fxn@...>
If the constant SCRIPT_LINES__ is defined and holds a hash, for each file
[#393924] Re: why no decreasing enumerations? — "Jan E." <jan.e@...>
If you actually have to do this task all the time, you could define your
[#393931] Re: network user with sinatra — Robert Klemme <shortcutter@...>
Mario Ruiz wrote in post #1052276:
[#393952] What’s the best way to check if a feature/class has been loaded? — Nikolai Weibull <now@...>
Hi!
Active Support has recently added qualified_const_* methods to Module
Ah, that won't work in 1.8.
On Wed, Mar 21, 2012 at 16:43, Xavier Noria <fxn@hashref.com> wrote:
On Wed, Mar 21, 2012 at 8:17 PM, Nikolai Weibull <now@bitwi.se> wrote:
On Wed, Mar 21, 2012 at 20:48, Xavier Noria <fxn@hashref.com> wrote:
On Wed, Mar 21, 2012 at 9:51 PM, Nikolai Weibull <now@bitwi.se> wrote:
On Wed, Mar 21, 2012 at 22:11, Xavier Noria <fxn@hashref.com> wrote:
On Thu, Mar 22, 2012 at 6:15 AM, Nikolai Weibull <now@bitwi.se> wrote:
On Thu, Mar 22, 2012 at 06:56, Xavier Noria <fxn@hashref.com> wrote:
Your emails mix classes, constants, and paths.
And another question.
On Thu, Mar 22, 2012 at 09:35, Xavier Noria <fxn@hashref.com> wrote:
[#393971] SSH hangs for a particular command in SSH.exec!(cmd) — Meena Valliappan <lists@...>
Hi All,
On Thu, Mar 22, 2012 at 3:12 PM, Meena Valliappan <lists@ruby-forum.com> wr=
[#393980] gem install rmagick requires imagemagick — thufir <hawat.thufir@...>
I was trying to just do a CLI short (very short) script with activerecord
[#393991] ActiveRecord and working with sequences — David Kerr <dmk@...>
Howdy,
[#394004] Dynamic Gem Server Docs — Intransition <transfire@...>
Anyone else thing Gem Server documentation should work like this?
[#394006] Write to kernel buffer? — ruby rub <lists@...>
Is it possible to use Ruby to specifically write to the kernel buffer?
[#394011] Specification for the Ruby Language(current) — Carter Cheng <cartercheng@...>
Hello,
It's impossible to know if a language conforms to an on-paper
Hi Tony,
No, the Ruby language's specification is laboriously written by hand:
Thanks Tony. I was wondering if there was some official language
[#394017] unsubscribe — Edward Michaels <micahfsu@...>
[#394020] rvm / gem install not working (zlib issue) on ubuntu — Stephen Boesch <lists@...>
Hi
i think this is your solution: http://beginrescueend.com/packages/zlib/
[#394035] Need to create a file-sharing client like Gnutella, where to start? — Bharadwaj Srigiriraju <lists@...>
I am a newbie and I am excited about how Ruby works :)
Bharadwaj Srigiriraju wrote in post #1053068:
Brian Candler wrote in post #1053069:
Bharadwaj Srigiriraju wrote in post #1053083:
[#394037] Ruby speed compared to C in a simple calculations. — Роман Ткаленко <rain.roman@...>
#works for 3.55 mins
[#394051] Emoticon Code — Marc Heiler <lists@...>
Hmm. These emoticons are valid ruby code (symbols):
[#394052] Google Summer of Code proposals open TODAY! — Charles Oliver Nutter <headius@...>
I posted previously about JRuby being accepted to the Google Summer of
We've had a lot of good discussions on IRC, and IM and twitter about
[#394053] ruby-net-nntp usage — Thufir <hawat.thufir@...>
am I not using the correct requires info? So far as I can tell, I've
[#394054] net/ssh telnet set port 119 (nntp) — Thufir <hawat.thufir@...>
Following the API at:
[#394056] Array handling trouble for new guy — Aaron Brink <lists@...>
Greetings all,
[#394066] Undecided on how to approach a problem of storing html tables in a database — "Scott H." <lists@...>
Hi guys
On 2012-03-26 11:22:30, Scott H. wrote:
[#394079] Path problem on Windows: backslash vs forward slash — Serguei Cambour <lists@...>
I can't figure out why the below code works fine:
[#394099] sort array of strings with integers — Ri Houjun <lists@...>
i have this array
[#394109] RVM setup on Mac OS X Lion 10.7.3 won't build RI documetation — David Souza <lists@...>
Just wondering if anyone has seen this before... now matter what I do on
On my lion I had to install Xcode 4.3.1 And then after that the Xcode comman=
[#394124] How to access Class variable? — Ruby Mania <lists@...>
A really stupid question but I am new to OO ruby
[#394125] rubygems.org SSL problem — Suraj Kurapati <sunaku@...>
I just visited rubygems.org and Chromium is reporting that its SSL
I use google chrome Version 19.0.1083.0 canary on Mac OS X Lion..
Am 28. M=E4rz 2012 07:26 schrieb Jose Figueroa <josen.figueroa@unixmexico.o=
Martin Bosslet wrote in post #1053736:
[#394136] How to process telnet data(binary) — Fengfeng Li <lists@...>
Hi everyone,
[#394140] copy file into new without dups, eol problem — Mario Trento <lists@...>
File.open("newf.txt", "w+") { |file| file.puts
Hi,
On 03/28/2012 04:25 PM, Jan E. wrote:
Jeremy Bopp wrote in post #1053841:
[#394154] uninitialized constant SOCKSSocket — Resident Moron <lists@...>
I am running ruby 1.9.3 on a linux box. I would like to use
It appears the class is only being defined if it's already defined.
Oh and be sure to stringify/symbolify that undefined const:
Actually, no, sorry, I just said a silly thing. Sorry, been writing
Matthew Kerwin wrote in post #1053913:
[#394160] Why z = Complex(1,2) rather than z = Complex.new(1,2)? — Ori Ben-Dor <lists@...>
What's this syntax, z = Complex(1,2), as opposed to z =
But doesn't it break the convention? I mean, the convention is using a
On Mar 29, 2012, at 8:31 AM, Ori Ben-Dor wrote:
[#394172] ECDSA encryption with OpenSSL — "Henri S." <lists@...>
Trying to do a simple ECDSA encryption using openSSL library
[#394175] shoes no such file to load -- rubygems — Mr theperson <lists@...>
I have installed shoes to develop GUI applications but when I try and
How did you install shoes?
Steve Klabnik wrote in post #1054001:
This error happens when you apt-get install shoes; it has an
Steve Klabnik wrote in post #1054006:
If you've built it successfully, shoes will be in the dist directory.
I installed cURL but i now get this error when I run rake
[#394201] Can't open url with a subdomain with an underscore — Jeroen van Ingen <lists@...>
I try to open the following URL: http://auto_diversen.marktplaza.nl/
Underscore is not a valid character in a hostname, thus Ruby rejects it.
Bartosz Dziewo=C5=84ski wrote in post #1054173:
if I have the following url: http://auto_diversen.marktplaza.nl
[#394205] Apparent Math issues — Steven Owens <lists@...>
Hello guys,
[#394222] Ruby openssl ECC help plz — no name <lists@...>
I am confused on how to properly export public ECC key. I can see it
[#394228] Ruby regex match hex string — Niels Steves <lists@...>
Hey guys,
Hi,
[#394229] regexp replace every other one — gabe gabriellini <lists@...>
When i have a string like:
[#394241] Capturing return value from method invoked with 'send' — Doug Jolley <lists@...>
Is there a way to capture the return value from a method that was
rib 1.0.4 released
## Rib <https://github.com/godfat/rib>
by Lin Jen-Shin ([godfat](http://godfat.org))
## DESCRIPTION:
Ruby-Interactive-ruBy -- Yet another interactive Ruby shell
Rib is based on the design of [ripl] and the work of [ripl-rc], some
of
the features are also inspired by [pry]. The aim of Rib is to be fully
featured and yet very easy to opt-out or opt-in other features. It
shall
be simple, lightweight and modular so that everyone could customize
Rib.
[ripl]: https://github.com/cldwalker/ripl
[ripl-rc]: https://github.com/godfat/ripl-rc
[pry]: https://github.com/pry/pry
## INSTALLATION:
gem install rib
### SYNOPSIS:
https://github.com/godfat/rib/raw/master/screenshot.png
### As an interactive shell
As IRB (reads `~/.rib/config.rb` writes `~/.rib/history.rb`)
rib
As Rails console
rib rails
You could also run in production and pass arguments normally as you'd
do in
`rails console` or `./script/console`
rib rails production --sandbox --debugger
Note: You might need to add ruby-debug or ruby-debug19 to your Gemfile
if
you're passing --debugger and using bundler together.
As Ramaze console
rib ramaze
As a console for whichever the app in the current path
it should be (for now, it's either Rails or Ramaze)
rib auto
If you're trying to use `rib auto` for a Rails app, you could also
pass
arguments as if you were using `rib rails`. `rib auto` is merely
passing
arguments.
rib auto production --sandbox --debugger
As a fully featured interactive Ruby shell (as ripl-rc)
rib all
As a fully featured app console (yes, some commands could be used
together)
rib all auto # or `rib auto all`, the order doesn't really matter
You can customize Rib's behaviour by setting a config file located at
`~/.rib/config.rb` or `~/.config/rib/config.rb`, or `$RIB_HOME/
config.rb` by
setting `$RIB_HOME` environment variable. Since it's merely a Ruby
script
which would be loaded into memory before launching Rib shell session,
You can
put any customization or monkey patch there. Personally, I use all
plugins
provided by Rib.
<https://github.com/godfat/dev-tool/blob/master/.config/rib/config.rb>
As you can see, putting `require 'rib/all'` into config file is
exactly the
same as running `rib all` without a config file. What `rib all` would
do is
merely require the file, and that file is also merely requiring all
plugins,
but without **extra plugins**, which you should enable them one by
one. This
is because most extra plugins are depending on other gems, or hard to
work
with other plugins, or having strong personal tastes, so you won't
want to
enable them all. Suppose you only want to use the core plugins and
color
plugin, you'll put this into your config file:
require 'rib/core'
require 'rib/more/color'
You can also write your plugins there. Here's another example:
require 'rib/core'
require 'pp'
Rib.config[:prompt] = '$ '
module RibPP
Rib::Shell.send(:include, self)
def format_result result
result_prompt + result.pretty_inspect
end
end
So that we override the original format_result to pretty_inspect the
result.
You can also build your own gem and then simply require it in your
config
file. To see a list of overridable API, please read [api.rb][]
Currently, there are two **extra plugins**.
* `require 'rib/extra/autoindent'` This plugin is depending on:
1. [readline_buffer][]
2. readline plugin
3. multiline plugin
* `require 'rib/extra/hirb'` This plugin is depending on:
1. [hirb][]
[api.rb]: https://github.com/godfat/rib/blob/master/lib/rib/api.rb
[readline_buffer]: https://github.com/godfat/readline_buffer
[hirb]: https://github.com/cldwalker/hirb
#### Basic configuration
Rib.config | Functionality
-------------------------- |
-------------------------------------------------
ENV['RIB_HOME'] | Specify where Rib should store config and
history
Rib.config[:config] | The path where config should be located
Rib.config[:name] | The name of this shell
Rib.config[:result_prompt] | Default is "=>"
Rib.config[:prompt] | Default is ">>"
Rib.config[:binding] | Context, default: TOPLEVEL_BINDING
Rib.config[:exit] | Commands to exit, default [nil] # control
+d
#### Plugin specific configuration
Rib.config | Functionality
------------------------------ |
---------------------------------------------
Rib.config[:completion] | Completion: Bond config
Rib.config[:history_file] | Default is "~/.rib/config/history.rb"
Rib.config[:history_size] | Default is 500
Rib.config[:color] | A hash of Class => :color mapping
Rib.config[:autoindent_spaces] | How to indent? Default is two spaces:
' '
### As a debugging/interacting tool
Rib could be used as a kind of debugging tool which you can set break
point
in the source program.
require 'rib/config' # This would load your Rib config
require 'rib/more/anchor'
# If you enabled anchor in config, then
needed not
Rib.anchor binding # This would give you an interactive shell
# when your program has been executed here.
Rib.anchor 123 # You can also anchor on an object.
But this might be called in a loop, you might only want to
enter the shell under certain circumstance, then you'll do:
require 'rib/debug'
Rib.enable_anchor do
# Only `Rib.anchor` called in the block would launch a shell
end
Rib.anchor binding # No effect (no-op) outside the block
Anchor could also be nested. The level would be shown on the prompt,
starting from 1.
### In place editing
Whenever you called:
require 'rib/more/edit'
Rib.edit
Rib would open an editor according to $EDITOR (`ENV['EDITOR']`) for
you.
After save and leave the editor, Rib would evaluate what you had
input.
This also works inside an anchor. To use it, require either rib/more/
edit
or rib/more or rib/all.
### As a shell framework
The essence is:
require 'rib'
All others are optional. The core plugins are lying in `rib/core/
*.rb`, and
more plugins are lying in `rib/more/*.rb`. You can read `rib/app/
ramaze.rb`
and `bin/rib-ramaze` as a Rib App reference implementation, because
it's very
simple, simpler than rib-rails.
## CHANGES:
### Rib 1.0.4 -- 2012-03-20
* [core/multiline] Fixed a corner case:
1/1.to_i +
1
* [rib] Do not crash because of a loop error. Try to relaunch the
shell.