0
0

More than 3 years have passed since last update.

[sed]【1行野郎】連続しない複数行を抽出する (例: 1行目とパターンマッチ行)

Last updated at Posted at 2021-08-25
本シリーズのトップページ
https://qiita.com/robozushi10/items/5d1313fa11ede179ddad

概要

docker images コマンドの結果のうち、ヘッダである「1行目」と「パターン一致行」を表示させる.

$ docker images | sed -n -e '1p' -e '/^maho/p'
REPOSITORY      TAG    IMAGE ID            CREATED             SIZE
maho/webapl     0.1    714ae03094e1        17 minutes ago      66.1MB

以上.

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0