Nathan Sobo
e723b26eb0
Add maximumLength schema enforcer for strings
2015-06-01 18:45:38 +02:00
Nathan Sobo
b68902dd83
🎨
2015-06-01 18:45:38 +02:00
Nathan Sobo
d1c44dcb54
Never load config settings from disk when a save is pending
...
Fixes #5771
We load the user’s settings from disk when we detect a change to their
config.cson file. However, if there’s a save pending, doing this will
end up blowing away the values we intend to save.
2015-04-20 12:12:05 -06:00
Nathan Sobo
96b0938c7c
🎨
2015-04-20 12:12:05 -06:00
Kevin Sawicki
4160a8c239
Merge pull request #6230 from mnquintana/coffeelint-plus
...
Lint for more styleguide errors
2015-04-08 12:07:23 -07:00
Kevin Sawicki
06b8195fb8
Remove template config.cson file
...
This old template file had several problems:
* The entries in this file are already the schema defaults so they
would get unset anyway when initially loaded
* The file was in the old format that didn't have scope selectors
* A race condition could occur when the file was copied, inited, and written
to all during the very first run of Atom.
Closes #6226
2015-04-07 11:47:36 -07:00
Machiste Quintana
5d2392ea67
👕 Fix new coffeelint errors
2015-04-06 23:59:54 -04:00
Kevin Sawicki
30419027a8
Show notification on config save failures
2015-02-05 15:34:17 -08:00
Ben Ogle
7263ca8faa
🎨 Fix spec title
2015-01-29 17:54:41 -08:00
Ben Ogle
083bafdb33
Handle unschema’d items in objects.
...
This is required for packages that still use configDefaults
2015-01-29 17:54:41 -08:00
Ben Ogle
26b450fe49
🎨 Clean up spec naming
2015-01-29 17:54:41 -08:00
Ben Ogle
5d273d0ee6
Add a bit more coverage to the specs
2015-01-29 17:54:41 -08:00
Ben Ogle
b9b2b4bca2
Adhere to the schemas when loading the user’s config
2015-01-29 17:54:41 -08:00
Ben Ogle
79094ee889
Reset all user config values when the schema changes.
2015-01-29 17:54:40 -08:00
Kevin Sawicki
63335f6b60
Return Color object when in cloned objects
...
This adds a custom deepClone that clones any Color objects
correctly.
2015-01-22 10:48:07 -08:00
Max Brunsfeld
0a59d13d56
Fix Config::unset with no scope-selector
...
Closes #5095
2015-01-16 10:23:12 -08:00
Ben Ogle
1bc2248fc2
Fix config specs
2015-01-14 16:15:53 -08:00
Kevin Sawicki
640f8920fb
Fix bounds checking of alpha
2015-01-12 17:34:43 -08:00
Kevin Sawicki
44939a12a0
Validate color properties when set
2015-01-12 17:34:43 -08:00
Kevin Sawicki
b8822b32db
Only coerce strings and plain objects
2015-01-12 17:34:43 -08:00
Kevin Sawicki
8c39818670
Don't blow up when asking for schema at non-existent path
2015-01-12 17:34:43 -08:00
Kevin Sawicki
5a2c208804
Add specs with invalid objects
2015-01-12 17:34:43 -08:00
Kevin Sawicki
fc899f54cf
Add specs for setting with an object
2015-01-12 17:34:42 -08:00
Kevin Sawicki
b923b57bcc
Add specs for hsl and hsla colors
2015-01-12 17:34:42 -08:00
Kevin Sawicki
319ec244e1
Add spec for invalid values
2015-01-12 17:34:42 -08:00
Kevin Sawicki
1267a1e14e
Add spec for default color value
2015-01-12 17:34:42 -08:00
Kevin Sawicki
0411f1584c
Add color schema type
2015-01-12 17:34:42 -08:00
Nathan Sobo
304f63532e
Replace ‘global’ config key with ‘*’ selector
2014-12-30 13:38:12 -06:00
Max Brunsfeld
6e7364c7c6
Merge pull request #4802 from atom/mb-reduce-config-saves
...
Don't write the config to disk so darn often
2014-12-30 10:41:01 -08:00
Max Brunsfeld
339f331776
Debounce saving and loading of config
2014-12-30 10:14:57 -08:00
Max Brunsfeld
5c730415b7
Use fake config file for entire Config spec
2014-12-30 00:03:34 -08:00
Max Brunsfeld
637b2b0aba
Don't save config when setting w/ non-default source
2014-12-29 17:08:26 -08:00
Max Brunsfeld
c7771ffde9
Add Config::getAll, deprecate ::settingsForScopeDescriptor
...
Signed-off-by: Nathan Sobo <nathan@github.com >
2014-12-29 11:01:46 -08:00
Max Brunsfeld
d508d1eedf
Handle a source but no selector in ::unset
2014-12-26 17:24:27 -08:00
Max Brunsfeld
2949ebfe86
Deprecate Config::addScopedProperties
2014-12-26 17:13:33 -08:00
Max Brunsfeld
dbaef8e593
Handle null key-path in Config::set
2014-12-26 14:58:17 -08:00
Max Brunsfeld
b4b492a321
💄 Organize config-spec
...
* Group tests by method rather than by scoped vs unscoped
* Group deprecated methods together
* Group internal methods together
* Make descriptions more consistent
2014-12-24 16:56:53 -08:00
Max Brunsfeld
883c48b490
Merge pull request #4753 from atom/mb-add-config-get-sources
...
Add Config::getSources
2014-12-23 20:35:42 -08:00
Max Brunsfeld
388428b074
Fix logic error when exception is thrown in config observer
2014-12-23 16:47:43 -08:00
Max Brunsfeld
60c5293b5e
Add Config::getSources
...
The settings-view needs this so that it can display snippets
associated with packages
2014-12-23 11:15:32 -08:00
Max Brunsfeld
a1b4820c04
Revert "Revert "Merge pull request #4631 ""
...
This reverts commit dc2a453986 .
Conflicts:
spec/config-spec.coffee
src/config.coffee
2014-12-23 09:26:40 -08:00
Max Brunsfeld
28ac51d140
Add Config::transact
...
Use this method to avoid emitting unecessary config events
when activating or deactivating multiple packages
2014-12-17 16:54:47 -08:00
Max Brunsfeld
b0731afd4c
Don't pass keyPath to Config::onDidChange callback
...
The keyPath field was never used by core or any package, and
for scoped settings, its value was always equal to the keyPath
specified by the caller.
2014-12-17 12:03:46 -08:00
Max Brunsfeld
dc2a453986
Revert "Merge pull request #4631 from atom/mb-new-config-api"
...
This reverts commit 5147fb6a8b , reversing
changes made to 9bbbb58084 .
2014-12-16 15:27:39 -08:00
Max Brunsfeld
965a6243e1
Remove toBe parens
2014-12-16 14:27:57 -08:00
Max Brunsfeld
b8f239cd39
Deprecate Config::isDefault and ::getDefault
2014-12-16 14:00:57 -08:00
Max Brunsfeld
9f851e55d1
Add Config::unset
...
Deprecate Config::restoreDefault
2014-12-16 14:00:57 -08:00
Max Brunsfeld
ab89776f01
Throw when Config::set is called w/ source and no scope
2014-12-16 14:00:57 -08:00
Max Brunsfeld
2cea51b50e
Take 'scope' option in Config::onDidChange
...
Deprecate passing the scope as an optional first argument
2014-12-16 14:00:57 -08:00
Max Brunsfeld
4e4794f3fd
Take 'scope' option in Config::observe
...
Deprecate using the scope as an optional first argument
2014-12-16 14:00:57 -08:00