librelist archives

« back to archive

are green and red shoes mutually exclusive?

are green and red shoes mutually exclusive?

From:
Sebastjan Hribar
Date:
2012-09-06 @ 12:00
Hi,

after successful installation of red shoes

(http://librelist.com/browser//shoes/2012/8/30/install-problem-on-ubuntu/#bf42310f6b6c94e372208eaa4e294894)

Green shoes stopped working. I get this error: `require': no such file
to load -- green_shoes (LoadError)

I get this error when running a green_shoes app which worked before.

regards,
seba

Re: [shoes] are green and red shoes mutually exclusive?

From:
J. Kaiden
Date:
2012-09-06 @ 18:16
hi Seba,

  ashbb can probably help you more with this question, but in my experience
-

  ...red and green are not exactly mutually exclusive, but you do sometimes
have to do some 'tweaking' to get things to run under both with exactly the
same code.  i've found it easier in the past to simply make red and green
versions of whatever i'm working on.

  ...as for the error, it sounds like you're trying to run the green shoes
code under red shoes. as i mentioned above, that can sometimes work just
fine - but one thing that will definitely be a problem is the `require
green_shoes` line.  remember that any code you run under red shoes is not
running under your system ruby, but under shoes' ruby (where there is no
green_shoes gem to be found).  the green shoes code should still run fine
in a terminal, but won't run by opening up shoes and selecting it.

  something i was (and still am) interested in doing is documenting some of
the more important differences between red and green - but as red is
undergoing a major overhaul, i figured i'd wait on that...

  the way i usually refactor code to run on red coming from green is to
simply remove the `require green_shoes` line, then see what breaks, and
then fix it.  coming from red to green is the same, except you add the
green shoes requirement.

  good luck,
  shoes on!

  - j




On Thu, Sep 6, 2012 at 12:00 PM, Sebastjan Hribar <
sebastjan.hribar@gmail.com> wrote:

> Hi,
>
> after successful installation of red shoes
> (
> 
http://librelist.com/browser//shoes/2012/8/30/install-problem-on-ubuntu/#bf42310f6b6c94e372208eaa4e294894
> )
>
> Green shoes stopped working. I get this error: `require': no such file
> to load -- green_shoes (LoadError)
>
> I get this error when running a green_shoes app which worked before.
>
> regards,
> seba
>
>

Re: [shoes] are green and red shoes mutually exclusive?

From:
Sebastjan Hribar
Date:
2012-09-06 @ 18:58
hi j,

well that's just it. I figured the same: I can't run green_shoes app in
red shoes let's say via the command open app or even via packaged app.

However, after installing red shoes and all required dependencies (I
followed the procedure on the github) I can't even run green_shoes app
from the terminal.

After runing this in the terminal:

require 'green_shoes'
Shoes.app do
   para "Welcome to Shoes"
 end

I get:
shoestest_1.rb:1:in `require': no such file to load -- green_shoes
(LoadError)
	from shoestest_1.rb:1



seba



Dne 06.09.2012 (čet) ob 18:16 +0000 je J. Kaiden napisal(a):
> hi Seba,
> 
> 
>   ashbb can probably help you more with this question, but in my
> experience -
> 
> 
>   ...red and green are not exactly mutually exclusive, but you do
> sometimes have to do some 'tweaking' to get things to run under both
> with exactly the same code.  i've found it easier in the past to
> simply make red and green versions of whatever i'm working on.
> 
> 
>   ...as for the error, it sounds like you're trying to run the green
> shoes code under red shoes. as i mentioned above, that can sometimes
> work just fine - but one thing that will definitely be a problem is
> the `require green_shoes` line.  remember that any code you run under
> red shoes is not running under your system ruby, but under shoes' ruby
> (where there is no green_shoes gem to be found).  the green shoes code
> should still run fine in a terminal, but won't run by opening up shoes
> and selecting it.
> 
> 
>   something i was (and still am) interested in doing is documenting
> some of the more important differences between red and green - but as
> red is undergoing a major overhaul, i figured i'd wait on that...
> 
> 
>   the way i usually refactor code to run on red coming from green is
> to simply remove the `require green_shoes` line, then see what breaks,
> and then fix it.  coming from red to green is the same, except you add
> the green shoes requirement.
> 
> 
>   good luck,
>   shoes on!
> 
> 
>   - j
> 
> 
> 
> 
> 
> 
> 
> On Thu, Sep 6, 2012 at 12:00 PM, Sebastjan Hribar
> <sebastjan.hribar@gmail.com> wrote:
>         Hi,
>         
>         after successful installation of red shoes
>         
(http://librelist.com/browser//shoes/2012/8/30/install-problem-on-ubuntu/#bf42310f6b6c94e372208eaa4e294894)
>         
>         Green shoes stopped working. I get this error: `require': no
>         such file
>         to load -- green_shoes (LoadError)
>         
>         I get this error when running a green_shoes app which worked
>         before.
>         
>         regards,
>         seba
>         
> 
> 

Re: [shoes] are green and red shoes mutually exclusive?

From:
J. Kaiden
Date:
2012-09-06 @ 19:39
On Thu, Sep 6, 2012 at 6:58 PM, Sebastjan Hribar <sebastjan.hribar@gmail.com
> wrote:

>
>
> After runing this in the terminal:
>
> require 'green_shoes'
> Shoes.app do
>    para "Welcome to Shoes"
>  end
>
> I get:
> shoestest_1.rb:1:in `require': no such file to load -- green_shoes
> (LoadError)
>         from shoestest_1.rb:1
>


  hmm...  that's odd.  what do you get when you run `which ruby` in the
terminal?  and how about `gem list` ?  do you see green_shoes listed there?

  i use rvm, which can make different versions of ruby much easier to
manage - and typically write and run code through Scite...  in Scite i've
specified different rubies to use at runtime (with a full path) depending
on whether i'm using red, green, purple, or whatever.  that's maybe a
little strange, and probably not the way you're doing it.

  check out what `which ruby` tells you...  if it says that you're running
a ruby from a shoes directory, then that's why it's not working - although
i'd be kind of surprised if the shoes ruby had become your default system
ruby.  you could also try specifying which ruby to use with a shebang at
the top of your code, something like:

#!/path/to/ruby/with_green_shoes

require 'green_shoes'
Shoes.app do
   para "Welcome to Shoes"
 end

  wish i could be of more help - good luck!

  - j

Re: [shoes] are green and red shoes mutually exclusive?

From:
Sebastjan Hribar
Date:
2012-09-07 @ 07:04
Hi,

to tell you the truth I am kinda frustrated and I don't know where to go
from here.

First:
which ruby outputs => /usr/bin/ruby

Second:
gem list doesn't include green_shoes gem; however I know I've installed
it since I've been using it prior to red shoes installation


I've noticed that the file .bash_profile was created and wasn't there
before the red shoes installation step: 

echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" #
Load RVM function' >> ~/.bash_profile
source ~/.bash_profile

Third:
What exactly must I add to .bashrc to make rvm load allways and I don't
have to load it every time with source ~/.rvm/scripts/rvm?

Last:
I am not an experienced user and tweaking to make all shoes distros work
isn't an option for me yet:(
Therefore can anyone tell me how would I remove and purge the red shoes
after the installation I've made according to github instructions
(https://github.com/shoes/shoes/wiki/Building-Shoes-on-Linux). So that I
only have working green_shoes.
 

regards,
seba


Dne 06.09.2012 (čet) ob 19:39 +0000 je J. Kaiden napisal(a):
> 
> 
> On Thu, Sep 6, 2012 at 6:58 PM, Sebastjan Hribar
> <sebastjan.hribar@gmail.com> wrote:
>         
>         
>         After runing this in the terminal:
>         
>         require 'green_shoes'
>         Shoes.app do
>            para "Welcome to Shoes"
>          end
>         
>         I get:
>         shoestest_1.rb:1:in `require': no such file to load --
>         green_shoes
>         (LoadError)
>                 from shoestest_1.rb:1
> 
> 
> 
> 
>   hmm...  that's odd.  what do you get when you run `which ruby` in
> the terminal?  and how about `gem list` ?  do you see green_shoes
> listed there?
> 
> 
>   i use rvm, which can make different versions of ruby much easier to
> manage - and typically write and run code through Scite...  in Scite
> i've specified different rubies to use at runtime (with a full path)
> depending on whether i'm using red, green, purple, or whatever.
>  that's maybe a little strange, and probably not the way you're doing
> it.
> 
> 
>   check out what `which ruby` tells you...  if it says that you're
> running a ruby from a shoes directory, then that's why it's not
> working - although i'd be kind of surprised if the shoes ruby had
> become your default system ruby.  you could also try specifying which
> ruby to use with a shebang at the top of your code, something like:
> 
> 
> #!/path/to/ruby/with_green_shoes
> 
> 
> require 'green_shoes'
> Shoes.app do
>    para "Welcome to Shoes"
>  end
> 
> 
>   wish i could be of more help - good luck!
> 
> 
>   - j

Re: [shoes] are green and red shoes mutually exclusive?

From:
Hawley Waldman
Date:
2012-09-07 @ 10:09
From what I can piece together by reading your posts I think that your 
problem may be that you installed the green_shoes gem with an rvm ruby 
running and now you're looking for it with a non-rvm ruby running, or visa
versa. 

Regarding getting rvm to load automagically each time you open a terminal,
from the rvm install instructions I expected to have to do something extra
for this, but after the install I changed my prompt to indicate whether 
rvm was running and which ruby it was using and I found that it was 
already being loaded/run. So, follow the instructions for making your 
prompt an indicator and see what you find. 

Bottom line is that I'd suggest you list your gems, and if you don't see 
green_shoes, install it (even though you have already installed it in one 
of your ruby installs).  Then try running the little "welcome to green 
shoes" program below. My guess is that it will work.  After that, it's in 
your best interest to sort out your rvm questions and make use of rvm's 
ruby version/gem segregation benefits to keep a nice clean ruby install 
alongside a ruby install that includes miscellaneous, potentially 
experimental gems. 

-Hawley

On Sep 7, 2012, at 3:04, Sebastjan Hribar <sebastjan.hribar@gmail.com> wrote:

> Hi,
> 
> to tell you the truth I am kinda frustrated and I don't know where to go
> from here.
> 
> First:
> which ruby outputs => /usr/bin/ruby
> 
> Second:
> gem list doesn't include green_shoes gem; however I know I've installed
> it since I've been using it prior to red shoes installation
> 
> 
> I've noticed that the file .bash_profile was created and wasn't there
> before the red shoes installation step: 
> 
> echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" #
> Load RVM function' >> ~/.bash_profile
> source ~/.bash_profile
> 
> Third:
> What exactly must I add to .bashrc to make rvm load allways and I don't
> have to load it every time with source ~/.rvm/scripts/rvm?
> 
> Last:
> I am not an experienced user and tweaking to make all shoes distros work
> isn't an option for me yet:(
> Therefore can anyone tell me how would I remove and purge the red shoes
> after the installation I've made according to github instructions
> (https://github.com/shoes/shoes/wiki/Building-Shoes-on-Linux). So that I
> only have working green_shoes.
> 
> 
> regards,
> seba
> 
> 
> Dne 06.09.2012 (čet) ob 19:39 +0000 je J. Kaiden napisal(a):
>> 
>> 
>> On Thu, Sep 6, 2012 at 6:58 PM, Sebastjan Hribar
>> <sebastjan.hribar@gmail.com> wrote:
>> 
>> 
>>        After runing this in the terminal:
>> 
>>        require 'green_shoes'
>>        Shoes.app do
>>           para "Welcome to Shoes"
>>         end
>> 
>>        I get:
>>        shoestest_1.rb:1:in `require': no such file to load --
>>        green_shoes
>>        (LoadError)
>>                from shoestest_1.rb:1
>> 
>> 
>> 
>> 
>>  hmm...  that's odd.  what do you get when you run `which ruby` in
>> the terminal?  and how about `gem list` ?  do you see green_shoes
>> listed there?
>> 
>> 
>>  i use rvm, which can make different versions of ruby much easier to
>> manage - and typically write and run code through Scite...  in Scite
>> i've specified different rubies to use at runtime (with a full path)
>> depending on whether i'm using red, green, purple, or whatever.
>> that's maybe a little strange, and probably not the way you're doing
>> it.
>> 
>> 
>>  check out what `which ruby` tells you...  if it says that you're
>> running a ruby from a shoes directory, then that's why it's not
>> working - although i'd be kind of surprised if the shoes ruby had
>> become your default system ruby.  you could also try specifying which
>> ruby to use with a shebang at the top of your code, something like:
>> 
>> 
>> #!/path/to/ruby/with_green_shoes
>> 
>> 
>> require 'green_shoes'
>> Shoes.app do
>>   para "Welcome to Shoes"
>> end
>> 
>> 
>>  wish i could be of more help - good luck!
>> 
>> 
>>  - j
> 
> 

Re: [shoes] are green and red shoes mutually exclusive?

From:
Sebastjan Hribar
Date:
2012-09-07 @ 11:39
Thank you for pointing me in the right direction.

My problem is that rvm is not loaded automatically or even in every
terminal. After I load it, there are all the gems including the green
shoes. And I've checked and the ruby version is also ok.

I just have to make rvm load automatically.

thank you all
regards
seba

Dne 07.09.2012 (pet) ob 06:09 -0400 je Hawley Waldman napisal(a):
> From what I can piece together by reading your posts I think that your 
problem may be that you installed the green_shoes gem with an rvm ruby 
running and now you're looking for it with a non-rvm ruby running, or visa
versa. 
> 
> Regarding getting rvm to load automagically each time you open a 
terminal, from the rvm install instructions I expected to have to do 
something extra for this, but after the install I changed my prompt to 
indicate whether rvm was running and which ruby it was using and I found 
that it was already being loaded/run. So, follow the instructions for 
making your prompt an indicator and see what you find. 
> 
> Bottom line is that I'd suggest you list your gems, and if you don't see
green_shoes, install it (even though you have already installed it in one 
of your ruby installs).  Then try running the little "welcome to green 
shoes" program below. My guess is that it will work.  After that, it's in 
your best interest to sort out your rvm questions and make use of rvm's 
ruby version/gem segregation benefits to keep a nice clean ruby install 
alongside a ruby install that includes miscellaneous, potentially 
experimental gems. 
> 
> -Hawley
> 
> On Sep 7, 2012, at 3:04, Sebastjan Hribar <sebastjan.hribar@gmail.com> wrote:
> 
> > Hi,
> > 
> > to tell you the truth I am kinda frustrated and I don't know where to go
> > from here.
> > 
> > First:
> > which ruby outputs => /usr/bin/ruby
> > 
> > Second:
> > gem list doesn't include green_shoes gem; however I know I've installed
> > it since I've been using it prior to red shoes installation
> > 
> > 
> > I've noticed that the file .bash_profile was created and wasn't there
> > before the red shoes installation step: 
> > 
> > echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" #
> > Load RVM function' >> ~/.bash_profile
> > source ~/.bash_profile
> > 
> > Third:
> > What exactly must I add to .bashrc to make rvm load allways and I don't
> > have to load it every time with source ~/.rvm/scripts/rvm?
> > 
> > Last:
> > I am not an experienced user and tweaking to make all shoes distros work
> > isn't an option for me yet:(
> > Therefore can anyone tell me how would I remove and purge the red shoes
> > after the installation I've made according to github instructions
> > (https://github.com/shoes/shoes/wiki/Building-Shoes-on-Linux). So that I
> > only have working green_shoes.
> > 
> > 
> > regards,
> > seba
> > 
> > 
> > Dne 06.09.2012 (čet) ob 19:39 +0000 je J. Kaiden napisal(a):
> >> 
> >> 
> >> On Thu, Sep 6, 2012 at 6:58 PM, Sebastjan Hribar
> >> <sebastjan.hribar@gmail.com> wrote:
> >> 
> >> 
> >>        After runing this in the terminal:
> >> 
> >>        require 'green_shoes'
> >>        Shoes.app do
> >>           para "Welcome to Shoes"
> >>         end
> >> 
> >>        I get:
> >>        shoestest_1.rb:1:in `require': no such file to load --
> >>        green_shoes
> >>        (LoadError)
> >>                from shoestest_1.rb:1
> >> 
> >> 
> >> 
> >> 
> >>  hmm...  that's odd.  what do you get when you run `which ruby` in
> >> the terminal?  and how about `gem list` ?  do you see green_shoes
> >> listed there?
> >> 
> >> 
> >>  i use rvm, which can make different versions of ruby much easier to
> >> manage - and typically write and run code through Scite...  in Scite
> >> i've specified different rubies to use at runtime (with a full path)
> >> depending on whether i'm using red, green, purple, or whatever.
> >> that's maybe a little strange, and probably not the way you're doing
> >> it.
> >> 
> >> 
> >>  check out what `which ruby` tells you...  if it says that you're
> >> running a ruby from a shoes directory, then that's why it's not
> >> working - although i'd be kind of surprised if the shoes ruby had
> >> become your default system ruby.  you could also try specifying which
> >> ruby to use with a shebang at the top of your code, something like:
> >> 
> >> 
> >> #!/path/to/ruby/with_green_shoes
> >> 
> >> 
> >> require 'green_shoes'
> >> Shoes.app do
> >>   para "Welcome to Shoes"
> >> end
> >> 
> >> 
> >>  wish i could be of more help - good luck!
> >> 
> >> 
> >>  - j
> > 
> > 

Re: [shoes] are green and red shoes mutually exclusive?

From:
ashbb
Date:
2012-09-07 @ 12:06
Hi Sebastjan,

Glad to hear that you solved the install problem.

BTW, about `require 'green_shoes'`.
You don't need to add it in your app. ;-)

For example:

# hello.rb
Shoes.app do
  para 'hello'
end

Open the console window and type:
$ shoes hello.rb   # run hello.rb with Red Shoes
$ gshoes hello.rb  # run hello.rb with Green Shoes
$ pshoes hello.rb  # run hello.rb with Purple Shoes

ashbb

Re: [shoes] are green and red shoes mutually exclusive?

From:
peter marien
Date:
2012-09-06 @ 19:06
Hi seba, i use red, green, purple, jruby and regular ruby side by side but
each needs its own environment variables set so i have batches (i'm on
windows) to set these in every home folder of the distro and most of the
time it works.
Most of the time i don't convert from one color to another because too
frustrating.

Succes !

Peter

2012/9/6 Sebastjan Hribar <sebastjan.hribar@gmail.com>

> hi j,
>
> well that's just it. I figured the same: I can't run green_shoes app in
> red shoes let's say via the command open app or even via packaged app.
>
> However, after installing red shoes and all required dependencies (I
> followed the procedure on the github) I can't even run green_shoes app
> from the terminal.
>
> After runing this in the terminal:
>
> require 'green_shoes'
> Shoes.app do
>    para "Welcome to Shoes"
>  end
>
> I get:
> shoestest_1.rb:1:in `require': no such file to load -- green_shoes
> (LoadError)
>         from shoestest_1.rb:1
>
>
>
> seba
>
>
>
> Dne 06.09.2012 (čet) ob 18:16 +0000 je J. Kaiden napisal(a):
> > hi Seba,
> >
> >
> >   ashbb can probably help you more with this question, but in my
> > experience -
> >
> >
> >   ...red and green are not exactly mutually exclusive, but you do
> > sometimes have to do some 'tweaking' to get things to run under both
> > with exactly the same code.  i've found it easier in the past to
> > simply make red and green versions of whatever i'm working on.
> >
> >
> >   ...as for the error, it sounds like you're trying to run the green
> > shoes code under red shoes. as i mentioned above, that can sometimes
> > work just fine - but one thing that will definitely be a problem is
> > the `require green_shoes` line.  remember that any code you run under
> > red shoes is not running under your system ruby, but under shoes' ruby
> > (where there is no green_shoes gem to be found).  the green shoes code
> > should still run fine in a terminal, but won't run by opening up shoes
> > and selecting it.
> >
> >
> >   something i was (and still am) interested in doing is documenting
> > some of the more important differences between red and green - but as
> > red is undergoing a major overhaul, i figured i'd wait on that...
> >
> >
> >   the way i usually refactor code to run on red coming from green is
> > to simply remove the `require green_shoes` line, then see what breaks,
> > and then fix it.  coming from red to green is the same, except you add
> > the green shoes requirement.
> >
> >
> >   good luck,
> >   shoes on!
> >
> >
> >   - j
> >
> >
> >
> >
> >
> >
> >
> > On Thu, Sep 6, 2012 at 12:00 PM, Sebastjan Hribar
> > <sebastjan.hribar@gmail.com> wrote:
> >         Hi,
> >
> >         after successful installation of red shoes
> >         (
> 
http://librelist.com/browser//shoes/2012/8/30/install-problem-on-ubuntu/#bf42310f6b6c94e372208eaa4e294894
> )
> >
> >         Green shoes stopped working. I get this error: `require': no
> >         such file
> >         to load -- green_shoes (LoadError)
> >
> >         I get this error when running a green_shoes app which worked
> >         before.
> >
> >         regards,
> >         seba
> >
> >
> >
>
>
>