Discussion:
[TxMt] TextMate on OS X 10.3.9
Darryl Morrell
2006-09-17 05:09:50 UTC
Permalink
I recently acquired TextMate 1.5.3, and am overall very pleased with
it. However, I am running OS X 10.3.9, and several bundles do not work
correctly. In particular, several commands in the Latex and TODO
bundles do not work. Some of the problems were fixed by installing
Ruby 1.8 from Fink, but many others remain. Any help would be
appreciated.

Darryl Morrell
Charilaos Skiadas
2006-09-17 06:07:09 UTC
Permalink
Post by Darryl Morrell
I recently acquired TextMate 1.5.3, and am overall very pleased
with it. However, I am running OS X 10.3.9, and several bundles do
not work correctly. In particular, several commands in the Latex
and TODO bundles do not work. Some of the problems were fixed by
installing Ruby 1.8 from Fink, but many others remain. Any help
would be appreciated.
A lot of bundle commands require Ruby 1.8, and as far as I know
that's the only problem with 10.3.9, so if there are still commands
you can't run, then you should probably tell us what they are and
what error messages you get.
Post by Darryl Morrell
Darryl Morrell
Haris
Darryl Morrell
2006-09-19 06:14:54 UTC
Permalink
A typical problem is the bold command in the Latex bundle. Instead of
inserting "textbf{}", it inserts "env: ruby -s: No such file or
directory". The bold command seems to work if I replace the first line
in toggle_style.rb with "#!/usr/bin/ruby -s". (I have created a link
so that /usr/bin/ruby links to Ruby 1.8 installed from Fink.)

Will I break things if I change the first line of the various ruby
scripts from "#!/usr/bin/env ruby -s" to "#!/usr/bin/ruby -s"?

Thanks for your help,

Darryl
Post by Darryl Morrell
I recently acquired TextMate 1.5.3, and am overall very pleased with
it. However, I am running OS X 10.3.9, and several bundles do not
work correctly. In particular, several commands in the Latex and
TODO bundles do not work. Some of the problems were fixed by
installing Ruby 1.8 from Fink, but many others remain. Any help
would be appreciated.
A lot of bundle commands require Ruby 1.8, and as far as I know that's
the only problem with 10.3.9, so if there are still commands you can't
run, then you should probably tell us what they are and what error
messages you get.
Post by Darryl Morrell
Darryl Morrell
Haris
c***@cyanite.org
2006-09-19 07:01:05 UTC
Permalink
Post by Darryl Morrell
Will I break things if I change the first line of the various ruby
scripts from "#!/usr/bin/env ruby -s" to "#!/usr/bin/ruby -s"?
No, I believe the env command is used to select the correct ruby command
at run-time (the first one in the PATH). So just providing the correct
path manually, will work as well.

I guess the problem is that the older env command doesn't allow arguments
for the commands following it, so it tries to start 'ruby -s' instead of
'ruby' with '-s' as argument.

-- Sune.
Tim Lahey
2006-09-19 18:34:35 UTC
Permalink
I've installed ruby 1.8.1 using fink on 10.3.9 and
when I try the command insert environment based
upon current word (using equation as an example)
I get the error,

dyld: ruby Undefined symbols:
_rb_attr_get
_rb_ll2inum
_rb_num2ll
_rb_string_value

Any ideas for how to fix this? Is there something
I need to add to a config file somewhere?

Thanks,

Tim.
Allan Odgaard
2006-09-19 22:02:34 UTC
Permalink
Post by Tim Lahey
I've installed ruby 1.8.1 using fink on 10.3.9 and
when I try the command insert environment based
upon current word (using equation as an example)
I get the error,
dyld: ruby Undefined symbols: [...]
It would seem that Ruby got built to rely on some shared library
which you do not have or similar.

Try run ruby from the shell and see if you do not get a similar error.
Tim Lahey
2006-09-19 23:49:37 UTC
Permalink
Using the simplest possible example script,

#!/usr/bin/env ruby
print "Hello World\n"

from the command line I get no errors. I
suspect that it is one of the libraries that
TextMate is including when this line is
run,

require "#{ENV['TM_SUPPORT_PATH']}/lib/plist"

Unfortunately, I don't know what this is doing
since I'm not that familiar with Ruby or
TextMate.

Ideas?

Thanks,

Tim.
Post by Allan Odgaard
Post by Tim Lahey
I've installed ruby 1.8.1 using fink on 10.3.9 and
when I try the command insert environment based
upon current word (using equation as an example)
I get the error,
dyld: ruby Undefined symbols: [...]
It would seem that Ruby got built to rely on some shared library
which you do not have or similar.
Try run ruby from the shell and see if you do not get a similar error.
______________________________________________________________________
(threading gets destroyed and the universe will collapse if you don't)
http://lists.macromates.com/mailman/listinfo/textmate
Allan Odgaard
2006-09-20 01:47:35 UTC
Permalink
Post by Tim Lahey
Using the simplest possible example script,
#!/usr/bin/env ruby
print "Hello World\n"
There is a chance this will load your default ruby.

Please try (from terminal):

/sw/bin/ruby -e 'p :hello'
Post by Tim Lahey
[...] require "#{ENV['TM_SUPPORT_PATH']}/lib/plist"
This loads a ruby extension bundled with TM. It is not unlikely that
this one is the one relying on the symbols, you can test that by
adding the following to the line above:

-r/path/to/TextMate.app/Contents/SharedSupport/Support/lib/plist

If it is the plist extension, then that should give the same errors
(where the previous line would have worked).
Tim Lahey
2006-09-20 02:12:22 UTC
Permalink
Hmmm, when I run this I get
:hello

for everything I try. So I'm wondering
what's happening. It certainly appears that
everything is okay with the ruby installation.

Now I'm really not sure what is wrong.

Thanks,

Tim.
Post by Allan Odgaard
There is a chance this will load your default ruby.
/sw/bin/ruby -e 'p :hello'
Post by Tim Lahey
[...] require "#{ENV['TM_SUPPORT_PATH']}/lib/plist"
This loads a ruby extension bundled with TM. It is not unlikely that
this one is the one relying on the symbols, you can test that by
-r/path/to/TextMate.app/Contents/SharedSupport/Support/lib/plist
If it is the plist extension, then that should give the same errors
(where the previous line would have worked).
Allan Odgaard
2006-09-20 06:54:47 UTC
Permalink
Post by Tim Lahey
Hmmm, when I run this I get
:hello
for everything I try. So I'm wondering
what's happening. It certainly appears that
everything is okay with the ruby installation.
Now I'm really not sure what is wrong.
Might be that TextMate then does not pick up your new ruby, and
installing the new ruby broke the old one.

See http://macromates.com/wiki/Main/FAQ#commandnotfound for
troubleshooting and more info.
Tim Lahey
2006-09-20 16:08:42 UTC
Permalink
Based upon some troubleshooting

Using type -p ruby gives
/sw/bin/ruby
Arnaud BARRÉ
2006-11-07 15:38:59 UTC
Permalink
On 2006-09-19 03:01:05 -0400,
Post by c***@cyanite.org
Post by Darryl Morrell
Will I break things if I change the first line of the various ruby
scripts from "#!/usr/bin/env ruby -s" to "#!/usr/bin/ruby -s"?
No, I believe the env command is used to select the correct ruby command
at run-time (the first one in the PATH). So just providing the correct
path manually, will work as well.
I guess the problem is that the older env command doesn't allow arguments
for the commands following it, so it tries to start 'ruby -s' instead of
'ruby' with '-s' as argument.
-- Sune.
I use the latest TextMate version (1.5.4 (v1324)) in Panther (10.3.9)
with Ruby 1.8.5. I have Installed ruby via MacPorts and I made a
symbolic link from /opt/local/bin/ruby to /usr/bin/ruby (the old ruby
version has been moved to /usr/bin/ruby-1.6.8). This works great for my
TextMate use which is in fact to write some reports in LaTeX. Like
Darryl Morrell, I can't used the snippets command like bold, italic or
underline because the Panther env command don't accept command with
options (You can try to add some ' or " or ` but it doesn't work ). So
I modify the first line of
/Applications/TextMate.app/Contents/SharedSupport/Bundles/Latex.tmbundle/Support/bin/toggle_style.rb
to be now '#!/usr/bin/ruby -s'. I thinked I have to modify the
ENV['TM_SUPPORT_PATH'] command because I didn't used the /usr/bin/env
command but it wasn't necessary. The snippets works !

My short story is finished, but not my thought. Like I have just
mentioned, it is not necessary to use the /usr/bin/env command (at list
in the toggle_style.rb file), so how the ENV array is accessible? If I
generalised my thought to all the snippets which start by
'#!/usr/bin/env ruby -s', it is possible to replace this line by
'#!/usr/bin/ruby -s? This modification would make it possible to use
TextMate on Panther (with the last ruby version installed)

Maybe it is not important, because you are using Tiger and in some
times Leopard, but I find the idea interessant to have a text editor
which works on the different Mac OS version.

Regards,

Arnaud

Continue reading on narkive:
Loading...