Hi!
I had the same problem as described in a post from Sebastian on
2007-11-11 (http://thread.gmane.org/gmane.editors.textmate.general/
23160).
Here is my error output:
Running bibtex on Exjobb (ny).tex
Traceback (most recent call last): File "/Users/peeter/Peeterprogram/
TextMate.app/Contents/SharedSupport/Bundles/Latex.tmbundle/Support/bin/
texMate.py", line 457, in texStatus, isFatal, numErrs, numWarns =
run_bibtex(texfile=fileName) File "/Users/peeter/Peeterprogram/
TextMate.app/Contents/SharedSupport/Bundles/Latex.tmbundle/Support/bin/
texMate.py", line 71, in run_bibtex return stat,fatal,err,warn
UnboundLocalError: local variable 'stat' referenced before assignment
It seems that it had to do with the parentheses in my filename messing
up the regexes.
My solution was to change lines 71 and 72 in Textmate.app/Contents/
SharedSupport/Bundles/Latex.tmbundle/Support/bin/texMate.py as follows:
# auxfiles = [f for f in os.listdir('.') if re.search('.aux
$',f) > 0]
# auxfiles = [f for f in auxfiles if re.match(r'('+ basename +
r'\.aux|bu\d+\.aux)',f)]
auxfiles = [f for f in os.listdir('.') if re.search('.aux$',f)
> 0 and (f.startswith(basename) or re.match(r'bu\d+\.aux', f))]
This works, at least for me.
Or have I messed something else up in the process?
/Peeter
I have just discovered TextMate, and am so far very happy with it,
but I think I just hit a glitch...
I am trying to edit a SQL load file that is about 5M, which shouldn't
be a problem. However, some of the lines are very long, as a complete
website contents is in a single line. I have no idea how many
characters are in this line, but I suspect about 2M worth.
Anyway, TextMate hangs while trying to work with this file. I can't
do much at all. Even a simple act of scrolling hangs. TextEdit does a
reasonably good job with the file though...
Actually, I don't think it is hanging, as it eventually responds
(about 30 seconds later), but it is so slow that it is completely
unusable. Is this a known problem? For me, it is weird files like
this that we need an editor like TextMate to be able to easily handle.
Thanks...
Jim Leask
Hi!
I'm just working on some Tex-Document which uses several dialogues
which I want to enclose in "< "> (the result are those <<
>>-enclosures in the document). Would be cool if that could be added
to the language grammar.
Thanks in advance
Niels
Hey everyone,
Recent TextMate convert here and boy do I love it - trial expiring
within the week, so will be a paying customer from then on. ;)
Have a question, though, with regards to sorting in the Project Drawer.
Is it possible to have entries sorted by type, and only then by
name? I'd like to keep directories together. (At the top,
preferably. ;)
I found the following reference (and its references) in the mailing
list archives:
http://comox.textdrive.com/pipermail/textmate/2004-December/001971.html
This message seems to imply the sorting is hard-coded.
Alexander Deruwe
Hi Allan and friends,
I have a source tree structure like this:
www/
site/
index.tcl, .adp
one.tcl, .adp
edit.tcl, .adp
item/
index.tcl, .adp
one.tcl, .adp
edit.tcl, .adp
The fact that files are named the same, but in different directories:
- Confuses both the Cmd-Opt-Up "Go to Header/Source" feature, which
will gladly find www/item/one.adp when I'm editing www/site/one.tcl. It
would be good if it would prefer the file in the current directory when
one exists. Otherwise, it's a great feature.
- Similarly, when using Cmd-T "Go to file", which I use almost
exclusively to open up new files now, it would be great if I could
write "itemonetcl" to get item/one.tcl, as opposed to site/one.tcl.
Currently, it doesn't take the path into account at all.
I can see some downsides to changing current behavior, too,
particularly with the Go to file feature.
But let me know what you think.
/Lars
The current Documentation for Word / Selection and Documentation for
Selector in the Objective-C bundle doesn't find a many of the classes
and selectors for lots of things now in Leopard (CAAnimation, for
example) or in the iPhone SDK.
Having looked at the existing implementations of these commands I
decided it would be easier to replace them rather than hack what was
there already. My implementation of these commands uses an Apple
supplied tool (docsetutil) to search for the word, etc. in the docsets
so don't need any private index lists to find words quickly. This has
the big advantage that the index is always up to date and covers every
framework. The code is a lot simpler as well.
The only downside I can see is this may only work with Leopard - I
don't know and don't have any easy way of finding if it works with
Tiger. I didn't work through all the ramifications of the original
selector identification code so it is possible my version has some
holes - I have tried it with lots of examples and it seems to work,
but if any problem cases are discovered I will be pleased to fix them.
To install this version copy the enclosed ruby file to /Applications/
TextMate.app/Contents/SharedSupport/Support/lib/ directory and edit
the two commands (or make two new commands) as follows:
Documentation for Word:
#!/usr/bin/env ruby
require ENV['TM_SUPPORT_PATH'] + '/lib/docset_query'
documentation_for_word
with input, output and scope selector as per the original. Will show
a list of candidates if more than one and also prefix them with the
language if more than one is present (hint try selecting init outside
of a [ ].
Documentation for Selector:
#!/usr/bin/env ruby
require ENV['TM_SUPPORT_PATH'] + '/lib/docset_query'
documentation_for_selector
with input set to "Entire Document", output "Show as Tool Tip" and
scope selector as per the original.
If there is interest in absorbing this work into the official
distribution that is fine by me and I hope I haven't committed any
sins in where the helper file is stored.
Dave.
As I set up Reformat Comment commands for the languages I use most
frequently (LaTeX and R), it occurred to me that maybe there's a way
to make a single call to rubywrap more generic, so that we don't need
a command per bundle. This is the result:
#!/usr/bin/env ruby
$LOAD_PATH << "#{ENV["TM_SUPPORT_PATH"]}/lib"
require "escape"
scope = ENV["TM_SCOPE"]
case scope
when /comment\.(block|line)\.number-sign\./
cstring = "# "
when /comment\.(block|line)\.percentage\./
cstring = "% "
end
flags = ""
flags += " -p \"#{cstring}\" "
flags += " --retabify" if ENV["TM_SOFT_TABS"] == "NO"
text =`echo -n "#{e_as(STDIN.read).gsub(/[$`]/, '\\\\\0')}" | ruby "#
{ENV["TM_SUPPORT_PATH"]}/bin/rubywrap.rb" #{flags}`
print e_sn(text)
The parameters are the same as the current command, with the
exception of scope, which I set to "comment.line, comment.block".
I also added a gsub to the command because it was eating latex math
and R symbols ($). There's probably a better solution to that. This
seems to work for me, and should be extended easily by adding lines
to the case statement for other languages. One advantage is that by
specifying the comment character based on the scope, it ought to work
for anything; it catches comments for both bash and perl, for
instance, without any extra effort. I think it's kind of cool.
-Alan
Hi all, I've tried searching for this, and my google-fu is weak.
Does anyone know how I would be able to change the indentation behavior for
just parenthesis in Javascript?
Basically, our code convention is so that when you have multiple arguments
on new lines (for instance, passing an anonymous function as a closure), the
closing parenthesis aligns to whatever the current tabbing level is.
Currently, the curly brackets do this now, and would like to mimic the
behavior, but can't make heads or tails of doing it with the current
indentation patterns.
Here's what I would like:
var xyz = (
\t
)
Here's how it actually currently is:
var xyz = (
\t)
Here are my current indenation rules, could anyone help me get what I'm
looking for, or have I been looking in the wrong place?
{ decreaseIndentPattern =
'^(.*\*/)?\s*(\}|\))([^{]*\{)?([;,]?\s*|\.[^{]*|\s*\)[;\s]*)$';
increaseIndentPattern = '^.*(\{[^}"'']*|\([^)"'']*)$';
}
Thanks in advance all!
--
View this message in context: http://www.nabble.com/Javascript-indentation-tp16985640p16985640.html
Sent from the textmate users mailing list archive at Nabble.com.