Even though I'm #1498 I have to admit I'm quite a bundle newbie. One
of the issues that I recently came across was that the Shoulda Bundle
was not recognizing "context" and "should" blocks within test classes.
This is important, because the symbol navigation is extremely useful
for these.
At first I thought there was maybe a conflict or something else going
on, but when I moved these blocks into the root scope of the file they
worked. I realized that the shoulda language was built on
source.ruby.rails, which meant it wasn't being picked up inside
source.ruby.rails.meta.rails.unit_test or
source.ruby.rails.meta.rails.functional_test.
I solved this problem by adding:
{ include = 'source.ruby.rails.shoulda'; },
to those definitions within the Rails bundle.
However I feel dirty. First, because I'm hacking the Rails bundle to
make another bundle work. This seems like it will make upgrading
complicated since I don't imagine there is any kind of granularity
with language updates. Secondly, it feels wrong for the Rails bundle
to define an include of a language that is descended from the Rails
bundle itself. Apparently TextMate handles this properly because it
works fine, but it was a red flag for me. So I guess my question is
am I doing this wrong? What do the bundle gurus have to say on the
matter?
--
Gabe da Silveira
http://darwinweb.net
The thing that caused the problem was -- "Edit each line in selection."
I was able to edit the file without any problem by just doing a search and
replace. I don't know specifically how edit each line in selection works,
but I suspect that it involves quite a few Allocs, Like one for each line,
possibly quite a few more for each line. I was just putting out a warning
that you shouldn't edit the entire file with "Edit each line in selection".
It could have just been my computer, but I suspect that I was abusing this
wonderful feature into something Allan didn't imagine it to be used to do,
because as an expert in line management he would never have gone down the
path I did. I was just appending ",END_NOTE" to each line.
This happened on a Dual Xeon Core 2 Duo Mac Pro with 1GB of ram ( inherited
from our graphics guy who doesn't want to learn FCP).
In my html files I use root-relative paths such as:
<link rel="stylesheet" href="/css/screen.css" type="text/css" />
The Web Preview does not work even though the path is also relative to
the top level of the project, I have to use paths relative to the
current document.
<link rel="stylesheet" href="css/screen.css" type="text/css" />
Is there some way to get Web Preview to work with root-relative paths
for html development?
-Gianni
Hi. Some questions w.r.t. getting themes to work as I prefer:
Firstly, the manual says [1] that "markup.heading.2.html" can be used
in a language grammar. And then subsequently one may use that as a
selector in a Theme. I have tried to use the mentioned selector in a
theme made entirely from scratch, but whatever color I add for that
selector, nothing happens to the styling of the <h2> tags or anything.
Do I need to update the language grammar for HTML in order to get it to
work or what?
Secondly, Brilliance Black seems to be one of the richest themes
arround, with colors for many languages. It has a HTML section. And
below that it has a "markup" section. The markup selection has e.g.
"markup.heading" and "markup.bold". I assumed that "markup.bold" would
turn <b>text/</b> into bold face. But, no - doesn't happen. I have
misunderstood something?
Thirdly: Ideally, what I would like to see was a theme were the /text/
changed styling, more than the tags/code around the text. But TextMate
appears to only be able to have one color for text, namely that of the
"Foreground" color. Am I right? I hope not. Put on an edge, I would much
rather have a permant color for tags etc, but differing colors for text,
depending of the context. Can TextMate do this? Or may I just forget it
at once?
(I have used TextMate for a 2-3 years, but I only used the installed
themes. And there are many things with it that I have not taken
advantage of.)
[1] http://manual.macromates.com/en/language_grammars
Best regards,
Leif Halvard Silli,
Oslo
Greetings TextMate mailing list.
Forgive me if this is child's play, i searched the list archives
thoroughly before posting.
I am trying (for many hours now) to open a .nib file created in
Interface Builder using the "$DIALOG" command from a shell script. My
general objective is identical to the screencast Allan created in 2006
(http://tinyurl.com/df3m9r).
- Open a .nib file
- Wait for user to close nib or hit a ok button
- pass default parameters to the .nib
- capture user input from the .nib to be used later in the .sh file.
Currently i am trying to accomplish this with:
"$DIALOG" nib --load ~/Desktop/Test2.nib --center --model '{ classPath
= "foo"; }' --parameters '{}'
That usually opens the .nib window, when i close the window all i get
is an integer.
Then it usually stops working all together, no matter how many time i
try and execute the line of code (control - R) nothing happens, i have
tried what Allan suggests in the post "So either press ⌃D to
“close” stdin, or give -p '{}' as argument, and things should work
as expected." And i cant get it to work, if i trash TextMate prefs and
reinstall, it works for a bit more.
I am not yet as familiar with Ruby as i would like to be and i have an
immediate need to implement this within an existing bundle using
shell. The screencast made it look so nice and easy...
Best,
</matthew>
-------------------------------------------
Matthew Richmond, Principal/Designer
The Chopping Block, Inc.
481 Broadway, 3rd Floor, New York, NY 10013
p 212.463.7574
f 917.591.7584
http://choppingblock.comhttp://chopshopstore.com
-------------------------------------------
World Domination Through Graphic Design
-------------------------------------------
Hi,
last time I asked, this wasn't possible and I did not follow the latest
development. So here's my question again:
I have a custom html/php dialect. It contains of regions of code that
is either html markup or php code.
<php>...</php>
and
<htm>...</htm>
Inside a php region, you can use <htm> and inside a markup
region, you can use <php> which leads to recursive a structure
that is very helpful for programming (at least for me) but
harder to colorize, fold or autocomplete correctly.
More complex example (outmost default is html markup):
<html>
<head>
<php>
echo convert($title);
</php>
<style> ..... </style>
</head>
<php> init(); </php>
<body>
Result:
<php>
if($someflag)
<htm>
<table border="0">
<php>
foreach $row ($rows)
{
<htm><tr><td></htm>
echo $row;
<htm></td></tr></htm>
}
</php>
</table>
</htm>
</php>
</body>
</html>
Can I customize Textmate so its html and php modules identify my
regions?
/Andreas Pardeike
Hello,
I'm trying to enhance the Matlab bundle. Especially by trying to make
matlab and texmate to interact (shortcut to launch a script etc...).
And I must say I'm pretty bad with shell scripts and regular
expressions.
I've nevertheless managed to do that, and now I'm trying to recreate
matlab "cell mode" : matlab source files are scripts, and it is
possible to divide the script in "cells". When you are in the (awful)
matlab editor, you can run the current cell just with cmd+enter. This
is very useful. The problem is that the cell separator is just a line
like this :
%% Title of the new cell
...That's it, there is no ending marker for a cell : the current cell
ends where the new one starts ! What I've done now is creating a new
"cell" scope delimited by these lines, but as soon as one "%% ...."
line is used to mark the end of a scope, it can't be used to start the
following one.
Here's my descriptor.
contentName = 'meta.cell.matlab';
begin = '%%.*$\n';
end = '%%.*$\n';
captures = { 0 = { name = 'meta.celltitle.matlab'; }; };
patterns = (
# Here I include all the other scope descriptors, because they can
be contained in a cell !
)
For my solution to work, I then have to use two of these "%% ..."
lines, one to end the previous cell scope, and one to start the new
one. This means matlab files need to be modified to work, which is not
so good !
Do you have an idea on how to solve this problem ?
A linked problem (but less important) is that I can't get code folding
to work with cells : a start marker can't be the same as an end marker.
Thank you !
Hello,
When accessing various bundle features I get (LoadErrors).
This is on 10.3.9 using 1.5.7 (1436). On 10.4.9 same version, no errors.
First question, is this version 10.3.9 functional. I could not find anything in
the notes or on the site.
If this is not a 10.3 issue then these are the errors I have been receiving:
This is the Error I get issue php-help:
/Applications/TextMate.app/Contents/SharedSupport/Support/lib/web_preview.rb:1:in
`require': No such file to load -- erb (LoadError) from
/Applications/TextMate.app/Contents/SharedSupport/Support/lib/web_preview.rb:1
env: ruby -wKU: No such file or directory
I also the this error when issue html tidy:
env: ruby -wKU: No such file or directory
I get both the above from numerous commands.
I searched the thread, and based upon what I can find, I believe my environment
variables are correct.
One guess is an issue with this could be a result of an older Ruby install:
10.3.9 uses Ruby ver. 1.6.8; 10.4.9 uses 1.8.2.
One post referenced a ruby test:
feed these lines to Terminal do you see this output?
=====
$ /usr/bin/ruby -r erb -e 'p url_encode("a test")'
-e:1: undefined method `url_encode' for main:Object (NoMethodError)
$ /usr/bin/ruby -r cgi -e 'p CGI.escape("a test")'
"a+test"
my results:
$ /usr/bin/ruby -r erb -e 'p url_encode("a test")'
/usr/bin/ruby: No such file to load -- erb (LoadError)
But the suggestion confused me.
Suggestions?
Thank You,
dmp
Another example of something to avoid, aka things textMate really wasn't
designed for.
-- Open a large file (mine was > 7000 lines)
-- Select the entire file
-- Edit each line in selection
-- start typing.
This brought the computer to its knees.
My bad. Just thought y'all could have a laugh at my expense.
There are, of course, at least a dozen other ways to do what I started to
do: Filter through command, Command, Search and replace ( $ with
[replacement value]), etc
Tschuss,
Brad Tittle
Tech Support
I'm using git to keep different versions and branches of my projects
in repositories. Unfortunately, Project Plus does not properly
recognize files that git watches as well as the status of files that
it (correctly) recognizes as part of my git repository.
I am using `freely' managed projects, i. e. those you can create via
File > New Project and drag files into. I do not (want to) drag my
whole project folder onto the TextMate icon. If I do that, Project
Plus correctly labels the status of my files (part of repository or
not, modified or not modified). The problem is not just cosmetic, I've
discovered that files which Project Plus does not properly recognize
are not part of commits!
The solution is that you need to move the location of a file (e. g. by
reshuffling or so), then, apparently, Project Plus updates the
properties of all files.
Is this a known problem?
Max
Thanks, Allan, for both the replies.
> I?d argue that ?name? is meta data for the ?content? with the agreed
> upon convention that it uses a format like ??title?[.?type?]? ? a
> resource fork is just another piece of content meta data which is very
> fragile since it won?t survive a lot of the mechanisms used to
> transfer content (unlike the name), so there is little reason trying
> to split up the name into ?title? and ?type? and then store the ?type?
> in a new meta data field.
I agree completely about the resource fork. I'm afraid my comment was
confusing and it seemed like I longed for the days of resource forks
getting lost when you transferred files across platforms. (I'd be just
as happy to be rid of the extension.)
And I filed my first bug report with Apple.
> Make a column selection of the desired width (and with desired indent)
> then hit ?Q and TM will reflow the paragraph to be ?in a box?.
Doh! I knew that and had forgotten it. I feel like such a punk now.
(I'd still like to automate the process, but I want to try to do it
myself.)
Hello, how in TM when I have a few windows open can I get them into a
unified window with tabs? These are usually remote files opened over
ssh in Interarchy.
--
Scott * If you contact me off list replace talklists@ with scott@ *
I am starting to use cmd-Shift-R a lot more to run code through TM in
it's window. Very nice. For quick one off shell scripts I am finding
it invaluable.
I have a few issues. There are more times for me where I am working
in php and I want the output to be html'ized. I see a raw <br /> over
a rendered one. I end up putting in a lot of \n's and such to get
somewhat readable.
Is there any way to toggle the mode on how it deals with this?
Second is control-H, which I use a lot to get to docs in php, this is
suer handy, and I bet it uses webkit to do it's secret little deed.
However, One function may lead me to another, as there are links in
the window. But there is no back button. Is there any way to get
more standard browser buttons in this window? Or heck, I would be
happy to have it just use Safari.
The TM pop up seems to always be set to sort of work like
target="_blank" and spawn a new window, which clutters me up some, and
I end up with 20 windows hiding around. I would like control-h to
replace windows.
Thanks
--
Scott * If you contact me off list replace talklists@ with scott@ *
As the subject line begins: git from the Bundle menu works (as does
working from the CLI), but CTRL+SHIFT+G... gives me the following tool
tip pop-up:
/tmp/temp_testmate.AQcVtg:26:in `open': No such file or directory -
pages (Errno::ENOENT)
from /tmp/temp_testmate.AQcVtg:26:in `entries'
from /tmp/temp_testmate.AQcVtg:26
"AQcVtg" above is variable. Everything else remains the same.
The short version of my question is: what's wrong and how do I fix it?
TM has made me a lazy man, reliant upon keyboard shortcuts. Please
save me from using the pull-down menu.
john
#!/usr/bin/ruby -w
require "#{ENV['TM_SUPPORT_PATH']}/lib/setuplibs"
require 'svn_diff_directory'
require 'shellwords'
#require 'exit_codes'
def get_dirs()
dirs = []
if ENV['TM_SELECTED_FILES']
dirs = Shellwords.shellwords(ENV['TM_SELECTED_FILES']).delete_if
{ |file|
(! File.directory?(file)) or (! File.directory?(file+'/.svn'))
}
end
if dirs.empty? and ENV['TM_PROJECT_DIRECTORY']
dirs = [ENV['TM_PROJECT_DIRECTORY']].delete_if { |file|
(! File.directory?(file)) or (! File.directory?(file+'/.svn'))
}
end
if dirs.empty?
TextMate.exit_show_tool_tip "Neither the selected directories nor
the Project directory are versioned"
end
dirs
end
STDOUT.sync = true
dirs = get_dirs()
dirs.each() { |d|
Dir.chdir(d)
svn = ENV['TM_SVN']? ENV['TM_SVN']:'svn'
puts `#{svn} diff -r 1 .`
}
This script is supposed to generate a full svn diff for the currently
selected directory.
However, it generates no output.
I've set input to none, and output to new document
------------------------------------------------------
"Home is not where you are born, but where your heart finds peace" -
Tommy Nordgren, "The dying old crone"
tommy.nordgren(a)comhem.se
Hello all. I'm trying to figure out a way to write a command that will
take a selected block of soft-wrapped text, hard-wrap it to a given
length, and then indent a given number of spaces. I do a lot of
writing using Markdown, and I would like to find a way to make
bulleted lists more clearly marked as such while in plain text mode.
None of the current options under the TEXT menu do what I want. I
don't need the command to ask for the wrap length or the spaces to be
indented, I'm happy to adjust that within the command itself -- once I
get what I want, I won't fool with it for months if not years.
If someone could even point me in the right direction, I'd be happy to
try to hack at something on my own, but I honestly don't know where to
start.
john
--
John Laudun
laudun(a)louisiana.edu
http://johnlaudun.org/
Twitter/Facebook/Flickr: johnlaudun
Sometimes I would like to make a substitution/search or whatever only on a
part of the file, but textmate doens't bother too much if I select
something, neither there are options to do it.
I'm sure there is a way to do it, any help?
--
View this message in context: http://www.nabble.com/Substitute-only-here%21-tp22914227p22914227.html
Sent from the textmate users mailing list archive at Nabble.com.
In Bill's defense, I have long had this problem with the Finder. If I
create a file in Textmate but assign it no extension, a blank document
icon is assigned the file and the default application -- no matter how
hard you try to change it through the Finder -- to open the file is
always TextEdit.
As many people have pointed out, this is indeed a Finder problem, but
it makes it no less frustrating for users who do not wish to have
extensions on text files. (In the old days, wasn't that what the
resource fork was for? And wasn't the promise of the modern OSes to
dispense with the file extension system?)
john
Greetings to everyone,
How is it possible to compile a small program via short-cut. Until now
I've used apple-cmd+R (RUN/Compile via xCode) in my .m files
(objective-c). Via command usually I do something like this:
Angel:Fraction atma$ ls
Fraction.h Fraction.m main.m
Angel:Fraction atma$ gcc Fraction.m main.m -o Fraction -l objc
Angel:Fraction atma$ ./Fraction
5 / 10 = 0.5
0 / 0 = 0
Angel:Fraction atma$
Best regards & thanks in advance
Panagiotis (atma) Atmatzidis
email: atma(a)convalesco.org
URL: http://www.convalesco.org
--
The wise man said: "Never argue with an idiot. They bring you down to
their level and beat you with experience."
Guys,
Which screen recording software do you usually use to record TextMate
screen casts?
Best regards,
Mathieu
___________________________________________
Mathieu Godart
Skype: mathieu_godart
MSN: mathieu_godart(a)hotmail.com
ASIC Integration Manager
Coolsand Technologies
___________________________________________
I'm glad to see I'm not the only one trying to do this and
encountering this issue.
Unfortunately, your solution didn't work for me. I was able to install
the older port okay, and `port installed` shows that I have in fact
installed screen 4.0.3_1, and `which screen` shows that I'm running
the binary that I expect to be running, but still I get "mate: failed
to establish connection with TextMate."
Any ideas?
Thanks in advance,
Brian
Hi,
when I want open a file from within TM I mostly want to open a file in
the vicinity of the current file.
So is there a way to have the open file dialog open with the directory
of the current file displayed.
adi
Well I rewrote my little script in Ruby and have had mostly success,
but I need some help escaping things properly. Here's what I'm having
trouble with:
#!/usr/bin/env ruby
arg = STDIN.read
arg.chomp!
arg.gsub!('\\', '\\\')
arg.gsub!("\'", '\\\'')
arg.gsub!("\"","\\\"")
arg.gsub!('\`', '\\\`')
system("pointfree \""+arg+"\"")
This is intended to enclose text selected in TextMate in quotation
marks, and then escape all of the following characters within the the
quotes, and then use that as the argument to pointfree. What's wrong
with how I'm doing it?
Sorry for all of the questions,
Ian
I've just started using Textmate and know very little about it, I was
wondering why the svn-commit.tmp, Regular Expression (Oniguruma), Regular
Expression (Python), Release Notes and Strings File are in the languages
list since they seem to do nothing.
They appeared after installing the Subversion bundle along with a few other
languages.
Thank you for your help.
http://www.nabble.com/file/p22995446/Cropped.png
--
View this message in context: http://www.nabble.com/Unknown-items-in-the-languages-list-tp22995446p229954…
Sent from the textmate users mailing list archive at Nabble.com.
I get the following error running a ruby program in Textmate, but it works
fine running it from the command line. The program creates a lot of strings,
and slightly reducing this just slightly makes the error go away.
I get this in Textmate
...
2 DATE 11 Jan 2001
at top level in 3 TIME 15 at line 56
1 RIN 13
but this on the command line (which is correct)
...
2 DATE 11 Jan 2001
3 TIME 15:56:49
1 RIN 13
Oddly, if I "puts s.reverse" in textmate, I get the right output too
(reversed of course:). I also don't get the error if I print to a file,
rather than printing to the Textmate output window (and I'm only printing
out a very short segment of text from the program).
s = f.to_gedcom
puts s #output window copy gives the error (before
File.open).
File.open('/tmp/xx.txt','w') { |fd| fd.print s } #file
copy is correct
puts s #output window copy gives the error (and also
after File.open)
So is there a heap or stack size issue running ruby from textmate? Any other
guesses at what is happening? It does it under Ruby 1.8.6 and Ruby 1.9.1.
--
View this message in context: http://www.nabble.com/Is-there-a-limited-heap-or-stack-for-running-ruby-in-…
Sent from the textmate users mailing list archive at Nabble.com.
Hey everyone,
I'm experiencing very annoying trouble out here. My font rendering is kind
of blurry when it comes to dark backgrounds. Here's a screenshot using
Swyphs II color theme. My rendering is on the top of the screenshot,
author's is at the bottom, after the red line.
http://berkana18.com/screen.jpg
Font smoothing in system perferences is set to 'Automatic', and i'm on
Leopard, 23" ACD.
Any ideas, anyone?
Thanks in Advance.
Aleksandr.
--
View this message in context: http://www.nabble.com/Font-is-blurry-on-dark-background.-tp22957411p2295741…
Sent from the textmate users mailing list archive at Nabble.com.
Dear all,
I'm doing a very simple test every morning and sometimes more often:
run SVN update on my work dir (let's call that command A) and then
update the tag index of this source code (let's call that command B).
And I wanted to create a macro to do that.
The problem is that the macro launches the command A and launches
command B without waiting the end of command A. Do you have an idea on
how to automatize this (long to run) task with a macro. I could
probably do that with a command, but it would be cheating.
Thanks.
Best regards,
Mathieu
___________________________________________
Mathieu Godart
Skype: mathieu_godart
MSN: mathieu_godart(a)hotmail.com
ASIC Integration Manager
Coolsand Technologies
___________________________________________
Hi folks,
In case anyone else is interested, I've just put together a command
that aligns comments in a block - a trivially modified version of
Chris Poirer's 'align assignments' script.
It fixes this:
imagecopy($image, $frame,
($x=max($width-$this->topRightCap[kCapWidth], $this-
>topLeftCap[kCapWidth])), // Destination x
0, // Destination y
$x, // Source x
0, // Source y
min($this->topRightCap[kCapWidth], $width-$this-
>topLeftCap[kCapWidth]), // Source width
$this->topRightCap[kCapHeight]); // Source height
Ctrl-Option-Command-/, then:
imagecopy($image, $frame,
($x=max($width-$this->topRightCap[kCapWidth], $this-
>topLeftCap[kCapWidth])), // Destination x
0
, // Destination
y
$
x
, // Source
x
0
, // Source
y
min($this->topRightCap[kCapWidth], $width-$this-
>topLeftCap[kCapWidth]), // Source width
$this-
>
topRightCap
[kCapHeight]); // Source
height
More info & download at http://michael.tyson.id.au/2009/03/27/align-comments-in-textmate/
Cheers,
Michael
--
Michael Tyson | michael.tyson.id.au
m: (+61) 0407 754 124
e: michael(a)tyson.id.au
aim: mikerusselltyson
twitter: MichaelTyson
Hello,
Is it possible do always highlight brackets/parentheses of the code block,
where my caret currently is?
I'd like to have the ability to always see what block I'm at, not only when
moving caret near the closing bracket. And is it possible to change the
color of the highlight? I may not be a square around that bracket, the
bracket itself can go bold and different color.
Does anybody know, how to do that, if possible?
Thanks.
--
View this message in context: http://www.nabble.com/Always-highlight-brackets-parentheses-of-the-code-blo…
Sent from the textmate users mailing list archive at Nabble.com.
Hi TextMate users!
I'm using LaTeX with TextMate. Is it possible to get the Acrobat Reader in the "View in:"-selection in LaTeX Preferences? Where can I set this?
Thanks and regards!
I'm experiencing slowness when I use the number keys 1-9 (not 0). There's a
full second's delay from pressing a number to having it appear in the file
that I'm editing. Interestingly the problem also exists when changing using
Apple+Number keyboard shortcut to change between open file tabs. The problem
only occurs in projects.
Is anyone else having this problem? Any suggestions on a solution would be
greatly appreciated.
I'm using OS X 10.4.11 and I have the ProjectPlus plug-in installed.
--
View this message in context: http://www.nabble.com/Number-keys-slow-tp22668585p22668585.html
Sent from the textmate users mailing list archive at Nabble.com.
I had earlier asked a question about how to have the textmate editor
highlight the footnotes in my latex document. Link:
http://www.nabble.com/Highlighting-in-Textmate---Latex-to20379168.html#a203…
I had two very good responses to that question about how to find the scope
and how to modify the preferences. For footnotes, the scope was
meta.footnote.latex
Now I am using a package called "changes" in latex, which defines commands
like \added, \deleted and so on for tracking changes. I want to highlight
anything that appears in the braces in \added{}. Using the method suggested
in the above post I found the scope as meta.group.braces.tex. But this scope
is common to many other pair of braces (for example, subscripts,
superscripts, \vspace{} etc.) and it highlights all those too. How can I
have the editor just highlight something that appears between \added{}.
Thanks very much.
--
View this message in context: http://www.nabble.com/Custom-highlighting-in-latex-tp22727134p22727134.html
Sent from the textmate users mailing list archive at Nabble.com.
How can I escape certain chars in a selection in TM? If this is not
built in, can someone help me make a macro or equivalent to do so?
Example:
echo "<a href="untitled.html" id="name" class="name"
target="_self">test</a>";
I would select the entire line, it would be smart enough to know the
language from the string.
echo "<a href=\"untitled.html\" id=\"name\" class=\"name\" target=
\"_self\">test</a>";
I have a feeling there is probably something built in that can help
me, but I am just not finding it.
--
Scott * If you contact me off list replace talklists@ with scott@ *
It would be useful with a command "Diff selected directory with
Version ...",
that would generate a diff for ALL versioned files in selected
directory.
-----------------------------------
See the amazing new SF reel: Invasion of the man eating cucumbers from
outer space.
On congratulations for a fantastic parody, the producer replies :
"What parody?"
Tommy Nordgren
tommy.nordgren(a)comhem.se
I'm newly coming back to the Mac after a long hiatus (late 1980's as a
developer); been Windows in the interim.
I still have to work periodically in Windows boxes and am somewhat forlorn
at the layout of the navigation keys on the Mac (as in most laptops). This
is where VI shines; the navigation can be accomplished in the "center" of
the keyboard where key layouts are consistent. David Wooten maps a single
key (http://lists.macromates.com/textmate/2006-January/007683.html) and Kirk
Fitzpatrick was attempting a plugin (
http://lists.macromates.com/textmate-plugins/2007-January/000022.html).
Anyone figure out anything like what VI has or have any ideas? I'm
considering building something that intercepts keystrokes right out of the
operating system so that TextMate has to know very little.
Thanks in advance,
--
Scott Smith - Old Fart Developer
With privilege comes responsibility,
with responsibility comes accountability,
with accountability comes honesty,
with honesty comes faithfulness.
I started a project I call "ropen", which is like OS X's "open" or
TextMate's "mate" commands, but works remotely by automatically
mounting the remote filesystem locally using MacFuse's sshfs:
http://github.com/tlrobinson/ropen/tree/master
It works quite well, except when you try to open a large directory
tree in TextMate. It seems like TextMate is trying to walk the entire
tree immediately when it's opened. Doing this over the network is very
slow and ends up hanging TextMate for moderately sized directory trees.
Is there any possibility of changing the behavior to lazily do
whatever initialization TextMate needs to do when opening directories?
Thanks,
Tom
I have seen others do this, I can not find any docs on it.
In php, I have seen someone type in array_keys() and somehow, they are
able, in that completion, or at a later time, get it to insert the
template arguments: array_keys ( array $input [, mixed $search_value
[, bool $strict= false]] )
--
Scott * If you contact me off list replace talklists@ with scott@ *
Howdy!
I would like to use TextMate for C/C++, but I have no idea how to set up. So what do I have to do to get this simple code working?
#include <stdio.h>
int main()
{
prinft("hello world");
return 0;
}
Thanks a lot!
This qualifies as "Well, if you don't like kicking yourself in the nose,
why don't you stop doing it?" kind of suggestion.
When I open a network drive location and double click on the folder, it
opens.
Yes, if I just click on it and then click on the sub folder I really want it
works exactly as it is supposed to.
This isn't a bug. This is just me telling the world that I am incapable of
instantly changing the way I use my flippin mouse. The real answer lies in
doing a bunch of other things correctly, I just haven't started doing them
that way yet.
The only bug here is that because i double clicked on a large directory,
textMate basically locks up (because it is processing a lot of files over a
network connection and even though all CS guys are constantly trying to
avoid N^2, it keeps coming back to bite us!).
Anyone ever try to open a large spreadsheet (say anything over 6,000 rows)
in Numbers. NOT A FUN thing.
--
Brad Tittle
Tech Support
Hello All,
I believe I have found a bug in the syntax highlighting for shell
scripts. When I have a comment in a case statement and the comment
does not get highlighted correctly. Here is the text for my case
statement:
#first figure out what platform you are in, based on the uname -rs
KERNELVERSION=`uname -rs`
case $KERNELVERSION in
#linux returns "Linux kernelversionnumber"
Linux* )
OSTYPE="linux";;
#freeBSD returns "freeBSD releaseversion"
*BSD* )
OSTYPE="bsd";;
#osX returns "Darwin kernelversionnumber"
Darwin* )
OSTYPE="macos";;
#everything else
* )
OSTYPE="unknown";;
esac
also here is a link to a picture of what I am seeing on my screen: http://farm4.static.flickr.com/3575/3410707546_d7a2a67e49_o.png
Im not sure if this is even helpful but pastebins highlighting seems
to do the same as textmate but quickhighlighter.com seems to get it
correctly(what I assume is correct).
Thanks for your help.
--Colin
When I edit a Template it stops working even when I edit just one tiny letter
in an out-commented text.
I do the following:
in the 'bundle editor' I expand the 'Project' Template and then I select the
'Project.as'. Here I placed the opening curly braces to be at the same line
as the function (and not at the next line).
public function ${TM_NEW_FILE_BASENAME}() {
When I close the window and try to make a new project from template nothing
happens.
Even when I revert my changes it won't work anymore, I have to reinstall the
whole bundle!
As said I also tried just to change a tiny letter in outcommented section of
_create_as3_project.sh with the same result.
What is the proper way of editing a Template?
--
View this message in context: http://www.nabble.com/How-to-edit-Actionscript3-Templates--tp22677253p22677…
Sent from the textmate users mailing list archive at Nabble.com.
I use the Makefile bundle on my desktop and never had any issues so I when I
put it on my laptop I was a little puzzled when running Build produced this
output:
env: ruby\r\rrequire: No such file or directory
Ruby is most definitely in TM's path, and checking the path from within TM
on both machines shows that they are exactly the same. Both machines are
running Leopard with the same version of ruby, same gems, and same version
of TM installed.
Any assistance is greatly appreciated.
Thanks,
Brian
Hello, I just started using command-R to refresh in running browsers.
I find it only refreshes the front most browser window. Is this normal?
I seem to be fighting this behavior, though command-R is so handy I
want to use it. Perhaps it could be modified to work better.
If I have a few windows, and a few tabs, move to TM, command-R, it
will switch to Safari in this case, and refresh whatever is the front
most window and tab within that window. I now have to remember to
bring the window forward that has the result of the code I am working
on to the foreground.
I think for me, a better behavior would be for command-R to spawn a
new browser window, with the code ran in that window. I can then
close the window, and be back in TM. This way, my window is always
going to be the one used.
Has anyone else found this mildly annoying and looked for a solution?
I can always go back to the command-tab to the window I want method,
and press reload in the browser.
I have tried the command-shift-R method, but I have a feeling that
since I am working on remote files through a ftp/ssh app, it is not
going to work. It also does not interpret html, and shows me the raw
html code, so that method seems more designed for cli type scripts, or
code that does not end up outputting to a browser.
Thanks for any workflow suggestions
--
Scott * If you contact me off list replace talklists@ with scott@ *
Hello, I found a .tmMacro file someone put up, it will allow me to
remove trailing spaces and tabs on save. Works nice, for one flaw.
If I have any text selected, that selected text is replaces with what
seems to be the contents of the entire file.
I can not figure out how to even edit the .tmMacto once installed. I
can put the cursor in the bundle editor area, but it will not allow
any chances.
I can not open the .tmMacro file in TM, so I could use the shell, but
that seems strange, and it is a plist, and not entirely sure what to
edit.
The Macro has two commands
executeCommandWithOptions
{
beforeRunningCommand = nop;
command = "perl -pe 's/[\\t ]+$//g'";
input = document;
output = replaceSelectedText;
}
executeCommandWithOptions
{
beforeRunningCommand = saveActiveFile;
input = none;
output = discard;
}
* I can sort of hack this out on my own by making a empty command,
then recording a macro to and hooking those two together. The above
seems cleaner though.
Any ideas what I should edit? The perl seems fine, a direct copy from
the TM built in to remove spaces and tabs, maybe the output =
replaceSelectedText; needs changing?
--
Scott * If you contact me off list replace talklists@ with scott@ *
Hi all,
I am new to textmate and Java/Python programming. When I run my code
with the textmate run command, there seems to be a problem with the
order of output in html. This problem seems not to be bundle specific
(both Java and Python bundle show the same problem) so I guess it is
in the underlying executor script.
The bundles and support dir are fresh SVN checkouts.
Example code: guess.py
import random
secret = random.randint(1, 99)
guess = 0
i = 0
while guess != secret:
guess = input("Make a guess (0 to quit): ")
if guess == 0:
print "Program quit"
break
elif guess > secret:
print "to big"
elif guess < secret:
print "to small"
i = i + 1
else:
print "Congratulations, you guessed right after",i ,"tries."
Example output: order is: prompt -> program output -> input
Make a guess (0 to quit): to small
1
Make a guess (0 to quit): to small
2
Make a guess (0 to quit): to small
3
Make a guess (0 to quit): to small
4
Make a guess (0 to quit):
Output order should be: prompt -> input -> program output
I'd like to use textmate in my cs cources starting soon and it would
be great if the html output had the right order, so I can hand it out
to the teacher as a proof for my working code. At the moment this
would be rather confusing and lead to some discussions I guess.
This really just happened to me. Really. I know I produced some April Fools
jokes yesterday, but that was yesterday. This is real.
I created this Ruby script in TextMate:
s = "wackamole"
puts s
I ran it, and the RubyMate output window displayed:
woe
Weird, eh? And it is part of a longer story; the string "wag wag" was being
displayed as "w w", and the string "ruff ruff" was being displayed as empty.
(Never mind why I was testing those strings.)
I quit TextMate, restarted my computer, and everything is back to normal.
But would anyone like to suggest a cause for what happened? Cosmic rays?
Belated April Fools day easter-egg-type joke?? The conficker virus??? Has
anyone else ever seen anything like this? m.
PS The problem was presumably with TextMate, not with ruby, because using
the Terminal to run the same script (as a saved text file) using the "ruby"
command worked just fine.
--
matt neuburg, phd = matt(a)tidbits.com, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
http://www.tidbits.com/matt/default.html#applescriptthings
Hello, I find that TM has too many keyboard shortcuts for my brain to
be able to retain and be useful to me. I have developed a habit that
I use in all apps, which is to use apple help, command-Shift-? will
bring up the help menu in the app. I can type a few words, and it
will show me the menu item I need. Return and it is executed. Or I
can traverse the real menu structure.
I use this in all apps, it is handy to me.
TM apparently crashes a lot when I do this.
I am now looking to use the "Select Bundle Item", but it is too
aggressive about what it finds. Enter in the single letter "E" and it
finds all bundle items that contain a singe E. I am looking to limit
it to contains characters of at least three characters for a match.
In the help search method, if I type "br" it brings up 6 items to pick
from. In the "Select Bundle Item" it beings up about 25 or so.
Any suggestions? Over time, I am sure this is going to force me to
learn more of these, but the apple help method was gread for those one
time uses where you will not use the command again for a long time.
It also goes beyond the bundle items, and I could toggle freehand edit
mode, for example, something I rarely do, and just do not want to
bother committing to memory.
--
Scott * If you contact me off list replace talklists@ with scott@ *
Hello,
I'm working on a "matlab console" bundle, à la "R console bundle". The
goal is to emulate a matlab console in a textmate window, which is
much more practical than the terminal to edit long commands. This is
so far working quite well, running matlab in the background and
sending/receiving messages via text files.
However, when I have a matlab script opened in a textmate window, I
want to be able to execute it in the textmate window where the matlab
console lies. I thought of doing that with applescript, but the
dictionary of textmate seems pretty poor, there is no way of handling
tabs for example.
So what I want to be able to do is a run a command from a window that
write its results in a different textmate window or tab (which has a
specific name, something like "Console.Mcon"). Is this possible ? and
how ?
Thanks
Pierre