<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>tounyun</author_name>
  <author_url>https://blog.hatena.ne.jp/tounyun/</author_url>
  <blog_title>てきとうまとめ</blog_title>
  <blog_url>https://tounyun.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>linuxでhistoryコマンドの履歴を削除しておきたい場面に遭遇しました。 あまり使う機会は多くないと思うのでメモ。 $ history -cこれで全履歴削除できます。 もう一度historyコマンド実行してみても確かに消えていました。念のため一度exitしてから、再度ssh接続してみる。 historyコマンド実行。 先ほど消したはずの履歴が復活している。 実は-cはそのセッションの履歴を削除するオプションらしいです。 セッションから出ても履歴削除を保ちたい場合は-wを使います。 $ history -c先程と同様、一度そのセッションの履歴を削除。 $ history -wそのあと-wで…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftounyun.hatenablog.com%2Fentry%2F2018%2F01%2F09%2F231436&quot; title=&quot;historyコマンドの履歴を消去する - てきとうまとめ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2018-01-09 23:14:36</published>
  <title>historyコマンドの履歴を消去する</title>
  <type>rich</type>
  <url>https://tounyun.hatenablog.com/entry/2018/01/09/231436</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
