Commit Graph

262 Commits

Author SHA1 Message Date
Jon Rohan
5969e79ebc allow leading dot in extension names in fs resolve 2013-01-22 12:41:33 -08:00
Kevin Sawicki
43d0c8a2a1 Perform extension test once
This does not need to be computed on each path since
file isn't changing between paths visited
2013-01-18 09:14:17 -08:00
Kevin Sawicki
a7f03f4aeb Use __moduleExists from require 2013-01-18 09:08:34 -08:00
Kevin Sawicki
f29c3a0836 Check if module path is already loaded before doing fs operations
resolve now checks the existence of a module already loaded at the
given path before checking if the file exists on disk.

This removes the need for many redundant fs.exists and fs.isFile
calls for already loaded modules.

This speeds up package loading since most packages have a common
set of requires that were doing needless fs operations for each
searched path when the module was already in the cache at that
path.
2013-01-18 08:54:59 -08:00
Kevin Sawicki
78d855e05e Add .tiff to image extensions 2013-01-16 09:11:40 -08:00
Kevin Sawicki
28d4c3749f Use octicon for command panel prompt 2013-01-14 09:32:04 -08:00
Kevin Sawicki & Nathan Sobo
ac3c059246 Extract _.setValueForKeyPath to underscore extensions 2013-01-10 18:02:55 -07:00
Kevin Sawicki & Nathan Sobo
3af97c4e38 Add Event.currentTargetView() and Event.targetView() 2013-01-10 11:41:07 -08:00
Nathan Sobo
2c4da1b8dd Merge branch 'snippets' into dev
Conflicts:
	src/app/package.coffee
	src/packages/snippets/src/snippets.coffee
2013-01-09 13:10:11 -07:00
Nathan Sobo
e33f93b40c Load snippets from TextMate bundles
There's still a bunch of holes in this. TextMate snippets have features
that we don't support yet. But the basic ones should now work.
2013-01-09 11:43:11 -07:00
Kevin Sawicki
fee1e7bc8b Escape ext in RegExp from fs.base 2013-01-08 13:31:37 -08:00
Kevin Sawicki
594813be34 Escape path in RegExp from fs.directory() 2013-01-08 13:30:41 -08:00
Kevin Sawicki
f78adfa060 Add command and invocation counts to header 2013-01-04 16:39:13 -08:00
Kevin Sawicki
b2ec05a2f2 Remove old bundles directory from include paths 2013-01-04 08:18:52 -08:00
Kevin Sawicki
4078046ac6 Vendor textmate bundles as submodules 2013-01-04 08:18:52 -08:00
Nathan Sobo
a9bb4ea163 When loading a package, honor the 'keymaps' manifest in package.json
Also, add a spec to cover the loading of keymaps in `atom-spec` and
reset the `keymap`'s internal data after each spec gets run to prevent
test pollution with keymaps.
2013-01-03 15:17:09 -07:00
Kevin Sawicki & Nathan Sobo
bcde77dd0e Load keymaps from cson
All existing .coffee keymaps are now .cson and package
keymaps are now located in a keymaps folder at the root of
the package.
2013-01-02 16:10:46 -08:00
Kevin Sawicki
183a6d8e8b Add helper for markdown extension to fs 2012-12-31 13:49:40 -08:00
Nathan Sobo
fa7bcfe51b Bundle a themes directory so we don't depend on ~/.atom/themes
We'll look first in the user themes directory, then in the built-in
themes directory. This allows us to default to 'IR_Black' and not crash
if the user doesn't setup their `~/.atom/themes` directory.
2012-12-31 12:08:36 -06:00
Nathan Sobo
9c7c2ab800 Store TM bundle start/end comment strings in scoped properties
Previously, we had a custom method on the `TextMateBundle` class for
retrieving these variables from the bundle. Now we're using Atom's
`syntax.getProperty` mechanism. The idea is to map TextMate concepts
to their Atom equivalent, rather than building everything directly
around TextMate.
2012-12-28 13:27:54 -06:00
Corey Johnson
d77fc88ff4 Merge remote-tracking branch 'origin/master' into config 2012-12-27 10:38:24 -08:00
Kevin Sawicki
ae6039e74d Add octicons to fuzzy-finder
Also place file base name first followed by
directory path in darker color
2012-12-26 20:13:53 -08:00
Nathan Sobo
886995364f Start on syntax global. Use it to replace scoped config settings.
We'll store all syntax-related global state in the `syntax` global. For
now, this means that all scoped properties will be stored here, as well
as all grammars.
2012-12-23 12:50:58 -07:00
Nathan Sobo
8d63805072 Pull out ConfigObserver & Subscriber mixins; Add unobserveConfig 2012-12-19 17:32:04 -07:00
Nathan Sobo
acc0503684 Merge remote-tracking branch 'origin/master' into config
Conflicts:
	src/app/keymap.coffee
	src/extensions/outline-view/src/keymap.coffee
	src/extensions/outline-view/src/tag-reader.coffee
	src/packages/fuzzy-finder/spec/fuzzy-finder-spec.coffee
	src/packages/fuzzy-finder/src/fuzzy-finder.coffee
2012-12-18 20:32:05 -07:00
Nathan Sobo
4ce8583cb2 Rename extensions to packages
We now look at the `core.disabledPackages` config key. Rename the `src/extensions` directory to `src/packages`. The config object now talks about loading packages instead of extensions.
2012-12-18 20:03:21 -07:00
Corey Johnson & Nathan Sobo
e6362af711 Rename subscription.destroy to subscription.cancel 2012-12-14 16:38:04 -08:00
Corey Johnson & Nathan Sobo
b822cd7779 View#subscribe subscribes to an event emitter 2012-12-14 14:40:51 -08:00
Corey Johnson & Nathan Sobo
528fae9466 Cleanup all subscriptions when a view is removed from the DOM 2012-12-14 14:29:20 -08:00
Corey Johnson & Nathan Sobo
55dc3e1cdf Merge branch 'master' into config
Conflicts:
	spec/app/project-spec.coffee
	src/extensions/wrap-guide/src/wrap-guide.coffee
2012-12-14 14:14:50 -08:00
Kevin Sawicki & Nathan Sobo
b91c353d2b Add View#observeConfig as a space-pen extension 2012-12-14 14:08:57 -08:00
Corey Johnson & Kevin Sawicki
a6a05b6ff4 Remove directories from fuzzy-finder 2012-12-12 17:25:45 -08:00
Corey Johnson & Kevin Sawicki
404f637101 Populate fuzzy-finder asynchronously 2012-12-12 12:26:39 -08:00
Nathan Sobo
98ef054438 💄 2012-11-29 12:01:16 -07:00
Nathan Sobo
a6e928d85a Use MessageChannel-based nextTick to schedule Editor display update
This is the fastest way I've found to get the nextTick behavior, which allows us to aggregate multiple requests for display update (from selection changes, cursor movement, line changes) etc into a single call at the end of processing an event.
2012-11-14 13:57:27 -07:00
Corey Johnson
837005176c animation 💄 2012-11-01 15:56:23 -07:00
Corey Johnson
f7f64ea9f3 Only log require.resolve warning when verifyExistence is true 2012-10-29 11:54:13 -07:00
Corey Johnson
bdb0d2c709 Log a warning when require.resolve cannot find the file 2012-10-26 15:36:15 -07:00
Corey Johnson & Nathan Sobo
0aa9f8de57 Indent works with hard tabs 2012-10-26 11:15:55 -06:00
Corey Johnson
f07d15e5ac Fix bug with fuzzy-filter searches using keys. 2012-10-25 11:11:10 -07:00
Corey Johnson
831d23d968 Fuzzy-filter scores basename matches higher.
Idea stolen from github/github https://github.com/github/github/blob/master/app/assets/javascripts/github/tree_finder.js
2012-10-24 15:38:18 -07:00
Corey Johnson
83a72b1d4a :Revert "nobody uses this file"
This reverts commit 5e75edc9e8.
2012-10-24 14:38:56 -07:00
Corey Johnson
5e75edc9e8 nobody uses this file 2012-10-24 14:36:42 -07:00
Kevin Sawicki
906f816fc6 💄 2012-10-23 21:43:43 -07:00
Kevin Sawicki
48bdc75359 Send remaining stdout/stderr output to callbacks
Previously this data was only sent to the done
handlers and so commands such as SelectAllMatchesInProject
were not displaying all the results when the result size
was large.
2012-10-23 21:27:17 -07:00
Corey Johnson & Nathan Sobo
84b2cabeb3 Calling .abortKeyBinding on an event that wasn't triggered by the keymap is ok
Certain events call `abortKeyBinding` to opt out of handling certain keybindings. Snippets does this with tab for example. If it's not a situation where it's appropriate to go to the next tab stop, we let the next binding be triggered, which could insert a tab, for example. But when we trigger events from the event palette, there *is* no next binding. Having a no-op function helps in this situation.
2012-10-19 12:42:27 -06:00
Corey Johnson & Nathan Sobo
191164ed4c Add $.fn.command method which ensures event is documented
For now, we auto-generate the documentation string by humanizing the event name. In the future, we may provide the option to provide more documentation, such as info about any arguments to the event, extended documentation, etc.
2012-10-19 12:14:02 -06:00
Corey Johnson & Nathan Sobo
d420585b11 Display keybindings in EventPalette. Style a bit. 2012-10-19 12:02:00 -06:00
Corey Johnson & Nathan Sobo
de3bbce29f Only show events w/ descriptions in EventPalette
Also, auto-generate human readable event name in editor. This is a good example of how we could do this automatically for some kind of `onCommand`, `command`, `onInteractiveEvent` method that combines the event name, documentation string, and handler in one shot.
2012-10-19 11:24:40 -06:00
Nathan Sobo
2b8c946a65 Merge branch 'master' into event-palette
Conflicts:
	spec/extensions/fuzzy-finder-spec.coffee
	src/extensions/fuzzy-finder/fuzzy-finder.coffee
2012-10-18 16:33:44 -06:00