From dc6c0a3e352ce1a1bf4e63757150b80a5f56282b Mon Sep 17 00:00:00 2001 From: David Graham & Nathan Sobo Date: Wed, 20 Jun 2012 11:19:40 -0600 Subject: [PATCH] Rename `userConfigurationPath` to `configFilePath` so I can add `configDirPath` as well --- src/app/atom.coffee | 6 ++++-- src/app/keymap.coffee | 2 +- src/app/window.coffee | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/app/atom.coffee b/src/app/atom.coffee index 36be59da3..1fdda1f62 100644 --- a/src/app/atom.coffee +++ b/src/app/atom.coffee @@ -9,13 +9,15 @@ module.exports = class Atom keymap: null windows: null - userConfigurationPath: null + configFilePath: null + configDirPath: null rootViewStates: null constructor: (@loadPath, nativeMethods) -> @windows = [] @setUpKeymap() - @userConfigurationPath = fs.absolute "~/.atom/atom.coffee" + @configDirPath = fs.absolute("~/.atom") + @configFilePath = fs.join(@configDirPath, "atom.coffee") @rootViewStates = {} setUpKeymap: -> diff --git a/src/app/keymap.coffee b/src/app/keymap.coffee index 3d4a59014..06f90bda0 100644 --- a/src/app/keymap.coffee +++ b/src/app/keymap.coffee @@ -20,7 +20,7 @@ class Keymap 'meta-o': 'open' $(document).on 'new-window', => $native.newWindow() - $(document).on 'open-user-configuration', => atom.open(atom.userConfigurationPath) + $(document).on 'open-user-configuration', => atom.open(atom.configFilePath) $(document).on 'open', => path = $native.openDialog() atom.open(path) if path diff --git a/src/app/window.coffee b/src/app/window.coffee index 05b7854d6..0685f3f3e 100644 --- a/src/app/window.coffee +++ b/src/app/window.coffee @@ -50,9 +50,9 @@ windowAdditions = loadUserConfiguration: -> try - require atom.userConfigurationPath if fs.exists(atom.userConfigurationPath) + require atom.configFilePath if fs.exists(atom.configFilePath) catch error - console.error "Failed to load `#{atom.userConfigurationPath}`", error.message, error + console.error "Failed to load `#{atom.configFilePath}`", error.message, error @showConsole() requireStylesheet: (path) ->