We finally did it. I submitted a PHP Drupal for Textmate and it is now listed at http://macromates.com/svn/Bundles/trunk/Review/Bundles/. The bundle primarily consists of work by kkaefer. I've also added bits that have been posted by others over time.
To install, see the Bundles page of the macromates wiki.
Lets improve the bundle. This group is the right place for general discussion about it (Textmate specific RSS feed). I created a Textmate project at drupal.org for discussing patches, bug reports, feature requests.
As for next steps with Macromates - here is the reply from Michael Sheets ....
I've added the PHP Drupal bundle to the review directory. The next step is get feedback from the community on the bundle before it's inclusion in the main Bundles directory in the repository. Generally these will be posted to the tm-dev list, some of the core bundle contributors may give their comments in the form of a comments.markdown document in the root of the bundle as to easily track the comments.
After a suitable amount of time and any issues have been addressed the bundle can be promoted to the main Bundles directory.
Sorry you thought the need the justify the bundle, we've got room for any languages no matter how small or big. As long as someone writes it we'll add it to the repository. I'll be adding some review comments when I can, until then keep up the good work.
Need from you the subversion username you'd like so I can setup a account for you to update the bundle.
Thanks for your contribution!
--
Michael Sheets
TextMate Bundles Moderator
Comments
I've been working on a
I've been working on a Drupal TextMate bundle recently and you seem to have beat me to it. I've seen you talk about the need for a Drupal bundle for a while and just checked this morning to see if one had been added to the bundles repository. Anyway, I'm up for helping to make this bundle the best it can be.
Going to install it now and see what it provides.
fs.io
drupalcontrib.org
This Bundle is certainly the
This Bundle is certainly the start of something amazing for us TextMate users!
TM_drupal_version should be TM_DRUPAL_VERSION for consistency.
I'd like to know how you feel about integrating the current hook_* tab triggers with Steven Wittens' function completion. The main PHP bundle does function completion using option+escape, it gives an option list to choose a function. I've been working on getting this same functionality with Drupal functions generated by Steven's generate.php.
The generator Steven created makes autocomplete snippets for functions within contributed modules. When doing a look-up using Wim Leers' api.drupal.org command the contrib functions are not found. API module allows documentation for contributed module functions. These two combined could allow the documentation look-up of the contributed functions from a local API.
Would love to know your thoughts on these.
fs.io
drupalcontrib.org
I have the Bundle doing a
I have the Bundle doing a look-up on my local API and it's working for functions from within contributed modules too. I added a new Shell Variable called TM_DRUPAL_API and set it to: http://api.drupal.org/apis/
if grep <<<${TM_CURRENT_WORD:-!} -Esq '^[a-zA-Z0-9_]+$'
then
FILENAME=${TM_FILEPATH##/}
BASENAME=${FILENAME%%.};
if [
echo "$TM_CURRENT_WORD" | grep -E "${BASENAME}_[0-9A-Za-z_]"
]then
HOOK=${TM_CURRENT_WORD##${BASENAME}}
URL="${TM_DRUPAL_API}${TM_DRUPAL_VERSION}/hook${HOOK}"
else
URL="${TM_DRUPAL_API}${TM_DRUPAL_VERSION}/${TM_CURRENT_WORD}"
fi
exit_show_html "<meta http-equiv='Refresh' content='0;URL=$URL'>"
else echo "Nothing to lookup (hint: place the caret on a function name)"
fi
This makes the API location flexible so you can use your own local API. Mine is set to: http://localhost/api/apis/ where api is the name of my local API site.
fs.io
drupalcontrib.org
I was using all uppercase
I was using all uppercase for TM_drupal_version but I thought to use lowercase afterreading the variables section of http://wiki.macromates.com/Bundles/StyleGuide. I think uppercase is the call though. Should we use TM_PHP_DRUPAL_VERSION so we get the nundle name in there?
I really want autocomplete and snippits for Drupal functions. But Steven's implementation is too odd for my taste. I don't want to generate .plist files. I'm not even sure the user should generate anything. We might just make a collection of frequently used modules (FM) and ship their functions in the bundle. In other words, myself and kkaefer (the bundle maintainers) run 'generate' from time to time to pickup new functions and add them to the bundle. I think we should hook into the PHP completion that exists already. We might just append our list of functions to the PHP function list and add our snippits somehow. I have investigated this at times but never found a solution that I liked. But this has to be the top priority so lets get to it people ...
TM_PHP_DRUPAL_VERSION would
TM_PHP_DRUPAL_VERSION would be the way to go, saves any confusion since, as you say, it contains the bundle name.
I've been trying to hack Ciaran's PHP Bundle's Completions command to work with a modified version of Steven's generate.php. I can get a list of options just like the PHP bundle completion: type 'theme_' then Option+Escape to see all functions starting with 'theme_'. The problem I'm having is that the prototype isn't expanding correctly. Ciaren kindly gave me a script that should help but I'm new to Ruby so I've been finding it hard to get working properly.
I'll post here when I get further with it.
fs.io
drupalcontrib.org
Exciting news about PHP completion
I was in #textmate today and caught wind of a new PHP Completion effort by Ciarán Walsh. It does what we all hoped - function/method completion based on the files in the current project. The module stores function/method info in a SQLite database. The bundle currently only parses .php files. I fiddled with Ruby and git like a semi blind person until i managed to publish my own fork which also parses .module and .inc files. I already submitted a patch (aka 'pull request') to Ciarán.
I consider Steven's bundle to now be obsolete and we'll use this new bundle as our completion solution for Drupal.
So what is the next priority for our little bundle? D6? More hooks?
The fork seems to have been
The fork seems to have been removed at this point. Has your changed been merged into the main trunk for PHP Completion? I tried looking through recent commits and couldn't tell from the comments.
Thanks!
Shrop
php completion
BTW.. I do think that having auto complete of functions for installed modules. If it makes most sense to leverage the work in PHP Completion, then that works for me :)
Thanks for all of your work on this!
Shrop
Thanks Moshe
As a TM user I'm happy to see this.
I've started testing and playing with it.
Thanks.
More snippets
Sweet! I actually released a small set of snippets that I have been using for the past few months, its not a complete package but there are form api and menu array helpers that are pretty useful (you can watch the demo to see how they work http://boldsource.com/tutorials/drupal-helper-textmate-bundle-screencast). Feel free to include the snippets in this new 'master' package.
http://boldsource.com/downloads/drupal-helper-textmate-bundle
Blake
Thanks for the link. Please
Thanks for the link. Please review the bundle from SVN and create a patch or a small bundle with your proposed additions. Post to Textmate project ... Try to maintain the naming conventions of the SVN bundle. Keep refreshing your checkout since the bundle will change frequently in its early days. Thanks.
Haven't even heard of
Haven't even heard of textmate, looks fairly primitive but I have a macbook now so I will have to check it out! not sure I could live without phped though
vision media
350designs
Print Huge Edmonton Printing Services
Design Inspiration Gallery
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
I did heard of textmate but
I did hear of textmate but since the beginning I used bbedit. However, I did try textmate with this bundle after reading this and I'm already on it. No more bbedit! Long live to textmate and Drupal bundle!
I really like the Drupal community....
Robert Garrigós
Professional site: garrigos.cat
Robert Garrigós
Professional site: garrigos.cat
How is the FTP/SSH support?
How is the FTP/SSH support? PhpED has alot of great features I could not live without, but I am sure some other IDE's incorporate them as well. Namely: integrated terminal, ftp/sftp, instant php function/class help & search, profiling, debugging module, db client, etc
vision media
350designs
Print Huge Edmonton Printing Services
Design Inspiration Gallery
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
FTP suggestion
If you can localhost debug with textmate I'd be impressed, but fwiw I'll drop a suggestion about FTP.
I highly recommend Cyberduck for nice GUI FTP that integrates nicely. When you tell Cyberduck that Textmate is your default editor, it gives you a textmate edit button. When you save with textmate it will then save back to server via Cyberduck.
Another advantage of Cyberduck is integration with lots of other text editors. For me, this means I can do quick setup on other people's Macs with a free combination like Cyberduck/TextWrangler. It's a nice non-techie setup.
Steven?
How this is related to http://acko.net/blog/updated-drupal-textmate-bundle ?
We are discussing how to
We are discussing how to incorporate drupal function complete in another comment branch of this same post. We all surely want it, but Steven's solution is not ideal IMO. The PHP bundle now has function completion and we need to tie into that somehow.
Would be nice to have some
Would be nice to have some quick hook completion functionality, or perhaps even a wizard sort of functionality. At the moment I just use a combination of code templates (CTRL + J, pick one and bam) and auto replace functionality so if type mmd it turns into dpm() ( mmd is faster for me to type ), mmm turns into a menu hook, mmf turns into a formAPI array, mmi turns into an install hook template etc
vision media
350designs
Print Huge Edmonton Printing Services
Design Inspiration Gallery
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
I just downloaded the trial,
I just downloaded the trial, does it not support FTP/SFTP/SSH? what do you guys use for this on the mac? My IDE on the windows end has been the ONLY reason that I have held of from migrating over to the mac entirely, PhpED is a very tight package though so I am second guessing what I have found for the mac so far :(
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
If you're used to the FTP
If you're used to the FTP way of working then Transmit 3 is a good option (although it's not free).
You could use ExpanDrive if you prefer navigating the file system using Finder.
I used ExpanDrive until the demo ran out and now just use Transmit until I find something better.
fs.io
drupalcontrib.org
Anything integrated with
Anything integrated with textmate? I hate having tons of separate clients, I have been leaning towards going with Eclipse for debugging and ftp etc but textmate is certainly cleaner
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
FTP/SSH Bundle
You're not alone. This has been discussed a bunch of times on the TextMate mailing list.
Check out the FTP/SSH Bundle. I've been thinking of using it but I keep going back to using MacFUSE.
This will come in the much
This will come in the much anticipated TextMate 2.0. For now I'm happy to use the other options.
I generally do everything in my local environment anyway so this is less of an issue for me.
fs.io
drupalcontrib.org
No debugging either correct?
No debugging either correct? The bundles look pretty elaborate as far as what can be accomplished but im not sure about what is available. I installed Eclipse as well and its a beast already haha so slow in comparison to what I normally use.
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
That's right, no debugger. I
That's right, no debugger. I have never used a debugger in my life, they seem a bit clunky to me. I just manually print (using functions provided by devel module) the data I need to see.
There are so many features in TextMate that it's hard to say what you'll find most useful.
Freestyle Systems
Drupal Contributions API
fs.io
drupalcontrib.org
The bundles seem really
The bundles seem really robust I really like what they have done with that, thats the main reason I am really interested in where it is now and where it will go in the future. Debuggers are really handy, I use them somewhat rarely but its defiantly something I am not ready to give up all together. A few things I noticed that it didnt seem to have (that i know of) was:
There were a few more I cant think of, like I said though totally stoked on where its going! Eclipse is slow and seems like a worse choice in the long run but for right now I might stick with it.
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Terminal(s) You can run
freestylesystems.co.uk
Drupal Contributions API
fs.io
drupalcontrib.org
Thanks for all the info man,
Thanks for all the info man, sounds like its working good for you guys so I have to dive deeper and see how things are done on this OS :)
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
API Version for this bundle
Is this bundle only for D6 or will much of the snippets work in D5? Is there an easy way to tell?
Thanks!
Shrop
I'm considering creating the
I'm considering creating the theme extension to this bundle.
We have the ability to see which version of Drupal we're currently working on so I propose that we use this logic to insert the theme snippets for the version required.
I have already created theme_regions and theme_links to make sure I know how to do this.
http://pastie.textmate.org/private/9y46e41mgdcy3xtinervbq
http://pastie.textmate.org/private/0rzjlxf7nvdqnxh6lrdyba
You can add these as commands and use the following settings:
Input: None
Output: Insert as Snippet
Tab Trigger: theme_regions and theme_links respectively
Scope Selector: source.php
This will give you the ability to type theme_regions, press tab and you will have a fully formed theme_regions function inserted as a snippet.
I think this is pretty useful but wanted to find out if others would also find this a useful addition to the PHP Drupal bundle. Let me know your thoughts.
fs.io
drupalcontrib.org
Looks good. I would love to
Looks good.
I would love to have common theming functions added to the bundle.
I have hundreds of commands
I have hundreds of commands / snippits that I added, will contribute them ASAP. Even wrote a quick bash script to 'jump' to a function declaration within the project in other files.
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Tj Holowaychuk
Vision Media - Victoria BC Web Design
Victoria British Columbia Web Design School
Drupal 6.x
I'm going to work on updating the bundle now.
Does anyone have anything before I go ahead and do work you've already done?
Drupal Contrib API | #drupaluk IRC channel | Freestyle Systems
fs.io
drupalcontrib.org
Textmate SVN repository location
The repo location has changed to:
The SVN repo has changed location. Here is the current location:
http://svn.textmate.org/trunk/Review/Bundles/PHP%20Drupal.tmbundle/
Drupal Contrib API | #drupaluk IRC channel | Freestyle Systems
fs.io
drupalcontrib.org
Does anything else need to
Does anything else need to be done to install the textmate bundle other than setting TM_DRUPAL_VERSION and TM_DRUPAL_API shell variables inside textmate prefs? I keep getting an error "The PHP Drupal Bundle is not installed properly" when I use tab triggers with bundle from svn…
Same error
I Get the same error: "The PHP Drupal Bundle is not installed properly". I have set the both TM_DRUPAL_VERSION and TM_DRUPAL_API shell variables.
I upgraded to Snow Leopard a few weeks ago. Maybe this is the culprit?
Kim
PreviousNext
http://www.previousnext.com.au
Yes, there was an issue that
Yes, there was an issue that mikejoconnor submitted a patch for where the TM_VARIABLES where in the wrong $_SERVER or $_ENV. His patch checks both locations and should fix the problem. Either do an svn up or delete and grab anew from github.
http://github.com/psynaptic/php-drupal.tmbundle
fs.io
drupalcontrib.org
tortoisesvn not working
Hi guys,
Thanks for this.
tortoisesvn on windows vista is failing for me when I try to "svn checkout" the drupal bundle.
Is there a tar.gz or zip file I can download somewhere?
Thanks
Development has moved to GitHub
Just to let everyone know, I have today migrated development of the PHP Drupal TextMate bundle to GitHub!
It's time to update your bundles!
http://github.com/psynaptic/php-drupal.tmbundle
fs.io
drupalcontrib.org
Quick installation instructions
Just a quick and simple way (using the command-line) to install the Drupal textmate bundle.
Taking a ZIP / tar.gz out of GitHub will extract as a directory which is useless.
Just run in Terminal.app:
mkdir ~/Library/Application\ Support/TextMate/; mkdir ~/Library/Application\ Support/TextMate/Bundles/
cd ~/Library/Application\ Support/TextMate/Bundles/
git clone git://github.com/psynaptic/php-drupal.tmbundle.git
Should look something like this if it hasn't gone pear-shaped:
For those who simply want the .tmbundle...
Actually, it's easy to make the directory work... e.g. If I go to the download page for the Drupal .tmbundle, and download and extract the archive, I currently get a directory named: psynaptic-php-drupal.tmbundle-0d64d4e
If you rename that to simply: php-drupal.tmbundle (assuming you have Textmate installed), your system will recognize it as what it is: a Textmate Bundle. Double-clicking it will now automatically install it in Textmate and open it in Textmate's Bundle Editor, just as with any other Textmate Bundle.
This means that those of us who are just getting into Drupal development can get the latest release of this .tmbundle to work with, even before mastering the use of Git. ;-)
About me: