1. 27 Dec, 2014 2 commits
    • Fabián Ezequiel Gallina's avatar
      * lisp/progmodes/python.el (python-shell-buffer-substring): Handle · 433af0a0
      Fabián Ezequiel Gallina authored
      cornercase when region sent starts at point-min.
      433af0a0
    • Fabián Ezequiel Gallina's avatar
      python.el: Handle file encoding for shell. · 2dd5163d
      Fabián Ezequiel Gallina authored
      * lisp/progmodes/python.el (python-rx-constituents): Add coding-cookie.
      (python-shell--save-temp-file): Write file with proper encoding.
      (python-shell-buffer-substring): Add coding cookie for detected
      encoding to generated content.  Fix blank lines when removing
      if-name-main block.
      (python-shell-send-file): Handle file encoding.
      (python-info-encoding-from-cookie)
      (python-info-encoding): New functions.
      
      * test/automated/python-tests.el (python-shell-buffer-substring-1)
      (python-shell-buffer-substring-2, python-shell-buffer-substring-3)
      (python-shell-buffer-substring-4, python-shell-buffer-substring-5)
      (python-shell-buffer-substring-6, python-shell-buffer-substring-7)
      (python-shell-buffer-substring-8)
      (python-info-encoding-from-cookie-1)
      (python-info-encoding-from-cookie-2)
      (python-info-encoding-from-cookie-3)
      (python-info-encoding-from-cookie-4)
      (python-info-encoding-from-cookie-5)
      (python-info-encoding-from-cookie-6)
      (python-info-encoding-from-cookie-7, python-info-encoding-1)
      (python-info-encoding-2): New tests.
      2dd5163d
  2. 25 Dec, 2014 1 commit
  3. 22 Dec, 2014 1 commit
    • Fabián Ezequiel Gallina's avatar
      python.el: Fix electric colon behavior · 749813e9
      Fabián Ezequiel Gallina authored
      * lisp/progmodes/python.el (python-indent-post-self-insert-function):
      Make colon to re-indent only for dedenters, handling
      multiline-statements gracefully.
      
      * test/automated/python-tests.el (python-indent-electric-colon-2)
      (python-indent-electric-colon-3): New tests.
      749813e9
  4. 14 Dec, 2014 1 commit
    • Joao Tavora's avatar
      Consider electric-pair-mode in tex-mode. · bb57c94d
      Joao Tavora authored
      Fixes: debbugs:19356
      
      * lisp/textmodes/tex-mode.el (tex-insert-quote): Consider and respect
      `electric-pair-mode'.
      
      * test/automated/electric-tests.el (autowrapping-7): New test for
      tex-mode's autowrapping.
      (electric-pair-test-for): Call the actual key-binding
      interactively.
      bb57c94d
  5. 13 Dec, 2014 1 commit
  6. 22 Nov, 2014 1 commit
    • Fabián Ezequiel Gallina's avatar
      Set PYTHONUNBUFFERED on shell startup. · 238c052f
      Fabián Ezequiel Gallina authored
      Fixes: debbugs:18595
      
      * lisp/progmodes/python.el (python-shell-unbuffered): New var.
      (python-shell-calculate-process-environment): Use it.
      
      * test/automated/python-tests.el
      (python-shell-calculate-process-environment-4)
      (python-shell-calculate-process-environment-5): New tests.
      (python-shell-make-comint-3): Use file-equal-p.
      (python-shell-get-or-create-process-1)
      (python-shell-get-or-create-process-2)
      (python-shell-get-or-create-process-3): Fix interpreter for
      Windows.
      238c052f
  7. 15 Nov, 2014 2 commits
    • Fabián Ezequiel Gallina's avatar
      Fixes: debbugs:18432 · 92f58578
      Fabián Ezequiel Gallina authored
      * lisp/progmodes/python.el (python-indent-calculate-levels): Fix
      indentation behavior multiline dedenter statement.
      
      * test/automated/python-tests.el (python-indent-dedenters-8): New test
      for Bug#18432.
      92f58578
    • Fabián Ezequiel Gallina's avatar
      Fix region indentation · 89ebffc1
      Fabián Ezequiel Gallina authored
      Fixes: debbugs:18843
      
      * lisp/progmodes/python.el (python-indent-region): Use
      python-indent-line and skip special cases.
      
      * test/automated/python-tests.el (python-indent-region-1)
      (python-indent-region-2, python-indent-region-3)
      (python-indent-region-4, python-indent-region-5): New tests.
      89ebffc1
  8. 08 Nov, 2014 1 commit
    • Michael Albinus's avatar
      Backport Tramp changes from trunk. · b03f9b58
      Michael Albinus authored
      * automated/tramp-tests.el (tramp-remote-process-environment):
      Declare.
      (tramp--test-enabled): Ignore errors.
      (tramp--instrument-test-case): Extend docstring.  Print debug
      buffer in any case.
      (tramp-test15-copy-directory): Skip for tramp-smb.el.
      (tramp-test21-file-links): Use `file-truename' for directories.
      (tramp-test26-process-file): Extend test according to Bug#17815.
      (tramp-test27-start-file-process, tramp-test28-shell-command):
      Retrieve process output more robustly.
      (tramp-test29-vc-registered): Set $BZR_HOME.
      (tramp--test-check-files): Extend test with `substitute-in-file-name'.
      (tramp-test30-special-characters): Skip for tramp-adb.el,
      tramp-gvfs.el and tramp-smb.el.  Add further file names.
      b03f9b58
  9. 20 Oct, 2014 1 commit
  10. 01 Oct, 2014 1 commit
    • Glenn Morris's avatar
      package-test tweaks for hydra · e694e2a9
      Glenn Morris authored
      * test/automated/package-test.el (with-package-test, package-test-signed):
      Also set HOME to a temp value, in case the real one is absent (e.g.
      hydra) or read-only. 
      (package-test-signed): Use skip-unless rather than expected-result.
      
      Fixes: debbugs:18575
      e694e2a9
  11. 01 Sep, 2014 1 commit
  12. 18 Aug, 2014 1 commit
  13. 11 Aug, 2014 1 commit
    • Glenn Morris's avatar
      Revert 2013-01-31 change that decides coding system before backing up · f314e84f
      Glenn Morris authored
      It causes a more serious problem than the one it solves.
      This closes bug#18141, and reopens bug#13522.
      
      * lisp/files.el (basic-save-buffer-2): Revert 2013-01-31 change.
      
      * src/fileio.c: Revert 2013-01-31 change.
      (choose_write_coding_system): No longer callable from Lisp.
      Move last piece back here from Fwrite_region.
      (Fwrite_region, syms_of_fileio): Update for above changes.
      
      * test/automated/data/files-bug18141.el.gz: New file.
      * test/automated/files.el (files-test-bug-18141-file):
      New variable and test.
      f314e84f
  14. 07 Aug, 2014 1 commit
  15. 03 Aug, 2014 1 commit
  16. 20 Jul, 2014 1 commit
    • Fabián Ezequiel Gallina's avatar
      Make python.el work with IPython automatically. · b06a0dff
      Fabián Ezequiel Gallina authored
      * lisp/progmodes/python.el:
      (python-shell-completion-setup-code): New value supporting iPython.
      (python-shell-completion-string-code): New value supporting iPython.
      (python-shell-completion-get-completions): Use them.
      (python-shell-completion-module-string-code): Make obsolete.
      (python-shell-prompt-input-regexps)
      (python-shell-prompt-output-regexps): Add safeguard for ipdb.
      (python-shell-output-filter): Fix comment typo.
      
      * test/automated/python-tests.el:
      (python-util-clone-local-variables-1): Fix test.
      
      Fixes: debbugs:15510
      b06a0dff
  17. 19 Jul, 2014 1 commit
    • Fabián Ezequiel Gallina's avatar
      Autodetect Python shell prompts. · d949ade3
      Fabián Ezequiel Gallina authored
      * lisp/progmodes/python.el:
      (python-shell-interpreter-interactive-arg)
      (python-shell-prompt-detect-enabled)
      (python-shell-prompt-detect-failure-warning)
      (python-shell-prompt-input-regexps)
      (python-shell-prompt-output-regexps): New vars.
      (python-shell-prompt-calculated-input-regexp)
      (python-shell-prompt-calculated-output-regexp): New vars.
      (python-shell-get-process-name)
      (python-shell-internal-get-process-name)
      (python-shell-output-filter)
      (python-shell-completion-get-completions): Use them.
      (python-shell-prompt-detect)
      (python-shell-prompt-validate-regexps): New functions.
      (python-shell-prompt-set-calculated-regexps): New function.
      (inferior-python-mode): Use it.  Also honor overriden
      python-shell-interpreter and python-shell-interpreter-args.
      (python-shell-make-comint): Honor overriden
      python-shell-interpreter and python-shell-interpreter-args.
      (python-shell-get-or-create-process): Make it testable by allowing
      to call run-python non-interactively.
      (python-util-valid-regexp-p): New function.
      (python-shell-prompt-regexp, python-shell-prompt-block-regexp)
      (python-shell-prompt-output-regexp)
      (python-shell-prompt-pdb-regexp): Use it as defcustom :safe.
      
      * test/automated/python-tests.el (python-shell-make-comint-1):
      (python-shell-make-comint-2): Fix indentation.
      (python-shell-make-comint-3)
      (python-shell-make-comint-4): New tests.
      (python-shell-get-or-create-process-1): Fix test.
      (python-shell-get-or-create-process-2)
      (python-shell-get-or-create-process-3): New tests.
      (python-shell-internal-get-or-create-process-1): Fix test.
      (python-shell-prompt-detect-1): New test.
      (python-shell-prompt-detect-2): New test.  (Bug#17370)
      (python-shell-prompt-detect-3)
      (python-shell-prompt-detect-4)
      (python-shell-prompt-detect-5)
      (python-shell-prompt-detect-6)
      (python-shell-prompt-validate-regexps-1)
      (python-shell-prompt-validate-regexps-2)
      (python-shell-prompt-validate-regexps-3)
      (python-shell-prompt-validate-regexps-4)
      (python-shell-prompt-validate-regexps-5)
      (python-shell-prompt-validate-regexps-6)
      (python-shell-prompt-validate-regexps-7)
      (python-shell-prompt-set-calculated-regexps-1)
      (python-shell-prompt-set-calculated-regexps-2)
      (python-shell-prompt-set-calculated-regexps-3)
      (python-shell-prompt-set-calculated-regexps-4)
      (python-shell-prompt-set-calculated-regexps-5)
      (python-shell-prompt-set-calculated-regexps-6)
      (python-util-valid-regexp-p-1): New tests.
      d949ade3
  18. 09 Jul, 2014 1 commit
    • Fabián Ezequiel Gallina's avatar
      Fix dedenters and electric colon handling. · fded0b4a
      Fabián Ezequiel Gallina authored
      * lisp/progmodes/python.el
      (python-rx-constituents): Add dedenter and block-ender.
      (python-indent-dedenters, python-indent-block-enders): Delete.
      (python-indent-context): Return new case for dedenter-statement.
      (python-indent-calculate-indentation): Handle new case.
      (python-indent-calculate-levels): Fix levels calculation for
      dedenter statements.
      (python-indent-post-self-insert-function): Fix colon handling.
      (python-info-dedenter-opening-block-message): New function.
      (python-indent-line): Use it.
      (python-info-closing-block)
      (python-info-closing-block-message): Remove.
      (python-info-dedenter-opening-block-position)
      (python-info-dedenter-opening-block-positions)
      (python-info-dedenter-statement-p): New functions.
      
      * test/automated/python-tests.el
      (python-indent-block-enders-1)
      (python-indent-block-enders-2): Fix tests.
      (python-indent-block-enders-3)
      (python-indent-block-enders-4)
      (python-indent-block-enders-5)
      (python-indent-dedenters-1)
      (python-indent-dedenters-2): Remove tests.
      (python-indent-dedenters-1)
      (python-indent-dedenters-2)
      (python-indent-dedenters-3)
      (python-indent-dedenters-4)
      (python-indent-dedenters-5)
      (python-indent-dedenters-6)
      (python-indent-dedenters-7)
      (python-info-dedenter-opening-block-position-1)
      (python-info-dedenter-opening-block-position-2)
      (python-info-dedenter-opening-block-position-3)
      (python-info-dedenter-opening-block-positions-1)
      (python-info-dedenter-opening-block-positions-2)
      (python-info-dedenter-opening-block-positions-3)
      (python-info-dedenter-opening-block-positions-4)
      (python-info-dedenter-opening-block-positions-5)
      (python-info-dedenter-opening-block-message-1)
      (python-info-dedenter-opening-block-message-2)
      (python-info-dedenter-opening-block-message-3)
      (python-info-dedenter-opening-block-message-4)
      (python-info-dedenter-opening-block-message-5)
      (python-info-dedenter-statement-p-1)
      (python-info-dedenter-statement-p-2)
      (python-info-dedenter-statement-p-3)
      (python-info-dedenter-statement-p-4)
      (python-info-dedenter-statement-p-5): New tests.
      
      Fixes: debbugs:15163
      fded0b4a
  19. 01 Jul, 2014 1 commit
  20. 28 Jun, 2014 1 commit
  21. 27 Jun, 2014 1 commit
  22. 25 Jun, 2014 1 commit
  23. 21 Jun, 2014 1 commit
    • Fabián Ezequiel Gallina's avatar
      Fix completion retrieval parsing. · 656f99be
      Fabián Ezequiel Gallina authored
      * progmodes/python.el (python-mode):
      (python-util-strip-string): New function.
      (python-shell-completion-get-completions): Use it.
      
      * automated/python-tests.el (python-util-strip-string-1): New test.
      
      Fixes: debbugs:17209
      656f99be
  24. 01 Jun, 2014 2 commits
  25. 08 May, 2014 2 commits
  26. 05 May, 2014 2 commits
  27. 25 Apr, 2014 1 commit
  28. 24 Apr, 2014 1 commit
    • Michael Albinus's avatar
      Use a mock-up connection method for remote files. · c0b9bc72
      Michael Albinus authored
      * automated/file-notify-tests.el
      (file-notify-test-remote-temporary-file-directory):
      * automated/tramp-tests.el (tramp-test-temporary-file-directory):
      Use a mock-up method as default.
      (tramp-test00-availability): Print the used directory name.
      (tramp-test33-recursive-load): Fix typo.
      c0b9bc72
  29. 22 Apr, 2014 2 commits
  30. 20 Apr, 2014 1 commit
  31. 19 Apr, 2014 1 commit
  32. 18 Apr, 2014 1 commit
    • Michael Albinus's avatar
      * automated/tramp-tests.el (tramp-copy-size-limit): Set to nil. · 2a2e6726
      Michael Albinus authored
      (tramp--test-make-temp-name): Optional argument LOCAL.
      (tramp--instrument-test-case): Show messages.  Catch also `quit'.
      (tramp-test10-write-region): No special test for out-of-band copy
      needed anymore.
      (tramp-test11-copy-file, tramp-test12-rename-file)
      (tramp-test21-file-links): Extend tests.
      (tramp-test20-file-modes): More robust check for user "root".
      (tramp--test-check-files): New defun.
      (tramp-test30-special-characters, tramp-test33-recursive-load)
      (tramp-test34-unload): New tests.
      (tramp-test31-utf8, tramp-test32-asynchronous-requests):  Rename.
      2a2e6726
  33. 10 Apr, 2014 1 commit
    • Paul Eggert's avatar
      Spelling fixes. · 10ee3b3f
      Paul Eggert authored
      * automated/electric-tests.el: Fix spelling error in test name.
      (whitespace-skipping-for-quotes-not-outside):
      Rename from whitespace-skipping-for-quotes-not-ouside.
      10ee3b3f
  34. 09 Apr, 2014 1 commit