I'm working with a legacy codebase, some of which uses CRLF line endings,
mixed with more recent updates which use LF.
Textmate displays these as <CR>
Is there an existing bundle item which will strip the <CR> and make the
full file LF consistent?
I'd rather this was a manual action rather than Save As... or done
transparently, because it can complicate git conflicts if its not managed.
Thanks
Hi,
short question:
Is it possible for a command (Input: “Selection” - fallback to “Line” ; Output: HTML window) to replace the "Input selection" via Javascript's TextMate.system()?
TextMate.system("$DIALOG x-insert --text 'foo'", null) works but only for a selection and not for the fallback situation.
Has anyone an idea?
Thanks,
Hans
Hi,
Here's a crash I'm getting deterministically on hitting ⌘G, when the text can't be found (when no occurrence exists, or after all occurrences have been found, even with the wrap around option selected). I can reproduce the crash as follows:
- Create a new empty file, or open any existing text.
- Open the Find dialog, enter a Find string that doesn't exist in the document, close the Find dialog.
- Hit ⌘G. TextMate will always crash.
I'm more than happy to provide any additional information, and my apologies if this has already been reported.
enas
1. Is there a way to use the current selection for "Incremental Search"
(⌃S)? It would be great to have "Use Selection for Find" (⌘E) to do the
same for "Incremental Search".
2. When using the combo of "Use Selection for Find" (⌘E) and "Find All"
(⌥⌘F), the file is scrolled to the last match. If you're at the top of a
long file, having it scrolled to the bottom can be pretty disorienting. Is
there a way to reverse this to have the file scrolled to the first match?
3. Using the same combo as before, ⌘E then ⌥⌘F, is there a shortcut for
jumping through each match without deselecting the matches?
4. Is there a way to enable "Incremental Search" (⌃S) to highlight all
matches as you type, instead of just the first?
Thanks,
Ryan
Steps to reproduce:
* Set font size to larger than the default.
* Position the cursor towards the bottom of a file such that the
viewport is displaying the bottom part of that file.
* Switch to another tab.
* Switch back to the original tab.
* See that although the cursor is still in the same place, the
viewport is now displaying an earlier part of the file.
It looks as if the viewport position calculation is not taking into
account the larger font size.
Cheers, James.
Thanks for the hint.
I've experimented more than a couple of things and found the following
settings works for me, at least it's much better than broken.
Under 'Budles' => 'Edit' => 'Settings' => 'Indenting':
{ disableIndentCorrections = :true;
indentOnPaste = 'simple';
foldingStartMarker = '^\s*"""(?=.)(?!.*""")';
foldingIndentedBlockStart = '^\s*.*(:|-) ?(&\w+)?(\{[^}"'']*|\([^)"'']*)?$';
foldingIndentedBlockIgnore = '^\s*#';
}
foldingStartMarker was copied from Python setting.
foldingIndentedBlockIgnore was copied from the 'Fold on the Dotted Line'
section in http://blog.macromates.com/2012/the-layout-engine/
If I hold down ALT, I can use the mouse to select a rectangular block of
text
Just wondering if there is any way to do this using solely the keyboard?
Thanks
Hi,
When using the US-International keyboard layout, if you want to enclose selected text with quotes, single quotes or back-quotes by typing them, the originally selected text is deleted.
Those keys are used for diacritical accents by the US-International layout and require two keystrokes, the quote character itself followed by either a space to indicate you actually want the quote character itself, or a different character if you want to apply the diacritical accent on it. For instance a single quote ' followed by an a gives á. If the quote character is followed by a character that doesn't accept diacritical accents then the layout issues the two characters as they were typed, so a " followed by a w gives "w
I do most of my programming using the standard US layout but sometimes I need to switch to spanish or french.
A really insignificant bug, I know :p and I can certainly live with it, so this is mostly for information. It's good to know someone knows it's there :-)
Gualo
Textmate gets frozen for 15 seconds and then throws
```
JavaScript Warning
The command ‘ruby18 "/Users/igor1043k/Library/Application Support/TextMate/Managed/Bundles/Git.tmbundle/Support"/dispatch.rb "controller=log" "action=open_revision" "file_path=/Users/igor1043k/git/Bilbeo/Application/DataAPI/libs/models/Workspace.js" "revision=9201f304"’ has been running for 15 seconds. Would you like to stop it?
To avoid this warning, the bundle command should use the asynchronous version of TextMate.system().
```
This bug is very old and it looks like no one but me uses this feature. Maybe someone with ruby knowledge can fix this thing?
Thanks.
First, I like new commit window/sheet, very nice.
Second. it seems I cannot close the sheet with a keyboard shortcut if
there's a commit message present. Is that intentional? Note that when
amending there's always a commit message.
--
/Jacob Carlborg
A while ago, I reported a text field visibility bug in the Search & Replace window, and after updating to alpha.9565, I noticed it’s back.
When you bring up the Search & Replace window, anything you type in the search or replace text fields will not appear until you bring up the Search & Replace window again (e. g. by aborting and pressing Command + F again).
Does anyone else see that behavior?
Max
Is it possible to offer the Dockerfile bundle as part of the TextMate
config options? I think there's enough popularity (at least momentum)
behind Docker to make this worthy of being listed on the master list.
https://github.com/docker/docker/tree/master/contrib/syntax/textmate
Ken
I have a recurring problem where TM cannot detect file changes.
This is because I work on a a remote filesystem (Centos), which is mounted
via AFP.
Its actually a VM running on ESXI Server on my LAN, although a Vagrant or
VMWare setup is quite common now.
>From what I understand, TM uses kqueue or BSD's FSEvents for file
notifications (I suspect kqueue?).
Its causing me a lot of problems as I switch git branch and TM doesn't
always detect it, sometimes resulting in a file from another branch being
saved over the top.
A bit of googling shows there is libkqueue, which tries to provide a kqueue
interface on top of the underlying host OS, but its not clear to me whether
this would be suitable for a remote fs, even if it was feasible to compile
into TM.
Has anyone found a workaround to this please?
Hello,
in TM 1 the symbol list (on the right-hand side of the status bar) was sorted alphabetically, is there some way to get this back in TM 2?
Kind regards,
Tobias Jung
Hi,
I've found a document modified status issue when using "Replace all" with either project or folder Find in... dialogs
When the Replace All button is clicked all the matches are applied to the documents containing them, but the status of the affected documents (which where not modified before issuing the command) does not change to "modified" as it could be expected.
When you close the Find in... dialog it shows a dialog box with the option to save the affected documents.
The text in the dialog states that the changes will be lost if you don't save them, which is actually incorrect, or at least misleading, because if you select not to save the documents they still include the applied changes. Their "modified" status though doesn't reflect this.
To reproduce the bug just open two or more files that contain a common string, open a Find in... dialog and do a replace all of that string, check the documents' statuses.
Unless I'm missing something obvious I believe that the additional "save documents" dialog is a lot of work just to save the "⌥⌘S" I'd issue anyway in most cases, but not always.
Also, given that the Find in... dialogs aren't modal, so the user can switch back to the documents and continue working, when he gets back to the Find dialog and closes it he may not always remember the context in which he executed the replace operation. When that happens my " keep the control" attitude always forces me to select not to save them ;-)
If a builtin "save changes" option is nevertheless required then I believe that an additional "Replace All & Save" button could be more effective.
To minimize real estate usage this button could be placed immediately to the right of the Replace All button with just "& Save" as the label. Alternatively, given that in this case the "Replace & Find" action button is apparently always disabled it could simply replace it.
Thanks
Gualo
Fortran storage modifiers do not appear with colours although they have set to this in the used TextMate theme and language
grammar.
In my custom theme, I have set
{ name = 'Storage';
scope = 'storage, storage.type, storage.modifier';
settings = {
fontStyle = 'bold';
foreground = '#003366';
};
which is clearly directing syntax colour for storage, storage type, and storage modifier.
In Fortran bundle, the grammar of Modern Fortran contains information of storage modifiers
{ name = 'storage.modifier.fortran.modern';
match = '\b(?i:(kind|len|optional|recursive|pointer|allocatable|target|private|public))\b';
},
Any idea how to get syntax colors for storage modifiers in a Fortran code? I have tried but did not get success.
It'd be great if TextMate could show the full path in the title bar of the
window, and in the Window drop-down because it's kind of driving me batty,
having projects opened with similar file names.
Is this an option?
--
Wells Oliver
wellsoliver(a)gmail.com
On 03 Sep 2014, at 08:00, textmate-request(a)lists.macromates.com wrote:
> I can?t reproduce this with 2.0-alpha.9563 but there have been a lot
> of changes done to the find dialog, so I assume it has been fixed,
> otherwise let me know.
Shortly after my post, alpha.9563 was made available for download. Indeed, Search & Replace works as expected now, I think the issue has been fixed.
Thanks!
Max
Hi,
using the Perl gramar, if I have the cursor on a package name, like
Time::Mo|ment, (| is the cursor) and I try to get help, it should try to
get help on Time::Moment but right now it only uses Moment.
I had this problem with TM1 also but I fixed it by including : in the
definition of the "word". I don't know if this is still the way to do it on
TM2 or if there is a better way.
Suggestions?
Thanks,
--
Pedro Melo
@pedromelo
http://www.simplicidade.org/
xmpp:melo@simplicidade.org
mailto:melo@simplicidade.org
The search and replace window has a serious bug: the text in the search and in the replace text fields is not updated as you type, meaning whatever was in these fields from the last search is displayed properly. But if you edit the text in one of the fields, it is not updated. Functionality-wise, everything still seems to work, meaning that the text you’ve entered blindly in the search field still is what TextMate searches for and the text in the replace text field is what the search term will be replaced with.
Also, if you do a search all, the first time you press the button Search All, the Replace All button remains grayed out. Only after pressing Search All a second time does the Replace All button become active.
Does anyone else have the same problem?
Max
Hi all,
As of only very recently, I get the following drop-down error box when I
try to typeset a LaTeX document:
| Failure running "Typeset & View (PDF)".
|
| Typeset & View (PDF):4: undefined method `+' for nil:NilClass
(NoMethodError)
I think it was working until 1-2 updates ago.
Andrew
Is there a way to have TextMate remember the tab settings for a specific
file? I seem to recall that TextMate 1 did this.
I have a file with a .txt extension that I would like to always be set to
indent size 2 with soft tabs.
In my default .tm_properties file I have the a [ text.plain ] section that
sets the defaults to 8 and no soft tabs so I assume that this is why the
file is always opened with these settings. I would like to make this one
file an exception, but it is not part of any particular "project" just a
one off file.
I suppose I could add an entry in my default .tm_properties file for each
specific exception to the rule, but was hoping there might be a way that
wouldn't involve this.
Thanks.
On 15 Aug 2014, at 19:16, riki wrote:
> […] In the following code:
>
> […] I checked scope as you suggested. I got storage modifier scope
> […] but not for allocatable.
The issue is not related to your custom theme but rather the Fortran
grammar.
The Fortran - Modern grammar includes Fortran - Punchcard. This grammar
has a rule for ‘meta.specification.fortran’. In this rule, a new
context is started, and only Punchcard rules are included into that
context, this is line 69 in the (Punchcard) grammar which is:
patterns = ( { include = '$self'; } );
If we change this to instead include the Modern grammar then it works:
patterns = ( { include = 'source.fortran.modern'; } );
There are other places where Punchcard includes Modern (it actually
includes $self + Modern, but here $self is redundant since Modern
includes Punchcard).
I do not know about this Modern vs Punchcard, it seems that if Punchcard
is made to include Modern (as it already does) the two grammars should
just be combined into a single one, which would make parsing more
trapsnarent.
Just upgraded to TextMate 2 (have not used TextMate in a while, glad to be back :-)
I’m also starting to try and due Rails development in TextMate. The Rails Bundle is dated, and so is only partially usable. I would like to start “fixing” that in my spare time. One thing, though, that would be nice, is the ability to edit Ruby code in the Bundle Editor. The files show up, but I cannot click on them. The only way I can edit is “mate …” from the command line the files I want to modify.
Not a big deal, but would be nice.
Is there any way to show the SVN new/modified/deleted lines on the editor, just like the Modific plugin (https://github.com/gornostal/Modific)?
I mean, some kind of line badges/colors to highlight the changes.
Thanks,
Rubén
Hello Everyone,
I've been participating in a thread on GitHub
(https://github.com/deplorableword/textmate-solarized/issues/52) that
has identified the selection of text in the Solarized Dark theme as a
real issue. It seems that implementation of
selectionForeground/selectionBackground may be one solution for the
frustrating issue. I wanted to see if there was a wider desire for a
solution to this problem here, and perhaps if there was more support for
the implementation of selectionForeground/selectionBackground.
Thanks,
Alex
I found a strange behavior that I believe is a bug. I am using 2.0-alpha.9503 on OS 10.9.1.
First I redefined the keyboard shortcut for "Comment Line" in the system Preferences. This command is from the "Source" bundle and appears as alternative shortcut to the default ⌘/ in the bundle menu (I used ⌘- in order to avoid the rather clumsy command for german keyboard layout).
Right after that both shortcuts work fine. After closing and reopening TextMate, only the default shortcut ⌘/ works, the new shortcut is now ignored.
When I select Bundles -> Source -> Comments I can see that the commands are still set correctly. After that, both shortcuts work again, until I close TextMate and open it again: the new shortcut is ignored until the menu selecting Bundles -> Source -> Comments is opened up, after that it works till closing TextMate again.
I was struggling some time with this issue, without solution. Now after testing for writing this bug report, at least there is a simple workaround. But maybe it can be resolved. I also tried changing the Bundle "Source" itself, but that didn't do the trick either.
Martin
I've found this great BlurMate plugin today for TM2.
https://github.com/cliffrowley/blurmate
It works great, I just wonder since it's just a few lines of code,
why background blurring is not included in TM2 already?
I always loved the blur in Terminal and thought that TM2 is not capable of it.
Found the plugin just by accident.
Some way to set the blur using "defaults" for example would be nice.
On 15 Aug 2014, at 18:37, riki wrote:
> Please find herewith my custom theme.
> […]
I do not see any issue here.
I saved your theme and switched to it. Then changed langauge to Fortran
— Modern and entered ‘recursive’. This keyword is shown in bold
and with a slight color change (rather subtle though).
The rule in my Fortran grammar does btw not include as many keywords as
yours. Did you edit the grammar? Did you verify that you get the storage
scope (using ⌃⇧P)?
In a .tex file, typing sec + tab prints code for a section header and label. Very handily, the label for the section header syncs with the actual section header the first time the section is typed. However, thereafter, if the section header changes, the label doesn't change. Is it possible to always have the label change whenever the section header changes?
Many thanks
Ross
Hi,
We’re writing a booking (currently LaTeX) and I’d like to be able to use TM themes in the code listings.
Any solutions for that?
We’re using LaTeX packages “listings” + “color” to do the syntax highlighting. It allows statements such as this:
\definecolor{codegreen}{rgb}{0,0.6,0}
\definecolor{codegray}{rgb}{0.5,0.5,0.5}
\definecolor{codepurple}{rgb}{0.58,0,0.82}
\definecolor{backcolour}{rgb}{0.95,0.95,0.92}
\lstdefinestyle{mystyle}{
backgroundcolor=\color{backcolour},
commentstyle=\color{codegreen},
keywordstyle=\color{magenta},
numberstyle=\tiny\color{codegray},
stringstyle=\color{codepurple},
basicstyle=\footnotesize,
breakatwhitespace=false,
breaklines=true,
captionpos=b,
keepspaces=true,
numbers=left,
numbersep=5pt,
showspaces=false,
showstringspaces=false,
showtabs=false,
tabsize=2
}
Pretty basic… Anyone seen anything better (pygments?) Or even a way to convert themes to this style?
Thank you, and best wishes,
tim
TextMate has keyboard shortcuts to show the file browser
(option+control+command+D) and switch focus to the file browser
(option+command+tab), but I cannot find a keyboard shortcut to open a file
from the file browser. The only way I can find for opening a file from from
the file browser is by clicking on the file with the trackpad. Is there a
keyboard shortcut available to open files from the file browser?
Cheers
Ross
Hi,
I came across with a rendering bug,
to reproduce it copy the following two lines and paste them into a TM document:
587 3 402 ̃ wa:w.4 NULL NULL NULL NULL
591 3 402 kha:ŋ.4 kha:w.4 NULL NULL NULL NULL
On my machine OSX 10.9.1 TM 2.0-alpha.9503 these lines are rendered as shown in that picture:
The "problem" seems to be that TM is not able to get rid of a TAB {utf8: 09} (and I believe this's true for each CONTROL character) followed by a combing diacritic - in that case a combining tilde {utf8: CC 83}. The actual data in the TM window are correct, you can e.g. look for TAB characters. If you remove the combining tilde TM renders the text correctly.
I'm aware that this is actually my fault since a combining character shouldn't appear after a control character and "more actually" I'm glad that TM had this bug thus I could find my fault ;) but I think TM should do it like other Mac apps e.g. TextEdit.
For safety reasons I attached a UTF-8 text file containing both lines.
Cheers, Hans
I want to modify the regex in the PHP language bundle item that applies the meta.embedded.sql scope to a string. I did this successfully in TM1, but with TM2 I opted to start with a fresh set of bundles and have been having trouble adding this functionality back in.
The PHP code continuing a string of SQL is this:
$db->query("
UPDATE table
SET foo = bar
WHERE foo = '" . function($variable) . "'
");
I tried many variations of the following, added just below the existing meta.embedded.sql rule:
{ name = 'meta.embedded.sql';
begin = '(\$db)->(query)\((")';
end = '(\3)\);';
beginCaptures = {
0 = { name = 'variable.other.php'; };
1 = { name = 'meta.function-call.object.php'; };
2 = { name = 'string.quoted.double.php'; };
};
endCaptures = {
0 = { name = 'string.quoted.double.php'; };
};
contentName = 'source.sql';
patterns = ( { include = 'source.sql'; } );
},
I've even tried simplifying it with only the 'name,' 'begin,' and 'end' and the scope isn't applied where I'd expect it. I can't see why.
I also found this rule (here is only a portion), which I thought I would modify:
name = 'string.quoted.double.sql.php';
begin = '"\s*(?=(SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER)\b)';
I tried changing this to:
begin = '"[\s\n\r]*(?=(SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER)\b)';
so that it would match the code example above, but the regex doesn't seem to be matching over multiple lines; it only works if the quote mark is on the same line as the UPDATE.
Can somebody please show me how to do this (with whichever of the above rules is more better)?
Once I get a working rule, I would like to add this to a custom bundle that includes the default PHP grammar and adds this modification to it so that I have a stock PHP bundle that is unmodified. Does anybody have an example of an extended PHP bundle so I can see how this should be done?
Thanks thanks,
Quinn
I¹ve upgraded to Yosemite beta and cannot save files. If I try to save a
file, a box pops that says the following:
Failure running ³Strip trailing whitespace on save². interpreter failed: No
such file or directory
What can I do to resolve this?
Thanks
Ross
I’m currently updating the RSpec bundle’s readme. The most important
(and also most complicated) part deals with how to run RSpec examples
from TextMate using the correct versions of Ruby and RSpec.
I’d love to get feedback on this. Here is the current version (work in
progress, the relevant section is the one titled “Supports RSpec 1, 2
and 3“):
https://github.com/rspec/rspec-tmbundle/blob/update-readme/README.md
(Topics like “How do I get TextMate to use rbenv for running my Ruby
scripts” have popped up several times on this list, so this may be
interesting even for people not using RSpec.)
Feel free to add any suggestions or corrections to the pull request at
https://github.com/rspec/rspec-tmbundle/pull/80
Thanks!
Stefan
Today I tried to install a bundle via Preferences → Bundles, but it
didn’t work: When I click on the checkbox the statusbar says “Installing
…” for some moments before changing to “Installed …“, but the checkbox
is unchecked (and the bundle has indeed not been installed).
Tried everything from
https://github.com/textmate/textmate/wiki/Reverting-To-Defaults, but
didn’t seem to make a difference. Tested in alpha.9551 and alpha.9553.
Any ideas?
Stefan
I attempted to build the MacPorts textmate2 port, originally for 2.0-alpha.9537, and got an "unknown signee" error during configure when it attempted to download the bundles.
I reported it on MacPorts Trac: https://trac.macports.org/ticket/43466. That ticket contains the steps I took and also now contains what I did to get the build to work.
My problem seems very similar to
http://lists.macromates.com/textmate/2013-February/035922.htmlhttp://textmate.1073791.n5.nabble.com/Unknown-signee-errors-td25943.html
and
http://permalink.gmane.org/gmane.os.apple.macports.tickets/68860
I think that there might be a couple of issues in key_chain.cc.
In file key_chain.cc, the line
if(err = SecItemImport(data, NULL, &type, &format, 0, ¶ms, NULL, &items) == errSecSuccess)
causes variable err to be set to the result of the logical expression, whereas the intent is to set it to the return value of SecItemImport. Needs either parentheses or splitting into an assignment and an if(). I chose the latter as in the diff output below.
Also, the documentation for SecItemImport (at https://developer.apple.com/library/mac/documentation/security/Reference/ke…) shows that the sequence of parameters &type and &format is wrong. I reversed them.
These changes didn't fix the problem but at least showed that SecItemImport was returning errSecAddinLoadFailed. On a hunch, I changed both &type and &format to pass the "unknown" enum and that fixed the problem.
I've included below the diff of the resulting changes, with a long comment added explaining that I didn't investigate whether both &type and &format needed to be changed or just one. If I had to guess, I'd say it was &format.
I have no idea why this was a problem for me and not for others.
The diff:
*** /tmp/key_chain.cc 2014-06-12 15:55:45.000000000 +1000
--- /tmp/key_chain.cc_orig 2014-06-12 15:55:45.000000000 +1000
***************
*** 31,56 ****
bool res = false;
SecItemImportExportKeyParameters params = { .keyUsage = NULL, .keyAttributes = NULL };
! /*****************************************************
! /* Specifying the expected Item Type and Format
! * caused SecItemImport to return
! * errSecAddinLoadFailed.
! * I didn't check whether it was due to both being
! * specified or just one. Setting to the Unknown enum
! * worked.
! * Original code on next two comment lines.
! /* SecExternalItemType type = kSecItemTypePublicKey;
! /* SecExternalFormat format = kSecFormatPEMSequence;
! * Updated code with both vars set to unknown on next
! * two lines. */
! SecExternalFormat format = kSecFormatUnknown;
! SecExternalItemType type = kSecItemTypeUnknown;
CFDataRef data = CFDataCreateWithBytesNoCopy(NULL, (const UInt8*)_key_data.data(), _key_data.size(), kCFAllocatorNull);
CFArrayRef items = NULL;
OSStatus err;
! err = SecItemImport(data, NULL, &format, &type, 0, ¶ms, NULL, &items);
! if(err == errSecSuccess)
{
_sec_key = (SecKeyRef)CFArrayGetValueAtIndex(items, 0);
if(_sec_key != NULL)
--- 31,43 ----
bool res = false;
SecItemImportExportKeyParameters params = { .keyUsage = NULL, .keyAttributes = NULL };
! SecExternalItemType type = kSecItemTypePublicKey;
! SecExternalFormat format = kSecFormatPEMSequence;
CFDataRef data = CFDataCreateWithBytesNoCopy(NULL, (const UInt8*)_key_data.data(), _key_data.size(), kCFAllocatorNull);
CFArrayRef items = NULL;
OSStatus err;
! if(err = SecItemImport(data, NULL, &type, &format, 0, ¶ms, NULL, &items) == errSecSuccess)
{
_sec_key = (SecKeyRef)CFArrayGetValueAtIndex(items, 0);
if(_sec_key != NULL)
regards - David
I was looking through the fork's of the original Handlebars and bundle
(which doesn't work very well anymore in 2.x land). Anyway, found this:
https://github.com/savetheclocktower/Handlebars.tmbundle
which on appears to be written in a very thoughtful way and geared
specifically for 2.x but unfortunately it doesn't work perfectly for me and
I'm too busy at the moment to dig into it. Does anyone else have any
bundles that work well for Handlebars?
ken
p.s. the problem I'm having is that while block commands like #each are
being highlighted correctly the more basic {{foobar}} variable
substitutions are NOT being highlighted.
Is anybody else having trouble using the default "Replace Conflict With Older Text" and "Replace Conflict With Newer Text" macros? They don't seem to work for me.
If I try to record a new macro, it doesn't remember the 'replace' value. That is, it works until I run some other search/replace command then my new macro for resolving conflicts just runs the last-used replace value. The macro I recorded contains this:
(
{ argument = {
action = 'findNext';
findString = '(?m:<<<<<<<[^\n]*?\n(.*?\n?)=======\n(.*?\n?)>>>>>>>([^\n]*)\n)';
ignoreCase = :true;
regularExpression = :true;
wrapAround = :true;
};
command = 'findWithOptions:';
},
{ command = 'replaceAllInSelection:'; },
)
See, no replace value. So I added a 'replaceString' item manually:
(
{ argument = {
action = 'findNext';
findString = '(?m:<<<<<<<[^\n]*?\n(.*?\n?)=======\n(.*?\n?)>>>>>>>([^\n]*)\n)';
ignoreCase = :true;
regularExpression = :true;
wrapAround = :true;
replaceAllScope = 'document';
replaceString = '$1';
};
command = 'findWithOptions:';
},
{ command = 'replaceAllInSelection:'; },
)
But it doesn't use this value, only the last one used in the find dialog box.
Any ideas?
--
Quinn Comendant
Strangecode, LLC
http://www.strangecode.com/
+1 530 624 4410 mobile
+1 530 636 2633 office
@qc and @strangecode
I often paste some crap from some terrible MS Word document into Textmate
and then into something else. Don't inquire as to the unholy nature of my
burdens such that I'm doing this work, just be thankful it's not you.
Is there a bundle that will clean up those awful fancy double quotes,
ellipses, etc, that Word likes to use into plaintext versions? It'd be
great.
Thanks all! Long live TextMate.
--
Wells Oliver
wellsoliver(a)gmail.com
The markdown-redcarpet bundle [1] supports fenced code blocks with
syntax highlighing, for example for shell scripts. The grammar pattern is:
fenced_block_shell = {
name = 'markup.raw.block.markdown.fenced';
begin = '(^|\G)([`]{3})[ ]*(?:bash|shell|sh)$';
end = '(^|\G)([`]{3})(\n|\z)';
patterns = ( { include = 'source.shell'; } );
};
This works fine, unless if have a block like:
```shell
dd bs=1m if=foo.img of=/dev/disk1
```
Here, “if” starts the scope “meta.scope.if-block.shell”, and this scope
extends beyond the ``` the end of the fenced code block, resulting in
incorrect highlighting for the rest of the markdown file.
Is there a way to include grammars in a way making sure the included
grammar does not extend beyond the “end marker” in any case?
And: Could the rule for if-blocks in the shellscript bundle be more
strict (matching only '^\s*if\b' for example)? Is this rule needed at
all? (I haven’t found any other references to the scope “if-block” in
the shellscript bundle.)
Stefan
[1]: https://github.com/streeter/markdown-redcarpet.tmbundle
I’m now one of the maintainers of RSpec’s textmate bundle. We just fixed
a bunch of issues, so if in the past you experienced problems with the
bundle please try again with the latest version.
Feel free to submit any issues you encounter at
https://github.com/rspec/rspec-tmbundle/issues/
I’m also thinking of removing support for RSpec 1 – if you’re still
using the bundle with RSpec 1 please chime in at
https://github.com/rspec/rspec-tmbundle/issues/78
Stefan
My bundles have been broken since the change to specify ruby18 ("Point to ruby 1.8 shim”, e.g. https://github.com/textmate/source.tmbundle/commit/8b80da05 . I understand the PATH changes, but it’s not a path issue — there is no “ruby18” executable on my system at all. I DO have Ruby 1.8.7 installed (with rbenv), just no `ruby18`.
Wondering if my system is an outlier, or if others have experienced this? What is the “shim” that ruby18 should be pointing to?
Thanks,
David
I'm using the TextMate version 2.0-alpha.9551 build and wanted to make sure
I had the latest version of JSLintMate. I deleted the existing bundle from
within Textmate and then downloaded and installed the latest bundle by
double clicking the bundle file/package. That seems to work in the sense
that it pops a dialog to install the bundle and the bundle file is then
locatable in:
Application Support → Avian → Pristine Copy → Bundles
The problem is it doesn't show up in the bundle menu. I've tried a restart
but that didn't help. Any idea why I'm not getting the bundle registered?
Ken