La commande set -o

yuri648 Messages postés 785 Statut Membre -  
yuri648 Messages postés 785 Statut Membre -
Bonjour,

est ce que vou pouvez m'expliquer la commande
set -o
voici son resultat

allexport off
braceexpand on
emacs on
errexit off
errtrace off
functrace off
hashall on
histexpand on
history on
ignoreeof off
interactive-comments on
keyword off
monitor on
noclobber off
noexec off
noglob off
nolog off
notify off
nounset off
onecmd off
physical off
pipefail off
posix off
privileged off
verbose off
vi off
xtrace off

merci

2 réponses

  1. lami20j Messages postés 21506 Date d'inscription   Statut Modérateur, Contributeur sécurité Dernière intervention   3 571
     
    Salut,

    Tape help set
    Ce que tu vois en fait ce n'est pas son résultat mais ce que tu peux utiliser comme argument pour l'option -o

    lami20j@debian-acer:~/iso$ help set 
    set: set [--abefhkmnptuvxBCHP] [-o option-name] [arg ...] 
        Set or unset values of shell options and positional parameters. 
         
        Change the value of shell attributes and positional parameters, or 
        display the names and values of shell variables. 
         
        Options: 
          -a  Mark variables which are modified or created for export. 
          -b  Notify of job termination immediately. 
          -e  Exit immediately if a command exits with a non-zero status. 
          -f  Disable file name generation (globbing). 
          -h  Remember the location of commands as they are looked up. 
          -k  All assignment arguments are placed in the environment for a 
              command, not just those that precede the command name. 
          -m  Job control is enabled. 
          -n  Read commands but do not execute them. 
          -o option-name 
              Set the variable corresponding to option-name: 
                  allexport    same as -a 
                  braceexpand  same as -B 
                  emacs        use an emacs-style line editing interface 
                  errexit      same as -e 
                  errtrace     same as -E 
                  functrace    same as -T 
                  hashall      same as -h 
                  histexpand   same as -H 
                  history      enable command history 
                  ignoreeof    the shell will not exit upon reading EOF 
                  interactive-comments 
                               allow comments to appear in interactive commands 
                  keyword      same as -k 
                  monitor      same as -m 
                  noclobber    same as -C 
                  noexec       same as -n 
                  noglob       same as -f 
                  nolog        currently accepted but ignored 
                  notify       same as -b 
                  nounset      same as -u 
                  onecmd       same as -t 
                  physical     same as -P 
                  pipefail     the return value of a pipeline is the status of 
                               the last command to exit with a non-zero status, 
                               or zero if no command exited with a non-zero status 
                  posix        change the behavior of bash where the default 
                               operation differs from the Posix standard to 
                               match the standard 
                  privileged   same as -p 
                  verbose      same as -v 
                  vi           use a vi-style line editing interface 
                  xtrace       same as -x


    GNU/Linux:Linux is Not Ubuntu! Quel linux choisir ne veut pas dire votre Distribution préférée,
    106485010510997108
    1
  2. yuri648 Messages postés 785 Statut Membre 7
     
    merci de me repondre
    c'est une question bete mais
    mais sa veut dire quoi on off
    par exemple

    braceexpand on
    emacs on
    errexit off
    errtrace off

    merci
    0
    1. jipicy Messages postés 40842 Date d'inscription   Statut Modérateur Dernière intervention   4 898
       
      Salut,

      ON = Actif
      OFF = Inactif

      Les paramètres braceexpand et emacs sont activés, alors que errexit et errtrace ne le sont pas ;-))
      0
    2. yuri648 Messages postés 785 Statut Membre 7
       
      merci mais ces parametres servent a quoi?
      0
    3. jipicy Messages postés 40842 Date d'inscription   Statut Modérateur Dernière intervention   4 898
       
      man bash et cherche la commande "set" :
      0
    4. yuri648 Messages postés 785 Statut Membre 7
       
      merci
      0