<p>I run</p>

<pre><code>kubectl edit deployment
</code></pre>

<p>to change the version of one of my pods (this commands opens a temp file in my text editor and then I usually edit and close this temp file) and even before I <em>close</em> this temp file in my text editor I can see the following note in my bash.</p>

<pre><code>Edit cancelled, no changes made.
</code></pre>

<p>It was OK before I installed <em>fish</em> and I tried to switch to <em>bash</em> but it doesn't help either.</p>

<p>How can I fix it?</p>

<p>Things like this are most likely caused by it opening an editor that forks off instead of staying.</p>

<p>That means you'll want to set $EDITOR to an editor that does wait. E.g. <code>nano</code>, <code>vim</code> or <code>emacs</code> should work, and e.g. if you use sublime text you'll have to use <code>subl -w</code> to explicitly tell it to wait.</p>

<p>It's not quite clear which shell you're running at the moment. If it's bash, run <code>export EDITOR="subl -w"</code>, in fish run <code>set -gx EDITOR subl -w</code> (or <code>"subl -w"</code> if you use fish &lt; 3.0).</p>
