 
 convertEOL = (text) ->
   text.replace(/\r\n|\n|\r/g, '\n')
+
+didAddOpener = false
 
 unimplemented = ({type}) ->
   command = type.replace(/^learn-ide:/, '').replace(/-/g, ' ')

        composite.add resultModel.onDidReplacePath ({filePath}) ->
          onFindAndReplace(filePath)

    atom.emitter.on 'learn-ide:did-join-channel', (channel) ->
      nsync.configure
        expansionState: activationState.directoryExpansionStates
        localRoot: _path.join(atom.configDirPath, '.learn-ide')

      'learn-ide-tree:refresh': onRefresh

    nsync.onDidConfigure ->
      if not didAddOpener
        didAddOpener = true
        atomHelper.addOpener (uri) ->
          fs.stat uri, (err, stats) ->
            if err? and nsync.hasPath(uri)
              atomHelper.loadingFile(uri)
              nsync.open(uri)
              waitForFile(uri, 1)

    nsync.onDidOpen ({localPath}) ->
      atomHelper.resolveOpen(localPath)
