This isn't really directly related to TextMate at all, but... :)
I've been doing some automation work to help make me all the more efficient
in various ways. That's generally involving writing up scripts glued to
various places-- and I've recently sort of wanted something like tm_dialog
to integrate with them, entirely outside of TextMate. I mean, I use
tm_dialog with a couple custom bundles for certain purposes but I don't
really "live" in TextMate so much.
Anyone know if there's a way to poke tm_dialog into just doing its thing
/outside/ of TextMate? Or, something else out there which fulfills a similar
use? I saw CocoaDialogs, but what I loved about tm_dialog was that it could
run custom nib's.
Anyhoo. Sorry for the OT post. =)
--Stephen
I caught this on a thread in reddit I think. Watch the animated image:
http://code-and-hacks.blogspot.com/2009/06/stealing-from-padre-for-vim.html
Something like this would be very cool. I know I can do it with find
and replace, but having a command that was aware of the scope you are
in, and only altering the variables you want within that scope, and
narrowed to that specific variable would be super nice.
Not something I would use all the time, but I have a habit of slamming
out some pretty off the top of my head code. To be able to go back,
and give nice logical well thought names, and have those changes not
break my code, would be a great addition.
Anyone cone close to this in TextMate today?
--
Scott * If you contact me off list replace talklists@ with scott@ *
On Jun 22, 2009, at 8:00 AM, textmate-request(a)lists.macromates.com
wrote:
> Personally I'd be in favor of simply using rhino as the js script
> runner. Just need to include it in your bundle of the shared TM
> support folder.
>
> ?Thomas Aylott / subtleGradient
Hi Thomas,
As a JavaScript devotee, I'd love to do this. I've installed Rhino and
got it running in
~/Library/Java/Extensions
per instructions found at
http://peter.michaux.ca/articles/installing-rhino-on-os-x
When I open ~/Library/Application Support/TextMate, however, I just
see the Bundles, Plugins, Pristine Copy, and Themes folders. Do I just
copy Rhino's js.jar file to a new "Extensions" directory?
Presumably I would also need to start a command with a shebang line to
tell TextMate I'm using a particular scripting language, like
#!/usr/bin/env perl
What would be the equivalent path for Rhino's JavaScript?
Thanks in advance for any guidance!
jon
/RR (http://responserequested.com)
______________________________
Still Water--what networks need to thrive.
http://newmedia.umaine.edu/stillwater/
Wherever I can I have switched to git. When switching branches (a
common thing with git), git replaces files 'in place'.
That has some side effects with TM:
- when I switch branches (say from the stable to the development
branch) and forget to close the project window first, TM happily
overwrites the project file. Thus I loose all the changes (eg new
classes added etc). Ideally TM should recognize that the project file
changed and reload it.
- Transitory information: TM seems to store transitory information
(window position or some such) in the project file, thus dirtying my
project. I'd prefer that TM would write that kind of info into a
separate file, so I can chose to track it or not.
How about some TM2 teasers?
Thanks
Gerd
The diff folding of blocks also folds away the first three lines of
the next block, for instance:
diff --git a/app/models/questionnaire.rb b/app/models/questionnaire.rb
index 14284d6..b9ee4f5 100644
--- a/app/models/questionnaire.rb
is also folded away if I fold the block before it.
It seems to me that something is going wrong here.
This diff was generated using 'git diff', but can also be created
using 'diff -u'.
Hope you can fix this.
Cheers,
Samuel
Hi All,
I’ve started using the Create HTML from Document command in the
TextMate bundle, but for small snippets the code it produces is
slightly weighty. I came across a post by Scott Stevenson:
http://theocacao.com/document.page/517
in which he mentioned modifying the command to only add class names
for the scopes that the current theme had styling for, eliminating
most of the unused class names. Unfortunately he hasn’t published his
modifications. How to do this is beyond me, so I wonder if anyone who
has made improvements to this command (to remove unused class names
and/or CSS rules) would care to share. Alternatively if there’s a
tool that would do this please let me know (I couldn’t see suitable
options in HTML Tidy’s config).
Thanks in advance
peace - oli
I have found that "Edit in TextMate" no longer works on 10.4.11 (not
sure about Leopard) with any build after 1498 -- it fails silently
although the key press gets picked up by Key Codes. Re-installing 1498
gets it working again. Anyone else found this?
Hi,
The DokuWiki bundle does highlight <del>foo</del> markups only if they
are at the beginning of a line or have max 2 spaces. I looked into the
bundle, but I can't find why that happens.
Wolfgang
Hello,
Does Textmate's code folding have limitations when a method declaration
is split across lines? Sometimes I have long parameter lists which
necessitate this style:
class MyClass():
def __init__(self,
var1=var1Default,
var2=var2Default,
var3=var3Default,
var4=var4Default,
var5=var5Default,
var6=var6Default,
var7=var7Default,
var8=var8Default):
pass
def method1(self):
pass
def method2(self):
pass
def method3(self):
pass
When I format the __init__() method above across line boundaries, I lose
code folding. Bummer. I know. I could use a work-around idea if this is
the way it is. :)
Cheers!
AZ
Any chance of a intel only bin of textmate? I've noticed a hell of a
difference in pretty much every app bar textmate in snow leopard.
If you could spit out an intel binary that would be great!
Many thanks
-Lawrence
Hi, there
I was doing my test programming in objective-c and i was doing some UI
work with interface builder, but whatever I did in the header file I
added, interface uilder does not recognize it. unless i open everything
in Xcode, and did the same thing, interface builder recognized it
immediately.
Is there anything I can do to get around that?
Cheers
Allen
Will having multiple preference files scoped to the same scope cause
any conflicts?
I've written a custom print command, and want each supported scope to
have a shell Variable,
specifying how to syntax-highlight the file.
-------------------------------------------
Engineers supporting greenpeace: Comparable to Afroamericans who wants
to join the Ku Klux Klan
----------------------------------------
Tommy Nordgren
tommy.nordgren(a)comhem.se
During my "gentle" introduction to Terminal in OSX, I was introduced to perl.
perl #!ed my brain so hard %-|, that without much introduction, I chose to
learn python because I thought it gave so much better ! for the $ (bang for
the buck) without help from hard core programmers. =^D
Now am trying to learn textmate and got stumbled on Ruby.
Sure it sounds a lot of fun to learn a new language.
But is there a way to use UI in python scripts within TM?
May be my question is a bit precocious because I just found a textmate
podcast series on itunes that has 2 podcasts on dialog2 in TM.
Oliver Taylor-2 wrote:
>
> On Jun 1, 2009, at 5:12 PM, MDX-LE wrote:
>
>> Could someone tell me how to install dialog2 available at
>> http://macromates.com/svn/Bundles/branches/WIP/Tools/Dialog2/
>> Dialog2 @
>> macromates.com
>
> I believe Dialog has been renamed UI and is already included in
> TextMate at TextMate.app/Contents/SharedSupport/Support/lib/ui.rb
>
> You can call UI with something like: require ENV['TM_SUPPORT_PATH'] +
> '/lib/ui.rb'
>
>
> _______________________________________________
> textmate mailing list
> textmate(a)lists.macromates.com
> http://lists.macromates.com/listinfo/textmate
>
>
--
View this message in context: http://www.nabble.com/newbie-question..-How-compile-source-code-for-dialog2…
Sent from the textmate users mailing list archive at Nabble.com.
As of late (last month or so), I keep getting this error message every
time I try to run basic bundle operations that use ruby under the
hood. A typical example is "comment out" (apple-slash) (in C++ or
Latex bundle) that replaces the corresponding text section with the
error message.
I read the posts on this problem that date back to 2006 and could not
solve the problem. I am running the latest version of Textmare
(Version 1.5.8 (1498)) and a very recent version of ruby.
'which ruby' followed by Ctrl-r yields:
/usr/local/bin/ruby
ls -lh /usr/local/bin/ruby gives me:
-rwxr-xr-x 1 root wheel 13K Jun 4 15:04 /usr/local/bin/ruby
and /usr/local/bin/ruby -v produces:
ruby 1.9.1p129 (2009-05-12 revision 23412) [i386-darwin9.7.0]
I tried everything I could think of, including reinstalling Textmate,
reinstalling ruby, and setting explicitely the TM_RUBY shell variable
but to no avail.
Thanks in advance for any insight into the cause of this problem.
Xavier
This hit the front page of reddit today, thought it would be good to
let the list know about it. I found it to be a well written piece and
keeps me happy moving forward.
http://blog.macromates.com/2009/working-on-it/
There are a good deal of comments on the blog as well as reddit about
the no pay for version 2 issue. I am more or less in the camp of
"charge for version 2", especially if the lack of a charge is in any
way adding to a lack of motivation to get 2 out the door.
That being said, I do not believe it would be wise to go against a
statement made in the past that version 2 would be a free upgrade.
Remember, there is nothing stopping any of us from just buying version
2 outright when it comes out if that is the direction you want to go in.
This may skew stats a little on new users, versus upgrade users which
could be undesirable. My suggestion, when this day comes, simply make
version two require a checkout process, to get a new serial, and
charge $0.00 to whatever you feel it is worth.
Personally, if version 2 solves a good deal of my needs that are
lacking in version 1, I will be donating one way or another, $100.00
for my copy. I pay my mortgage, dinners, clothes, and the rest of my
life as a result of TextMate, $100.00 is a small price to pay for
making it easier for me to make a living.
Thank you for coming forward with a new plan to keep users updated on
the progress. It has been long overdue, though users are generally
forgiving. I also feel, the most vocal, that make a lot of noise, are
probably a very small percentage of the true count of the user base.
Yay for 2.0 news! Very nice to know at least one person is using 2.0
on a daily basis as well.
Have a nice end of the weekend to you all.
--
Scott * If you contact me off list replace talklists@ with scott@ *
Hi folks. I'm starting to get into javascript, and am having problems
with the Reformat Document (Beautify) command.
I want soft tabs of 2 spaces. I read in a .js file, with the 2 space
indentation, and call the Reformat Document. It alas, does not use
the current 2 space soft tabs, but defaults to 4.
Yet if I edit the file, the auto indent correctly uses the 2 space
indent.
So clearly the tab setting I use (bottom of textmate, tabs menu) is
used by the auto-indent, but apparently not for Reformat Document.
What am I doing wrong?! Is there a textmate/javascript variable or
preference that needs to be set? Should the tabs menu control both
the auto-indent and Reformat?
-- Owen
Hi everyone,
I just upgraded to SnowLeopard GM1 and cmd+left/right no longer seem
to go to the beginning/end of lines. I'm not sure if this is Apple's
fault or TextMate's fault, but other apps that use standard Cocoa
editing controls in GM1 (i.e. TextEdit) seem to work fine with
cmd+left/right. Is anyone else experiencing this?
I know you can use ctrl+a/e to get to the beginning and end of lines,
but I prefer to use the cursor keys.
Thanks,
Ben
I know it's silly but I'd rather keep my serial number that shows I've
been using TM from the early beginning... So I'd prefer a donation
option or some sort of custom upgrade path than buying a brand new
license...
I said it was silly!
On Jun 18, 2009, at 8:00 AM, textmate-request(a)lists.macromates.com
wrote:
> As I have mentioned, there will be nothing preventing any if us from
> ignoring the free upgrade option and just buying version 2 outright.
> No donation button needed.
Hi there!
Is there any way in TextMate to navigate back to the previous cursor
position? In VIM I use "CTRL-O" to go back and "TAB" to go forward in
command mode.
Thanks a lot in advance!
Regards,
Alex
--
View this message in context: http://www.nabble.com/Is-it-possible-to-go-back--tp24074243p24074243.html
Sent from the textmate users mailing list archive at Nabble.com.
Dear All,
Many years ago, in a state of innocence, I hard-coded my LaTeX quotation marks.
> Thus I have text that `looks like this'.
I now find that it would have been MUCH better (if not essential) to have done:
> Thus I have text that \enquote{looks like this}
I can't do a search and replace, because there is no algorithm that
will get the quotes right, but I would like to be able to do the
following:
1. Select the text that needs changing with the mouse
2. Hit a key and have the text changed to the \enquote version.
I feel like this ought to be the sort of thing that TextMate excels
at. How should I do it?
Very best wishes,
Nicholas
Hi all,
I understand from the text accompanying the font "Anonymous Pro"
<http://www.ms-studio.com/FontSales/anonymouspro.html> that we should
expect a new build which will take care of some problems associated with
TTF font files with included bitmaps.
Any prognosis on when to expect this?
Andrew
Hi,
I tried to use
\usepackage{epstopdf}
to convert the eps into pdf files on the fly. But nothing is created
during the compilation process. I only get the error message that the
pdf-file could not be found.
How could I get the "epstopdf" to work?
Thanks
Christian
Dear TextMate folks,
Is there any way to invoke the "Create HTML from Document with line
numbers" command on a source file from the command line? I'd like to
be able to write a shell script to take several source files and
pretty-print them into HTML.
Alternately, is there any other way to automate the process of taking
a number of source files and creating corresponding HTML files (e.g.,
with Applescript)?
Thanks,
Lorin
I have a Ruby code project with several TODO comments in it. When I run the
TODO list command, the bundle displays an empty list.
If I open one of the Ruby source files in the project by itself, the TODO
bundle does list to TODO items it contains. Presumably the Bundle doesn't
like the way I have my project set up. I have *.rb source files in the
standard Ruby gem directory structure (i.e. in lib, test, bin
subdirectories). I manually add all files to the project (i.e. I don't have
Textmate automatically import them.) I have created lib, test, and bin
groups in the project. I have tried highlighting various collections of
items in the sidebar when running the show TODO list command to no avail.
Any suggestions as to what is wrong?
--
W.P. McNeill
http://staff.washington.edu/billmcn/index.shtml
Sent from Seattle, WA, United States
Using the bundle to write my thesis. Fantastic work; thanks for all
who contributed.
Just having one problem. I have my TM_LATEX_MASTER variable set to
"thesismaster.tex", i.e a relative path to the current project
directory. I do this because I sync my thesis folder using Dropbox,
and work on another computer occasionally. This process works for
typeset and view, i.e. it will compile thesismaster.tex even if I am
editing a different file; but watch document will not work, it keeps
complaining that there is no "/" in my file path. If I make the file
path absolute, i.e. /Users/name/Dropbox/thesismaster.tex etc, then it
works. But obviously, won't work on my other computer because I have a
different username. Using ~ doesn't work for the file path in textmate
seemingly.
Anyone have any ideas?
Thanks.
Dear List,
is there a way to change Textmate's internal shortcuts? I was unable
to find infos on it.
Specifically, I'd like to reassign Column Selection to something other
than ALT (it sometimes gets in the way on non-English keyboards).
Best,
Daniel
--
"The good people of the world are washing their cars on their lunch
break"
Daniel Stegmueller
Molukkenstraat 92
6524 NE Nijmegen, The Netherlands
I'm rather new to both Ruby and Interface Builder. So what better thing to
do than to try to write a command in Ruby that uses TextMate::UI.dialog?
Please excuse the newbness of my question. I also apologize for the length
of my post, but I tried to provide as many details as I could.
I've managed to get some basic nib goodness happening, in the form of text
fields both setting values on nib launch, and returning values on nib close.
But I'd like to implement a popup control in my nib, and am at a complete
loss for how to get the values both in and out. It's really just a short
list of options, not even dynamically generated, but it's not working and I
can't find any form of reference or help on Google.
Here's what I've got. Without worrying about the popup control, this works:
TextMate::UI.dialog(:nib => nib, :parameters => {}, :center => true) do
|dialog|
dialog.parameters = {'package' => 'com.mypackage', 'activity' =>
"ActivityClass"}
dialog.wait_for_input do |params|
package = params['package']
activity = params['activity']
puts "package: #{package}"
puts "activity: #{activity}"
end
end
I tried setting up the nib with an Array Controller, and binding Content
Array for Multiple Selection to my parameters Object Controller, with the
Model Key Path set to the parameter name (buildTarget).
This at least didn't cause errors, which was a huge step forward for me, and
even appears to return back the the whole array of objects that I'm passing
in.
Then I figure I need to bind the popup to the array controller, and I've
tried Content, Content Object, Content Values...but I'm really just shooting
in the dark.
If anyone has idea, or could even provide a reference or a working sample of
what I'm trying to do, I would be very grateful.
Hello, I now use BBedit rarely, the times TM just flat out amazes me,
I am a happy camper. There are times I still fire up the old BB, but
it gets less and less. Maybe I am getting too old to remember all
these damn keyboard shortcuts :)
1) Is there an <a href... snippet, I can not find it
2) How can I shift selected text right and left one space at a time?
3) Most other apps allow me to drag and drop a text clipping to the
apps icon, and it will open it. In TM, I have to open the clipping,
copy, then new file, then paste. Any workarounds on this one? Oddly,
I find I used this feature a lot and I am missing it.
4) I am liking soft tabs a lot, as they seem to allow me to align
things better, and when files move to other places, they stay lined up
regardless of the tab stop setting. I was happily working in 4 spaces
per tab stop, and wanted to move to 5, changing it did nothing. I had
to convert spaces to tabs, then make the change. I am not entirely
sure what I did really. Can someone give me a primer or point me to
docs on how this works?
* I am often opening tab separated files, and will need to open tabs
to 40 spaces or so, because the launch time to something like Excel is
just too aggravating, TM seems to work against me a little for this
type of work, suggestions?
5) Given code such as:
$foo = 'bar';
$this = 'that';
$something = 'else';
What is a simple way to get to:
$foo = 'bar';
$this = 'that';
$something = 'else';
6) I have picked up this TM book and printed it out, it is helping me
a lot. There is a section on being able to select some sql, and have
it run and show me the output. I am not understanding how to make
this work. I usually have a db.inc that will contain my user and pass
and db name, so it will be well outside the scope of the file I am in,
unless TM can follow that include reference. To be able to run
arbitrary sql would be huge for me, is there a better walk through? I
am just not getting this one to work. I have not tried to be honest,
since I do not understand the setup at all.
7) Any of you care to share your top #1 little tricks, the one thing
you use all the time, that just makes you happy every time you invoke
it? I mainly work in php, so leaning on things that would be helpful
in that area would be nice. Second would be bash, and lately, for
some odd reason, I have been spending some time in TCL, but not much,
so I am not sure how many tricks in there would benefit me in the long
run.
Thanks all... Hey, when is the next version coming out... just
kidding :)
--
Scott * If you contact me off list replace talklists@ with scott@ *
How do I Select all the characters between double quotes?
When I use Ctrl+Alt+B when the cursor is somewhere inside the double quotes,
it selects all the characters inside the quotes AND the quotes themselves.
Can I change this so that I can restrict selection within the quotes without
the quotes?
--
View this message in context: http://www.nabble.com/Newbie...Select-between-double-quotes-tp23907116p2390…
Sent from the textmate users mailing list archive at Nabble.com.
Having some issues with my eyesight, and although I can make the code any
size I want within TM, I can't seem to figure out how to bump up the size
in the TMCodeBrowser - I even tried adjusting the NIB, but couldn't get both
the text and the line-height bigger- I realize it's a third party plugon -
but I thought it was worth asking..
- sr
Hi, everyone
I am new to textmate, and I am working on a objective-c project, and I
tried to run the project with comand+r but the compiler returns an error
with this message
"xcodebuild: Error: the directory /Users/<myusername> does not contain
an Xcode project."
What do I need to do to run objective-c project in textmate?
Cheers
Allen
I need to do a lot of horrible search and replaces in a very large
project (actually replacing a lot of bibtex labels). I want to do a
search in project, and would like to limit it to particular files
(*.tex ones). The "Find in Project" command is replaced for searching
with excellent plugins like "Grep in project". Does anything similar
exist for search/replace?
Best,
Nicholas
I have an html file containing
<img src="dvipsnames.png"/>
The image renders correctly in the browser and also
in TextMate's builtin preview.
However, if I pipe the same file to Textmate.exit_show_html
the image does not show.
How should I specify the path to the picture so that
Textmate.exit_show_html can find it?
Thanks
Piero
Hi all,
I'm looking to extend the definition of a comment in the textmate
syntax highlighting, but I'm not quite sure how to achieve the effect
I'm after.
I frequently comment out snippets of code by sticking `if (false)
{ ... }` around the code. The other variation I use is to convert an
existing condition into a comment: `if (false && previous condition)
{ ... }`. You don't want to over-use this idiom, but it is useful in
its place.
At the moment TextMate treats this just like normal code (which is
exactly what you'd expect). I was wondering if there was a way to
make TextMate see these patterns as comments. It isn't easy as you
really want to pick the right brace to close the comment. There could
be further blocks of code nested inside the 'comment block'.
This isn't a huge priority for me, but I thought I'd raise it and
see if anyone had any obvious solutions.
Be well,
Will :-}
Hello,
How can I get 10.5.6 to use TextMate as the default application to
open text files instead of using TextEdit?
For example, if I do the following, I'd like the new file to open in
TextMate:
grep 'test' *.c > newfile
open newfile
Currently, this opens in TextEdit (ugh).
For files with an extension, I can get the system to use TextMate for
all files with that extension.
But I'd like something that works automatically for files without
extensions (like "newfile" in the example).
Also while it works to use "get info" to set the "open with"
application for an existing file,
when I do "Change All..." to use TextMate, I get the following error:
An error occurred while changing the application that
open "newfile" because not enough information is
available.
I'm using Version 1.5.8 (1498).
Thanks,
Bill Paxton
The class snippet in the Java bundle (from SVN) is not working as
expected for me. It fails guessing the correct class name from the
file name.
The regex for the class name guessing looks like this in the current snippet:
${TM_FILENAME/(.*?)(\..+)?/(?2:$1:untitled)/}
For a file that is not yet saved I get "class untitled ..." as
expected. However, if I have a Java file TestClass.java the snippet
names the class "untitledTestClass.java" - not what it is ment to be.
In an very old version of the bundle the regex in that snippet was:
${TM_FILENAME/(\w+).*|(.*)/(?1:$1)(?2:ClassName)/}
This one works for me (TM). I hope this is a good pointer to get the
snippet working again in the current bundle.
I also asked myself, whether the regex should be "improved" in such a
way, that it only accepts valid Java identifiers as class names and
otherwise informs the user about it. Nor sure whether this is beyond
the scope of the snippet, so I would like to hear some opinions, befor
I start messing with the regex ;-)
A possible improvement could be like this IMHO:
* A file MyClass.txt results in "class MyClass". As long as the
identifier is valid inside the Java file, the snippet should not care
about inapropriate named files.
* Same goes for file/class names that are against naming conventions
but compile fine anyway: class myclass, class Myclass, etc.
* The regex _should_ complain when file/class name doesn't start with
a Unicode letter, underscore, or currency symbol (dollar, euro, yen
sign). e.g. 1MyClass is not a valid class name (error at compile
time). The snippet could give the user a hint early in the process by
naming the class "class InvalidClassName" or something
* The alphabet for class names _should_ be restricted to Unicode
letters, digets, underscore and currency symbols
* keywords are not allowed as Identifiers but I'd say that's beyond
the scope of the snippet check that too
Last but not least it would be great if the tab triggers were the same
between packages for common snippets like class: python has class-->,
ruby has cla-->, java has cl-->
> { name = 'meta.test';
> match = '^(ATOM|HETATM).*(GLN)';
> captures = {
> 1 = { name = 'keyword.first-match'; };
> 2 = { name = 'string.second-match'; };
> };
> }
>
> This should color each match differently. Please note that there are
> many different ways to do this and may not be the best way for your
> needs.
>
> Do yourself a favor and look up some regex tutorials on the web. They
> will help immensely.
>
> --oliver
captures = {
1 = { name = 'keyword.first-match'; };
2 = { name = 'string.second-match'; };
};
That was the missing link I was looking for.
Thanks Oliver.
Marc
> his indeed works but I do think I need to be a bit more specific.
> Lets look again at the line:
>
> ATOM 14 CA GLN A 2 -27.648 -9.581 30.325 1.00 10.00
>
> My goal is to have both the 'ATOM' string and the 'GLN' string colored
> differently.
>
> Using ^(ATOM|HETATM)\b I can color the ATOM part.
> Using \bGLN\b I can color the GLN part.
>
> The problem is that I only want the GLN part to be colored if the line
> starts with ATOM. In your reply the complete part starting with ATOM
> up to GLN gets colored.
>
> Marc
Dear all,
Thanks for all comments and tips on my "Conditional regex" question.
Nevertheless I'm still a bit of a novice when it deals with regular
expressions.
Although I can see the logic in many of your tips I'm still unable to
put the
bits and pieced together into a functional expression.
Would anyone of you be so kind to provide me with a more elaborate
answer/example?
Thanks,
Marc
>> I believe this is the correct firstLineMatch for AS3:
>> package\s?([\w\.]*)\s?{
>
> You need to add a ^ assertion to the beginning of that at least. And
> you need to make sure it can't get triggered in D, Doxygen, Groovy,
> Java, JavaScript, Processing, Scala. (The languages I quickly scanned
> to see have a package keyword that could get tripped up)
I did some quick research:
- The Java-based languages use a semi-colon, rather than a brace.
- D uses 'module' to define its packages.
- Before I added the firstLineMatch, my files were coming up as
plain-text. If there's a language this pattern conflicts with,
TextMate doesn't know about it out-of-the-box.
Here's a slightly-modified version that caps the ends of the string.
It also makes the { optional (in case someone puts his braces on the
next line):
^package\s?([\w\.]*)\s?{?$
> I used \bAS3\b because comments are as likely to be found on the
> first line as package declarations. So, for anyone who wanted to,
> adding 'AS3' would help TM identify ActionScript 3 over ActionScript
> files.
>
> I've also taken the liberty of adding 'AS3' into the comment header
> for the same reason.
I'd venture a guess that package ... { is the handily the most common
first line of an AS class; however, why don't we use either method?
(^package\s?([\w\.]*)\s?{?$)|(\bAS3\b)
Note: I get this as a first line if I do new AS3 class from template:
package .var.folders.NQ.NQfuLuLLE+aVJJfvkTLNwU+++TI.-Tmp- {
I imagine I'll have plenty to contribute in the way of bundlie-
goodness. I don't personally use a version control system, and I'm
not wed to any of them. Is there any sort of utility that will enable
me to contribute to any of them, so I could fork somebody on github
and somebody else on bitbucket without having to mess with git and hg?
Thanks,
B
Hi,
I've been using TextMate for almost a year now and like it very much.
I'm trying to stay off my mouse and here is one task I think I should be
able to do without using mouse. From time to time, I copy some code to a
new editor window and run. What is the keyboard shortcut to invoke the
file type dropdown in the bottom of the editor?
Thank you.
Cao
Hello everybody,
I use TextMate mainly for LaTex editing.
In LaTex, I often use a package "jurarsp". This package works by way
of running BibTex on a file with the extension *.rsp.aux (okay,
admittedly the," rsp"-part is not the file extension, but you get the
gist, I hope). In TextMate, I set all my LaTex projects to run the
latex, bibtex, etc. commands on a master file. Now I want to create a
custom command that would run bibtex on the master_file.rsp.aux file,
where the "master_file"-part would automatically be the name of the
master file of the current project. The bibtex command already
achieves this by using this simple syntax:
texMate.py bibtex 1
However, simply adding .rsp.aux after the 1 does not work. So I guess
what I am looking for is a command or regular expression that would do
the following: get the name of the current master file without
extension, and add the extension .rsp.aux to this name. Maybe that is
very simpe question I am asking but I promise you that I duly
researched the mailing list and could not find an answer.
Thank you for any suggestions,
JJ
My LaTeX bundle is latexmk.pl to compile LaTeX documents, but I have no idea
where this file is. I have search my entire hard drive. Where
does latexmk.pl reside?
--
W.P. McNeill
http://staff.washington.edu/billmcn/index.shtml
Sent from Seattle, WA, United States
Hello all,
I'm developing a bundle for handling biomolecular structure files (PDB
files). I'm now working on
getting the language description sorted out. In doing this I ran into
a regex problem.
The situation:
A PDB file is essentially a table. One line from such a table can be
as follows:
ATOM 14 CA GLN A 2 -27.648 -9.581 30.325 1.00 10.00
In the language description I would like to use a regular expression
construct that
matched 'GLN' only if the line starts with either 'ATOM' or 'HETATM'.
This seams like
a conditional regular expression but my attempts to implement it at
such have failed
so far.
Can anyone help?
Thanks,
Marc
>> ball.graphics.beginFill // inserts the following grep error into my
>> file:
>> grep: /Users/brenton/Library/Application Support/TextMate/Bundles/
>> ActionScript 3.tmbundle/support/data/completions.txt: No such file or
>> directory
>> ();
>
> This is a bug I need to fix. Could you could let me know if both of
> the following exist for you:
>
> ~/Library/Application Support/TextMate/Bundles/ActionScript 3.tmbundle
> ~/Library/Application Support/TextMate/Pristine Copy/Bundles/
> ActionScript 3.tmbundle
>
Both exist. completions.txt is in Pristine Copy (and Support is
capitalized in the bundle but not in the error. This could cause
problems on case-sensitive file-systems).
>> I've heard great things about TextMate. I'm still yet to find an
>> editor that rivals FlashDevelop on Mac, but I'm hoping to change
>> that. =)
>
> Contributions are most welcome :) Ideally by forking the bundle on
> github:
>
> http://github.com/simongregory/actionscript3-tmbundle/tree/master
Considering, but then I'd need to have Git. =P
Thanks!
Brenton