7 ms·
Use OSX Finder Quicklook (Spacebar) to preview all plain text files
- magoon 14y agoThis is so good
- rover 14y agoisn't it ? made me a happy person :)
- pooriaazimi 14y agoMore QuickLook plugins: http://www.qlplugins.com http://www.qlplugins.com http://www.quicklookplugins.com http://www.quicklookplugins.com This one is my favorite: http://macitbetter.com/BetterZip-Quick-Look-Generator/ http://macitbetter.com/BetterZip-Quick-Look-Generator/
- rover 14y agoHey, thanks a lot. Didn't know about these at all. Cheers.
- rover 14y agoBetterZip is really good. Thx.
- patrickg 14y agoThis is my favorite: http://lallafa.de/blog/c64-projects/d64qlplugin/ http://lallafa.de/blog/c64-projects/d64qlplugin/
- 5teev 14y agoFor iOS developers, this one reveals a lot of useful information about provisioning profiles: http://www.macmation.com/blog/2011/10/quicklook-plugin-for-mobile-provision-files/ http://www.macmation.com/blog/2011/10/quicklook-plugin-for-m...
- mtr 14y agoOn a related note, is there any way to get Spotlight to index all text files?
- rover 14y agoI wouldn't know why you'd want to do so(slowing down the search), but it seems possible (or close enough). Scroll at the way to "Make Spotlight index source code" here. http://www.macosxtips.co.uk/index_files/terminal-commands-for-improving-spotlight.php http://www.macosxtips.co.uk/index_files/terminal-commands-fo...
- Groxx 14y agoThat assumes you care about the speed more than the results. Quicksilver or Alfred completely replace Spotlight for anything frequent; I'd be happy if it took 5 minutes, if it could always find what I was looking for.
- tilltheis 14y agoThe command line version of it (mdfind) seems to search the entire file system.
- deleted 14y ago[deleted]
- pstadler 14y agoNice plugin! Pro tip: Instead of restarting finder run `qlmanage -r`
- rover 14y agoSweet !
- deleted 14y ago[deleted]
- hcarvalhoalves 14y agoAs always... simple hacks, the best hacks!
- rover 14y ago:)
- redog 14y agoIs there such thing as plain text?
- rover 14y agowell... :)
- matthijs 14y agoWould it be possible to make the text inside the Quicklook window selectable? I often just want to quickly copy something from a file, and Quicklook would be the fastest way to do so.
- deleted 14y ago[deleted]
- Watabou 14y agoYes there is a way. Open up terminal and type this in: defaults write com.apple.finder QLEnableTextSelection -bool true Then restart the Finder by typing in this into the Terminal: killall Finder
- Groxx 14y agoWhy isn't this the default...? Many thanks :)
- johnpowell 14y agodefaults write com.apple.finder QLEnableTextSelection -bool TRUE; killall Finder
- rover 14y agoawesome !
- rasmus_b 14y agoCode syntex highlight http://code.google.com/p/qlcolorcode/ http://code.google.com/p/qlcolorcode/
- Watabou 14y agoNow that is just awesome. Thank you!
- rover 14y agobeware though. might not work after latest XCode installation
- Watabou 14y agoI don't have XCode installed as of yet. I'm on Mountain Lion and I'm waiting for both the official release of ML and XCode on the App Store. Will XCode for ML still interfere with this plugin or is there any other plugin with similar functionality?
- rover 14y agowell, i don't really know.
- Zirro 14y agoI'll take the opportunity to ask: Is there a way to make Spotlight index files in the Library folders? There are sometimes some obscure preference or cache-files that I need to find.
- Thomvis 14y agoTo my knowledge it does index those files, they are just not shown in the search results. You can ask Spotlight to show the system files, see this guide: http://support.apple.com/kb/HT4355 http://support.apple.com/kb/HT4355
- rover 14y agoYou'll definitely find what you're looking for here. http://www.macosxtips.co.uk/index_files/terminal-commands-for-improving-spotlight.php http://www.macosxtips.co.uk/index_files/terminal-commands-fo... To save you some time, add a folder as follows: mdimport -f /Library
- jasomill 14y agoOn recent OS X versions (Lion at the very least), the problem isn't that /Library and ~/Library aren't indexed by default; they are. Trouble is that if I search for a file named, say "com.apple.RemoteDesktop.plist", Finder appears to run a query akin to kMDItemDisplayName == "com.apple.RemoteDesktop.plist" && kMDItemSupportFileType != MDSystemFile which returns nothing on my system, rather than simply kMDItemDisplayName == "com.apple.RemoteDesktop.plist" which returns three results, one each in subdirectories of /System/Library, /Library, and ~/Library. There's an option in the "full" Spotlight search window that lets you control this for any given search, under "Other..." in the drop-down you get when you click "+" to add criteria. It's called, logically enough, "System files". Incidentally, the mdfind command line tool doesn't have this behavior by default.
- gloubibou 14y agoIf you want a nice GUI, try Tembo (http://www.houdah.com/tembo http://www.houdah.com/tembo). Tembo is a Spotlight front-end. Incidentally it searches all indexed locations, including Library folders.
- miles 14y agoSuspicious Package http://www.mothersruin.com/software/SuspiciousPackage/ http://www.mothersruin.com/software/SuspiciousPackage/ is another neat QuickLook plugin that displays detailed information about Installer Packages (.pkg files).
- rover 14y agoYeah, it's pretty sweet.
- backwardm 14y agoYou can also add a QuickLook directory to your own ~/Library if you are into keeping stuff separated.
- pstadler 14y agoSomehow off topic but this is a very neat trick: You can preview the selected item directly in the Spotlight menu by pressing the left arrow key. Source: http://www.macstories.net/mac/all-you-need-to-know-about-quick-look-in-lion-plus-some-handy-tips-and-tricks/ http://www.macstories.net/mac/all-you-need-to-know-about-qui...
- rover 14y agocool stuff !
- jkbr 14y agoIMO the preview appears automatically after ~2 seconds without having to press any key. Useful feature indeed.
- pstadler 14y agoI guess you're right. Though I never recognized this before and since I'm using Alfred, I don't touch Spotlight that often.
- skinnymuch 14y agoOn mobile device right now, but earlier today Alfred prompted for a beta update which included some Spotlight features. Not sure about the details or if it's only part of the paid Powerpack
- city41 14y agoSadly what it does and does not preview seems to be pretty random. For me with Lion it will preview Rakefiles and .txt files for example, but not .js files.
- miggaiowski 14y ago.org files =)
- aes256 14y agoThanks so much for this. For the longest time I've found it irritating that I couldn't preview plaintext .nfo files with Quicklook. I didn't realise Quicklook plugins were a thing...
- rover 14y agowell, so did i. Irritation is the root of all hacks :)
- SmileyKeith 14y agoThis is fantastic. Always wondered why quick look wasn't set up to parse plain text files just because they had a different extension. Especially Markdown.
- 205guy 14y agoSo now opening a text file is "cutting edge?" [1] [1] http://news.ycombinator.com/item?id=4226539 http://news.ycombinator.com/item?id=4226539 PS, just like clicking "More" on HN front page after reading a few articles results in a "cutting edge" error.
- lorrin 14y agoAnyone know how to control what the Open with button offers? E.g. it's offering "Open with Sublime Text 2" and I'd rather have an Open with MacVim.
- rover 14y agoIt's pretty simple and managed by OSX. - Select a filetype you'd want to change the default application for and open the File Info (Cmd+I) - In the "Open with" section, select the app you want to be the default app for the filetype - To persist the default app along the whole filetype, also click the "Change All" button right below it.
- Watabou 14y agoYou can also hold down the open button and a list of alternate applications that can be used to open the document drops down. Pretty handy.
- thought_alarm 14y agoThat's up to the application. You can crack open the app packages for Sublime Text and MacVim and see how their Info.plist files differ. It's also worth looking at the Info.plist for TextEdit, which has a catch-all for all non-executable files.
- jaylevitt 14y agoI bet RCDefaultApp will work: http://www.rubicode.com/Software/RCDefaultApp/ http://www.rubicode.com/Software/RCDefaultApp/
- vito 14y agoIs there something like this for Chrome? Really annoying having code downloaded instead of displayed.
- halostatue 14y agoSort of. Some of it will be controlled by the website more than anything else, but anything that comes over ultimately as text/plain can be handled nicely by Sight: https://chrome.google.com/webstore/detail/epmaefhielclhlnmjofcdapbeepkmggh https://chrome.google.com/webstore/detail/epmaefhielclhlnmjo...
- nikcub 14y agoNo. It has to be sent as text/plain for Chrome to view the file if it is on a remote server. The MIME types that are opened in the browser instead of downloaded are hardcoded within the Chrome source. Numerous feature requests have been submitted[1] to update this functionality and to provide a preferences pane for users to decide how they want different file types handled, but they have been ignored as this behavior is a design decision. [1] http://code.google.com/p/chromium/issues/detail?id=118204&thanks=118204&ts=1331749873 http://code.google.com/p/chromium/issues/detail?id=118204...
- uladzislau 14y agoIs there any way to change the font or its size in Quicklook?
- zwass 14y agoFile this under things that should have worked in the first place.
- shellox 14y agoIt's possible to get syntax highlighting working with it?