-2
 ======KVM 虚拟化手册======
=====简介=====
=====安装和配置kvm虚拟化=====
====检查是否支持KVM====
====安装kvm虚拟化平台====
====配置nested virtualization====
==== 配置网络====
====重启系统并检查相关配置====
=====virsh创建 & 安装虚拟机=====
====通过VNC进行安装====
=====REFERENCE=====
  1. The lines which begin with"=" and end with "="
  2. add - at the end of the left "=", like:

    ===== - REFERENCE=====
    

How can I do ? thks ...

2
sed '/^=.*=$/ s/=\+/& - /' file

The first bit is "for each line that starts and ends with =".
The second bit is "replace the first sequence of = with: itself space dash space".

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.