title: Replace spaces and / between two brackets in bash
body: <p>I have this (text) file:</p>
  <pre><code>[check consumer TAIL_SCE_O_P]
  [CheckCo on IEB02]
  [CheckSubscribers consumers for ne/os/jms/queue/FT_PN_IN]
  [CheckSubscribers consumers for ne/os/jms/queue/SO_IN]
  Please do not change/me/thank/you
  another bracketless text
  </code></pre>
  <p>I would like replace spaces ( ) and / to an - between brackets</p>
  <p>Example output:</p>
  <pre><code>[check-consumer-TAIL_SCE_O_P]
  [CheckCo-on-IEB02]
  [CheckSubscribers-consumers-for-ne-os-jms-queue-FT_PN_IN]
  [CheckSubscribers-consumers-for-ne-os-jms-queue-SO_IN]
  Please do not change/me/thank/you
  another bracketless text
  </code></pre>
  <p>I have tried this:</p>
  <pre><code>cat output.txt |grep &quot;\[&quot; | sed 's/\ /-/g'
  </code></pre>
  <p>But it is changed a lot of tings.</p>