Hello all, I'm trying to make use of some external refactoring tools
for Haskell, and I've written the following script:
#!/usr/local/bin/ runghc
import System.Cmd
where
main = do
c <- getContents
system ("/Users/ian/.cabal/bin/pointfree \"" ++ c ++ "\"")
Here's the problem:
Whenever I try to run the script, the output I get says "interpreter
failed: Permission denied". Now, I'm pretty sure that the script
execution fails even without executing the local program pointfree.
Any ideas what I'm doing wrong?
-Ian Duncan
Hello,
I have read this page
http://blog.macromates.com/2005/handling-encodings-utf-8/ and I use
UTF8 wherever I can. But, sometimes I have to open czech text-files,
made on MS Windows (not made by me), that are, almost without
exception, in "Central European (Windows Latin)", or, Windows 1250 (
http://en.wikipedia.org/wiki/Windows-1250 ).
ISO-8859-1 is different from Windows-1250, some of the czech letters
appear weird - for example, http://en.wikipedia.org/wiki/Ø instead of
http://en.wikipedia.org/wiki/Ř
Right now, when I get file like that, I need to
1) open it in TextMate, only to find out I cannot open it
2) open TextEdit, open the file in TextEdit, re-save it in UTF8
3) open it in TextMate again, swearing on all sides
I personally find this procedure stupid and I would love to have the
opportunity to, at least, open the file in Windows-1250 and convert it
to UTF8 and not having to start another text editor.
Karel Bilek
Hi,
I recently opened one of my old Java files and remembered I used some
snippet to create a method and automatically create a header comment
and javadoc comment like this:
/**
* doSteps
*
* calculate n steps each lasting 0.005s
*
* @param steps number of steps each of which accounts for
0.005s
*/
public void doSteps(int steps) {
//do smth...;
}
I can't find this anywhere anymore. Can anyone help me out here? The
snippet automatically jumped to the return type, then the function
name (also inserting it at the top in the comment), then to the @param
thingy to enter text and finally to the function itself to write some
code. At least that's how I think it went. Might be that I idealize a
bit from bad memory :P
Does someone know of a snippet like this? I already searched the web
but couldn't find something. (Yeah I also searched the Javadoc
bundle... but it isn't there :( )
Maybe I was just dreaming of this snippet :(
Thanks,
Thomas Krajacic
Hi,
I'm sure that question must have been asked over and over, but I
couldn't find any similar question, so please forgive my ignorance.
I'm just wondering if there's any simple shortcut to navigate between
blocks. Suppose I'm in the middle of a big block, I want to go to the
end of it, or to the beginning. What's I'm currently doing is either
an F1 to fold the block, if I want to go outside (right after or right
before), but which is not ideal since I don't always want to actually
make the block invisible, or I use the Cmd-Shift-T to open the go to
symbol panel, then type Enter if I want to go to the beginning of the
block, or Down then Enter if I want to go to the end of the block. But
that's too many strikes.
Is there any direct shortcut for what I want - or how can I define
one? What are your habits on that topic? (I particularly use that when
writing LaTeX documents.)
Thanks,
enas
I think I got misunderstood by JiHo : I want to avoid the matlab GUI
as much as possible. The matlab-console I developed is an
implementation of the matlab console IN textmate.
For what I described I use a very similar command as JiHo, except that
I tend to use the cell mode (which Thomas added in the last version of
the bundle). And in this cases because the commands that are sent to
the terminal can be long, I use an temporary m-file (called cellrunner
in the following code).
I've came up with a better applescript thought, which is more robust
when you have several terminal windows or tabs running :
osascript<<END
tell application "Terminal"
set termwin to id of windows
set nwin to count of termwin
repeat with i from 1 to nwin
set ntab to number of tab of window i
repeat with j from 1 to ntab
set pr to processes of tab j of window i
set npr to count of pr
set runsmatlab to false
repeat with k from 1 to npr
set runsmatlab to "MATLAB" = item k of pr
end repeat
if runsmatlab then
set selected of tab j of window i to true
do script with command "cellrunner" in tab j of window i
end if
end repeat
end repeat
end tell
tell application "MATLAB" to activate
END
Pierre
Hi,
So I use Find in Project to search code and find various sources when
I've pulled down say.. a set of Java classes for an app. Once I find
a file I can click the file in the list of found items and it'll load
in the main window. But what I'd like is to also show that file in
the Project Drawer (since it's hidden somewhere in the hierarchy of
files).
Is this possible?
--
David Orriss Jr.
My blog: http://www.codethought.com/blog
Howdy!
How do I have to set up TextMate for using MATLAB? I have installed the MATLAB Bundle of Thomas Kjosmoen.
http://kjosmoen.org/matlab
Is it now possible to compile MATLAB code directly out of TextMate without opening the code in the MATLAB editor?
Thanks!
Hi
We all know TextMate doesn't have splitting windows. Do people who
want to have splitting windows just right-click the file to open a new
window?
I'd like to ask this question especially for hardcore TDD/BDD'er, who
develop on Rails. I know I can switch between the implementation file
and the test file with one key combination.
Anyway, I'm truly hoping that Allan is winning the ADC this year with
the upcoming version!
Takaaki
--
Takaaki Kato
http://samuraicoder.net
I just recently noticed that if I go to...File...New From Template, Ruby is
no longer present. How do I add it or other templates (such RSpec) into
this sub-menu?
Brad
I wrote a PHP Snippet that outputs some FirePHP-based debugging information.
fb(\$${1:variable}, '${2:function} \$${1:label}');
I would like to replace ${2:function} with something that
automatically puts in the current function or class::method (if
available);
I notice in the status bar at the bottom of the editor window (to the
right of the Tab Size), there is a "Symbol Popup" menu. So it seems
like the information I need is available. Is there a variable in
TextMate that I can slap into the snippet? A $TM_CURRENT_SYMBOL or
something?
Thanks for your help!
Regards,
Daniel Royer