[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/rubocop 2b782ec 23/64: Merge pull request #13 from ojab/ma
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/rubocop 2b782ec 23/64: Merge pull request #13 from ojab/master |
Date: |
Wed, 11 Aug 2021 10:07:58 -0400 (EDT) |
branch: elpa/rubocop
commit 2b782ecbe7feda9c92d26a45a803bd932604f5ee
Merge: 7446469 9b23b05
Author: Bozhidar Batsov <bozhidar.batsov@gmail.com>
Commit: Bozhidar Batsov <bozhidar.batsov@gmail.com>
Merge pull request #13 from ojab/master
Make rubocop-emacs TRAMP-aware
---
rubocop.el | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/rubocop.el b/rubocop.el
index dae674a..02e4050 100644
--- a/rubocop.el
+++ b/rubocop.el
@@ -58,6 +58,13 @@
:group 'rubocop
:type 'string)
+(defun rubocop-local-file-name (file-name)
+ "Retrieve local filename if FILE-NAME is opened via TRAMP."
+ (cond ((tramp-tramp-file-p file-name)
+ (tramp-file-name-localname (tramp-dissect-file-name file-name)))
+ (t
+ file-name)))
+
(defun rubocop-project-root ()
"Retrieve the root directory of a project if available.
The current directory is assumed to be the project's root otherwise."
@@ -79,7 +86,7 @@ Alternatively prompt user for directory."
(or directory
(read-directory-name "Select directory:"))))
(compilation-start
- (concat command " " directory)
+ (concat command " " (rubocop-local-file-name directory))
'compilation-mode
(lambda (arg) (message arg) (rubocop-buffer-name directory)))))
@@ -115,7 +122,7 @@ Alternatively prompt user for directory."
(let ((file-name (buffer-file-name (current-buffer))))
(if file-name
(compilation-start
- (concat command " " file-name)
+ (concat command " " (rubocop-local-file-name file-name))
'compilation-mode
(lambda (arg) (rubocop-buffer-name file-name)))
(error "Buffer is not visiting a file"))))
- [nongnu] branch elpa/rubocop created (now f5fd18a), ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop f493961 03/64: Check for the presence of the rubocop binary, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 7026b86 04/64: Make rubocop.el usable :-), ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 88d1bbf 09/64: Change commentary so that it doesn't describe projectile, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop c620a0c 11/64: Add auto-correction commands, minor mode and a default keymap, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 192d976 02/64: An extremely basic RuboCop interface, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 1e77d3f 18/64: add missing period, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 7446469 21/64: Merge pull request #11 from rranelli/master, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 2b782ec 23/64: Merge pull request #13 from ojab/master,
ELPA Syncer <=
- [nongnu] elpa/rubocop 405e0fd 28/64: Bump version to 0.4.0, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 14ab46a 01/64: first commit, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop fb98804 24/64: Load tramp dependency, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 322564d 07/64: Update for RuboCop 0.9 (fixes #1) - update rubocop-on-current-file, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 4aeda22 14/64: Update README.md, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop a192b35 26/64: Fix autocorrect-project binding, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop b65a310 10/64: Merge pull request #3 from purcell/patch-1, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 4acece2 17/64: Merge pull request #5 from arthurnn/fix-mode-desc, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 80be17c 13/64: Fix table, ELPA Syncer, 2021/08/11
- [nongnu] elpa/rubocop 1ffa08b 05/64: Add a few autoloads, ELPA Syncer, 2021/08/11