mirror of
https://github.com/atom/atom.git
synced 2026-01-26 15:28:27 -05:00
Merge branch 'master' into ns-modernize-build
This commit is contained in:
@@ -237,10 +237,6 @@ module.exports =
|
||||
default: true
|
||||
title: 'Confirm Checkout HEAD Revision'
|
||||
description: 'Show confirmation dialog when checking out the HEAD revision and discarding changes to current file since last commit.'
|
||||
backUpBeforeSaving:
|
||||
type: 'boolean'
|
||||
default: false
|
||||
description: 'Ensure file contents aren\'t lost if there is an I/O error during save by making a temporary backup copy.'
|
||||
invisibles:
|
||||
type: 'object'
|
||||
description: 'A hash of characters Atom will use to render whitespace characters. Keys are whitespace character types, values are rendered characters (use value false to turn off individual whitespace character types).'
|
||||
|
||||
@@ -757,14 +757,14 @@ class TextEditor extends Model
|
||||
# Essential: Saves the editor's text buffer.
|
||||
#
|
||||
# See {TextBuffer::save} for more details.
|
||||
save: -> @buffer.save(backup: @config.get('editor.backUpBeforeSaving'))
|
||||
save: -> @buffer.save()
|
||||
|
||||
# Essential: Saves the editor's text buffer as the given path.
|
||||
#
|
||||
# See {TextBuffer::saveAs} for more details.
|
||||
#
|
||||
# * `filePath` A {String} path.
|
||||
saveAs: (filePath) -> @buffer.saveAs(filePath, backup: @config.get('editor.backUpBeforeSaving'))
|
||||
saveAs: (filePath) -> @buffer.saveAs(filePath)
|
||||
|
||||
# Determine whether the user should be prompted to save before closing
|
||||
# this editor.
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
/** @babel */
|
||||
|
||||
import fs from 'fs'
|
||||
import {spawnSync} from 'child_process'
|
||||
|
||||
const ENVIRONMENT_VARIABLES_TO_PRESERVE = new Set([
|
||||
@@ -37,6 +38,10 @@ function updateProcessEnv (launchEnv) {
|
||||
process.env[key] = envToAssign[key]
|
||||
}
|
||||
}
|
||||
|
||||
if (envToAssign.ATOM_HOME && fs.existsSync(envToAssign.ATOM_HOME)) {
|
||||
process.env.ATOM_HOME = envToAssign.ATOM_HOME
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user