diff options
author | Ned Deily <nad@python.org> | 2016-02-23 20:45:57 +1100 |
---|---|---|
committer | Ned Deily <nad@python.org> | 2016-02-23 20:45:57 +1100 |
commit | 903783416b82499e1e8cc483c37a8ebc494564d9 (patch) | |
tree | f9799366bed84ac51004432ea8c43f57b12d3ab7 /Mac | |
parent | c46a2ebaff1be90707ef28656649bca025e8e395 (diff) | |
download | cpython-git-903783416b82499e1e8cc483c37a8ebc494564d9.tar.gz |
Issue #26417: Prevent spurious errors and incorrect defaults when
installing IDLE 2.7 on OS X: default configuration settings are
no longer installed from OS X specific copies.
Diffstat (limited to 'Mac')
-rw-r--r-- | Mac/IDLE/Makefile.in | 22 | ||||
-rw-r--r-- | Mac/IDLE/config-extensions.def | 93 | ||||
-rw-r--r-- | Mac/IDLE/config-main.def | 79 |
3 files changed, 19 insertions, 175 deletions
diff --git a/Mac/IDLE/Makefile.in b/Mac/IDLE/Makefile.in index 6ae360c61c..98590ab002 100644 --- a/Mac/IDLE/Makefile.in +++ b/Mac/IDLE/Makefile.in @@ -7,6 +7,7 @@ CFLAGS=$(BASECFLAGS) $(OPT) LDFLAGS=@LDFLAGS@ srcdir= @srcdir@ VERSION= @VERSION@ +LIBDEST=$(prefix)/lib/python$(VERSION) UNIVERSALSDK=@UNIVERSALSDK@ builddir= ../.. PYTHONFRAMEWORK=@PYTHONFRAMEWORK@ @@ -28,13 +29,28 @@ PYTHONAPPSDIR=@FRAMEWORKINSTALLAPPSPREFIX@/$(PYTHONFRAMEWORK) $(VERSION) all: IDLE.app -install: IDLE.app $(srcdir)/config-main.def $(srcdir)/config-extensions.def +install: IDLE.app test -d "$(DESTDIR)$(PYTHONAPPSDIR)" || mkdir -p "$(DESTDIR)$(PYTHONAPPSDIR)" -test -d "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" && rm -r "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" /bin/cp -PR IDLE.app "$(DESTDIR)$(PYTHONAPPSDIR)" touch "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" - /bin/cp $(srcdir)/config-main.def "$(DESTDIR)$(prefix)/lib/python$(VERSION)/idlelib/config-main.def" - /bin/cp $(srcdir)/config-extensions.def "$(DESTDIR)$(prefix)/lib/python$(VERSION)/idlelib/config-extensions.def" + if [ -f "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def" ]; then \ + /bin/cp -p "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def" \ + "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def~" ; \ + sed -e 's!name= IDLE Classic Windows!name= IDLE Classic OSX!g' \ + < "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def~" \ + > "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def" ; \ + rm "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def~" ; \ + fi + if [ -f "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def" ]; then \ + /bin/cp -p "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def" \ + "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def~" ; \ + sed -e 's!zoom-height=<Alt-Key-2>!zoom-height=<Option-Key-0>!g' \ + -e 's!<Alt-Key-!<Option-Key-!g' \ + < "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def~" \ + > "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def" ; \ + rm "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def~" ; \ + fi clean: rm -rf IDLE.app diff --git a/Mac/IDLE/config-extensions.def b/Mac/IDLE/config-extensions.def deleted file mode 100644 index 1791b9c0ae..0000000000 --- a/Mac/IDLE/config-extensions.def +++ /dev/null @@ -1,93 +0,0 @@ -# config-extensions.def -# -# IDLE reads several config files to determine user preferences. This -# file is the default configuration file for IDLE extensions settings. -# -# Each extension must have at least one section, named after the extension -# module. This section must contain an 'enable' item (=1 to enable the -# extension, =0 to disable it), it may contain 'enable_editor' or 'enable_shell' -# items, to apply it only to editor/shell windows, and may also contain any -# other general configuration items for the extension. -# -# Each extension must define at least one section named ExtensionName_bindings -# or ExtensionName_cfgBindings. If present, ExtensionName_bindings defines -# virtual event bindings for the extension that are not user re-configurable. -# If present, ExtensionName_cfgBindings defines virtual event bindings for the -# extension that may be sensibly re-configured. -# -# If there are no keybindings for a menus' virtual events, include lines like -# <<toggle-code-context>>= (See [CodeContext], below.) -# -# Currently it is necessary to manually modify this file to change extension -# key bindings and default values. To customize, create -# ~/.idlerc/config-extensions.cfg and append the appropriate customized -# section(s). Those sections will override the defaults in this file. -# -# Note: If a keybinding is already in use when the extension is -# loaded, the extension's virtual event's keybinding will be set to ''. -# -# See config-keys.def for notes on specifying keys and extend.txt for -# information on creating IDLE extensions. - -[FormatParagraph] -enable=1 -[FormatParagraph_cfgBindings] -format-paragraph=<Option-Key-q> - -[AutoExpand] -enable=1 -[AutoExpand_cfgBindings] -expand-word=<Option-Key-slash> - -[ZoomHeight] -enable=1 -[ZoomHeight_cfgBindings] -zoom-height=<Option-Key-0> - -[ScriptBinding] -enable=1 -[ScriptBinding_cfgBindings] -run-module=<Key-F5> -check-module=<Option-Key-x> - -[CallTips] -enable=1 -[CallTips_cfgBindings] -force-open-calltip=<Control-Key-backslash> -[CallTips_bindings] -try-open-calltip=<KeyRelease-parenleft> -refresh-calltip=<KeyRelease-parenright> <KeyRelease-0> - -[ParenMatch] -enable=1 -style= expression -flash-delay= 500 -bell= 1 -[ParenMatch_cfgBindings] -flash-paren=<Control-Key-0> -[ParenMatch_bindings] -paren-closed=<KeyRelease-parenright> <KeyRelease-bracketright> <KeyRelease-braceright> - -[AutoComplete] -enable=1 -popupwait=2000 -[AutoComplete_cfgBindings] -force-open-completions=<Control-Key-space> -[AutoComplete_bindings] -autocomplete=<Key-Tab> -try-open-completions=<KeyRelease-period> <KeyRelease-slash> <KeyRelease-backslash> - -[CodeContext] -enable=1 -enable_shell=0 -numlines=3 -visible=0 -bgcolor=LightGray -fgcolor=Black -[CodeContext_bindings] -toggle-code-context= - -[RstripExtension] -enable=1 -enable_shell=0 -enable_editor=1 diff --git a/Mac/IDLE/config-main.def b/Mac/IDLE/config-main.def deleted file mode 100644 index 4691a85290..0000000000 --- a/Mac/IDLE/config-main.def +++ /dev/null @@ -1,79 +0,0 @@ -# IDLE reads several config files to determine user preferences. This -# file is the default config file for general idle settings. -# -# When IDLE starts, it will look in -# the following two sets of files, in order: -# -# default configuration -# --------------------- -# config-main.def the default general config file -# config-extensions.def the default extension config file -# config-highlight.def the default highlighting config file -# config-keys.def the default keybinding config file -# -# user configuration -# ------------------- -# ~/.idlerc/config-main.cfg the user general config file -# ~/.idlerc/config-extensions.cfg the user extension config file -# ~/.idlerc/config-highlight.cfg the user highlighting config file -# ~/.idlerc/config-keys.cfg the user keybinding config file -# -# On Windows2000 and Windows XP the .idlerc directory is at -# Documents and Settings\<username>\.idlerc -# -# On Windows98 it is at c:\.idlerc -# -# Any options the user saves through the config dialog will be saved to -# the relevant user config file. Reverting any general setting to the -# default causes that entry to be wiped from the user file and re-read -# from the default file. User highlighting themes or keybinding sets are -# retained unless specifically deleted within the config dialog. Choosing -# one of the default themes or keysets just applies the relevant settings -# from the default file. -# -# Additional help sources are listed in the [HelpFiles] section and must be -# viewable by a web browser (or the Windows Help viewer in the case of .chm -# files). These sources will be listed on the Help menu. The pattern is -# <sequence_number = menu item;/path/to/help/source> -# You can't use a semi-colon in a menu item or path. The path will be platform -# specific because of path separators, drive specs etc. -# -# It is best to use the Configuration GUI to set up additional help sources! -# Example: -#1 = My Extra Help Source;/usr/share/doc/foo/index.html -#2 = Another Help Source;/path/to/another.pdf - -[General] -editor-on-startup= 0 -autosave= 0 -print-command-posix=lpr %s -print-command-win=start /min notepad /p %s -delete-exitfunc= 1 - -[EditorWindow] -width= 80 -height= 40 -font= courier -font-size= 10 -font-bold= 0 -encoding= none - -[FormatParagraph] -paragraph=70 - -[Indent] -use-spaces= 1 -num-spaces= 4 - -[Theme] -default= 1 -name= IDLE Classic - -[Keys] -default= 1 -name= IDLE Classic OSX - -[History] -cyclic=1 - -[HelpFiles] |