From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Kevin Faulkner Newsgroups: gmane.emacs.help Subject: TRAMP and Ruby mode, tabs not being honored Date: Wed, 15 Nov 2017 00:17:38 -0500 Message-ID: References: <20171115034048.GA24198@rmail> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1510756805 6802 195.159.176.226 (15 Nov 2017 14:40:05 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 15 Nov 2017 14:40:05 +0000 (UTC) User-Agent: K-9 Mail for Android To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Nov 15 15:39:57 2017 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eEyr6-0001Gs-Sr for geh-help-gnu-emacs@m.gmane.org; Wed, 15 Nov 2017 15:39:57 +0100 Original-Received: from localhost ([::1]:36467 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eEyrE-0004t2-Aa for geh-help-gnu-emacs@m.gmane.org; Wed, 15 Nov 2017 09:40:04 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42123) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eEq5O-0003et-Hx for help-gnu-emacs@gnu.org; Wed, 15 Nov 2017 00:18:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eEq5J-00021p-H6 for help-gnu-emacs@gnu.org; Wed, 15 Nov 2017 00:18:06 -0500 Original-Received: from mail.lazytree.us ([107.161.30.114]:45482) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eEq5J-000213-AX for help-gnu-emacs@gnu.org; Wed, 15 Nov 2017 00:18:01 -0500 Original-Received: from Galaxy-Note5.cast (cpe-65-188-242-229.triad.res.rr.com [65.188.242.229]) by mail.lazytree.us (Postfix) with ESMTPSA id 85817616B3 for ; Wed, 15 Nov 2017 05:17:58 +0000 (-00) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lazytree.us; s=mail.lazytree.us; t=1510723078; bh=SxJrQy7e/MS4q6PC0aMj/HYXa3XONkmMglstFbol01A=; h=Date:In-Reply-To:References:Subject:To:From; b=JovNpb4iXRfRkRC5n2u6cmc3DTBcvhrPuoxFz1txl7OH+7E1xZMO/ArOHAb4sVffC DWRNZY8yn5QXbPXsA40/n6wXI+6+jL/0ple9Mgi4pJpUFGS8WZwIrQOqzRwewopyGD AO0brweMVjt3QNtEzdDocz6XPRN65MeQWCErFHNo= In-Reply-To: <20171115034048.GA24198@rmail> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 107.161.30.114 X-Mailman-Approved-At: Wed, 15 Nov 2017 09:39:01 -0500 X-Content-Filtered-By: Mailman/MimeDel 2.1.21 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:114878 Archived-At: Hello, I tried to resolve this issue on freenode at #emacs, we made some=20 progress but we were not able to reach a resolution in TRAMP mode=2E=20 The problem I have is that over TRAMP mode while editing a chef (Ruby =2Erb) file remotely, I enter Ruby mode by nature of editing that file=2E When I try make a new block and press (or just press return from=20 the new block) it inserts two spaces=2E When I am editing previously written lines/blocks, I can press tab and it will be a tab character=2E My company mandates tabs (despite my best efforts to change that) in this repository=2E While on IRC I added the hook which seems to work (suggestion found here: https://stackoverflow=2Ecom/a/38901225/9903)=2E It changed the behavior locally (a tab is a tab), but not over TRAMP, which is what I'm really looking to achieve=2E I have made a =2Edir-locals file and tried many variations on the options but it generally looks like this: ```:: ( (setq indent-tabs-mode t) (ruby-mode =2E ((indent-tabs-mode =2E t) (add-hook 'ruby-mode-hook (lambda () (setq indent-tabs-mode t) (setq tab-width 2))) (tab-width =2E 3)))) ::``` I know for a fact that the dir-locals file is being read and respected because I can change the tab-width to be crazy like 10 and it works=2E I would prefer not to make a secondary script to change the spaces into tabs, because I feel this is a configuration/user issue=2E I can include my =2Eemacs (init) file, if you like, I don't have anything too extreme included but here is part of it: ```:: '(bmkp-last-as-first-bookmark-file "/home/kfaulkne/=2Eemacs=2Ed/bookmarks"= ) '(custom-enabled-themes (quote (misterioso))) '(enable-remote-dir-locals t) '(package-selected-packages (quote (dired+ elscreen bookmark+ org-notebook async-await magit leanote elpy dokuwiki-mode dokuwiki))) '(safe-local-variable-values (quote ((ruby-indent-tabs-mode =2E t)))) ;;This was because I kept adding various options I had kept finding=2E '(tramp-default-method "sshx")) ::``` Please excuse any inefficiencies, I have I have tried diligently in vain for a full day and I hope that I might get this resolved=2E Thank you all for your time=2E -Kevin