<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>7020</bug_id>
          
          <creation_ts>2005-06-07 14:58:14 +0400</creation_ts>
          <short_desc>alternatives-manual некорректно определяет текущий статус альтернативы</short_desc>
          <delta_ts>2005-07-15 10:55:56 +0400</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>alternatives</component>
          <version>unstable</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Sir Raorn">raorn</reporter>
          <assigned_to name="placeholder@altlinux.org">placeholder</assigned_to>
          <cc>at</cc>
    
    <cc>glebfm</cc>
    
    <cc>ldv</cc>
    
    <cc>placeholder</cc>
    
    <cc>vt</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>25348</commentid>
    <comment_count>0</comment_count>
    <who name="Sir Raorn">raorn</who>
    <bug_when>2005-06-07 14:58:14 +0400</bug_when>
    <thetext>Код:

grep -q &quot;^$from&quot; $manual_file
if [ $? -eq 0 ]; then
    [ -w $manual_file ] || print_fatal &quot;$manual_file is not writable for me&quot;
    ed -s $manual_file 2&gt;/dev/null &lt;&lt;EOF
%s|^$from   .*|$from    $to manual|g
wq
EOF
else
    echo &quot;$from $to manual&quot;&gt;&gt;$manual_file
fi

Если $from совпадает с началом одной из существующих альтернатив и эта
альтернатива находится в &quot;ручном режиме&quot; - $from не будет переведена в &quot;ручной
режим&quot;.
Steps to Reproduce:
1. apt-get install vim-enhanced vim-X11 vim-X11-gtk
2. alternatives-manual /usr/bin/vim-X11 /usr/bin/vim-gtk &amp;&amp; alternatives-update
3. alternatives-manual /usr/bin/vim /usr/bin/vim-enhanced
4. readlink /etc/alternatives/links/\|usr\|bin\|vim
Actual Results:  
/usr/bin/vim-X11

Expected Results:  
/usr/bin/vim-enhanced</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>25349</commentid>
    <comment_count>1</comment_count>
    <who name="Sir Raorn">raorn</who>
    <bug_when>2005-06-07 14:59:23 +0400</bug_when>
    <thetext>&gt; 3. alternatives-manual /usr/bin/vim /usr/bin/vim-enhanced

alternatives-update естессно запускается.  Кстати, можно заглянуть и в
/etc/alternatives/manual</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>25531</commentid>
    <comment_count>2</comment_count>
    <who name="inger@altlinux.org">inger</who>
    <bug_when>2005-06-10 12:36:01 +0400</bug_when>
    <thetext>в 0.2.0-alt1</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>