[TxMt] Re: PHP debug workflow suggestions

feek feekdiv at gmail.com
Fri May 6 13:15:07 UTC 2016


Hi,

because I post via Nabble.com, I see that my TM-command did not show up in
the e-mail:

=== Code

#!/usr/bin/env bash

[[ -f "${TM_SUPPORT_PATH}/lib/bash_init.sh" ]] && .
"${TM_SUPPORT_PATH}/lib/bash_init.sh"

# Open current file on current line in VIM in a iTerm session 

osascript << END
if application "iTerm" is running then
	-- iTerm is running
	if (count windows of application "iTerm") is 0 then
		-- NO window is found
		tell application "iTerm"
			set newWindow to (create window with default profile)
			tell current window
				tell current session
					write text "vi +$TM_LINE_NUMBER \"$TM_FILEPATH\""
				end tell
			end tell
		end tell
	else
		-- Window(s) Found
		tell application "iTerm"
			select first window
			tell current window
				set newTab to (create tab with default profile)
				tell current session
					write text "vi +$TM_LINE_NUMBER \"$TM_FILEPATH\""
				end tell
			end tell
			--set newWindow to (create window with default profile)
		end tell
	end if
else
	-- iTerm is NOT running
	tell application "iTerm"
		activate
		tell current window
			tell current session
				write text "vi +$TM_LINE_NUMBER \"$TM_FILEPATH\""
			end tell
		end tell
	end tell
end if
END

=== END CODE

also see
http://textmate.1073791.n5.nabble.com/PHP-debug-workflow-suggestions-td29945.html



--
View this message in context: http://textmate.1073791.n5.nabble.com/PHP-debug-workflow-suggestions-tp29945p29969.html
Sent from the textmate users mailing list archive at Nabble.com.


More information about the textmate mailing list