textmate

Django - Mac OSX Workflow - Questions on efficient development methodologies

ぐ巨炮叔叔 提交于 2019-12-03 06:25:21
问题 I am going to outline my workflow and I would like some suggestions on how to improve the efficiency of this. It seems right now a bit cumbersome and repetitive (something I hate), so I am looking for some improvements. Keep in mind I'm still new to django and how it works but I'm a pretty fluent coder (IMHO). So here goes... Tools (I use these everyday so I'm not inclined to shift) : Mac OSX Leopard TextMate Terminal w/tabs Perforce Assumptions Django Basics (Did the tutorials/bought the

Regex to replace values that include part of match in replacement in sublime?

核能气质少年 提交于 2019-12-03 05:30:41
问题 I've come up with this regex that finds all words that start with $ and contain _ underscores: \$(\w+)_(\w+) I'm basically searching for variables, like $var_foo etc. How do I replace stuff using the regex groups? For example, how can I remove the underscore and make the next letter uppercase, like $varFoo ? 回答1: The replacement expression is: \$\1\u\2 \1 , \2 are the captures (or $1 , $2 ) \u up-cases (see the Replacement String Syntax section). See the Regular Expressions chapter (in the

how to move the textmate file explorer to the right side?

跟風遠走 提交于 2019-12-03 05:25:01
how to move the textmate file explorer to the right side? You can move textmate to the left edge of the screen and close and open the panel. ie. ctrl, alt, cmd + d. For Textmate 2 (released long after this question was answered) the accepted answer doesn't appear to work anymore. This is what did it for me: To change it to the right on OSX, open up your terminal and run the command: defaults write com.macromates.TextMate.preview fileBrowserPlacement right To change it to the left: defaults write com.macromates.TextMate.preview fileBrowserPlacement left If you're not using ProjectPlus by Ciarán

VIM: RSync on save

大城市里の小女人 提交于 2019-12-03 03:43:50
I'm looking for a way to map the :w command so that when I use it, it will rsync the current directory and save the file in question. Ideally, the response generated by the rsync command should be returned in vim, but not in the the current file, but rather as a tooltip or something. I managed to achieve this in TextMate and am now looking to start working with Vim. I've been trying things like :map w :w|!rsync . but that doesn't seem to work (I'm a beginner :)) I'd appreciate any help. Thanks, Joe You can hook into BufWritePost. I don't remember the exact syntax, but " :he BufWritePost " and

Where to find a list of scopes for Sublime2 (or textMate?)

自古美人都是妖i 提交于 2019-12-03 01:50:53
问题 in .tmTheme files the scope key defines how a element is highlighted: <dict> <key>name</key> <string>HTML: Attribute Values</string> <key>scope</key> <string>meta.tag string.quoted, meta.tag string.quoted constant.character.entity</string> <key>settings</key> <dict> <key>background</key> <string>#FFFFFF</string> <key>fontStyle</key> <string></string> <key>foreground</key> <string>#2aa198</string> </dict> </dict> where can I find a list of all scopes supported by these apps, so I can create my

TextMate Grammar ― precedence of rules

匿名 (未验证) 提交于 2019-12-03 01:05:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm trying modify syntax highlighting for CSharp language, so I will get syntax highlighting for SQL in C# string. TextMate has support for embeded languages, so this seems possible. I build on csharp.tmLanguage.json and I would like to be able to enable embeded SQL with special comment before string like string query = /*SQL*/ $@"SELECT something FROM ..." Thanks to TextMate's Language Grammars and Introduction to scopes I came up with this JSON rule "repository": { "embeded-sql": { "contentName": "source.sql", "begin": "/\\*\\s*SQL\\s*\\*/

Textmate/Regex: Strip whitespace from beginning/end of file

只愿长相守 提交于 2019-12-03 00:51:22
I'm trying to add a macro/command to Textmate for some file cleanup and the last tidbit I haven't figured out is simply to remove blank lines from the beginning and end of a file -- does anyone know how to do this? I know some Textmate or regex trick must exist, just not sure what... For the tasks you mentioned, you can use built-in commands from the "Text" Bundle. Even if you just want to script your own, i would suggest using these as templates for your own efforts. To access these: Removing Trailing Spaces: ctrl-cmd-t to bring up the context-sensitive Bundle menu begin typing "remove

What are some useful TextMate shortcuts? [closed]

雨燕双飞 提交于 2019-12-03 00:04:41
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 7 years ago . Macs are renowned (or bemoaned) for having an extensive number of shortcuts. However, OS X itself pales in comparison to the shortcut

Django - Mac OSX Workflow - Questions on efficient development methodologies

你。 提交于 2019-12-02 20:58:36
I am going to outline my workflow and I would like some suggestions on how to improve the efficiency of this. It seems right now a bit cumbersome and repetitive (something I hate), so I am looking for some improvements. Keep in mind I'm still new to django and how it works but I'm a pretty fluent coder (IMHO). So here goes... Tools (I use these everyday so I'm not inclined to shift) : Mac OSX Leopard TextMate Terminal w/tabs Perforce Assumptions Django Basics (Did the tutorials/bought the books) Python Fluent (running 2.6 with IDLE Support) Starting my first Application working on models.py

“Sort Lines in Selection” for Xcode 4

被刻印的时光 ゝ 提交于 2019-12-02 19:15:19
I like Textmate's "Sort Lines in Selection" feature a lot. Is there something similar for Xcode 4? If not, what would be the best way to integrate such a feature (a plugin, Applescript, ...)? You can do this with Automator in Lion. Start Automator and select "Service" Find and drag "Run Shell Script" into the workflow panel Select "Output replaces selected text" Type sort -f into the "Run Shell Script" textfield Save Now you can sort lines in any textfield. Select some text and right-click or Control click and select the service you just created. After 4 years Xcode still doesn't have this