Si je tape emacs test.shEmacs insiste pour me mettre en Shell-scriptmode. Une autre fois, je veux modifier le fichier help.txt, puis Emacs me met en Textmode. Mais parfois, je ne veux rien de tout cela, surtout quand je fais une grande pâte dans Emacs à partir d'une autre source.
Comment démarrer Emacs en mode "rien"? Pas d'indentation, d'espacement, etc. particuliers, et Emacs prend simplement les caractères en place lors de leur saisie.
MISE À JOUR: Voici un exemple. Copiez le texte suivant dans votre presse-papiers, ouvrez emacs (même en mode fondamental) et collez.
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<EntityDescriptor xmlns="urn:oasis:names:tc:SAML:2.0:metadata"
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
xmlns:shibmd="urn:mace:shibboleth:metadata:1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
ID="FARM20190311T2248"
Name="https://www.example.com/"
entityID="https://www.example.com/" validUntil="2020-03-11T22:48:12Z"><ds:Signature>
<ds:SignedInfo>
<ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
Emacs insiste pour changer l'espacement (même en mode fondamental et en utilisant -q) en ceci:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<EntityDescriptor xmlns="urn:oasis:names:tc:SAML:2.0:metadata"
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
xmlns:shibmd="urn:mace:shibboleth:metadata:1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
ID="FARM20190311T2248"
Name="https://www.example.com/"
entityID="https://www.example.com/" validUntil="2020-03-11T22:48:12Z"><ds:Signature>
<ds:SignedInfo>
<ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
Essayez la même expérience avec viou nano. Ces programmes (au moins sur mon ordinateur) ne modifient pas l'espacement.
J'utilise GNU Emacs 24.5.1 sur le tronçon Debian.
emacs -Qpour vous assurer que Debian n'a pas installé de site-lisp qui est à l'origine de cela? Si cela ne change rien, essayez une version plus récente d'Emacs?