<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://nethackwiki.com/index.php?action=history&amp;feed=atom&amp;title=Shell_escape</id>
	<title>Shell escape - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://nethackwiki.com/index.php?action=history&amp;feed=atom&amp;title=Shell_escape"/>
	<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;action=history"/>
	<updated>2026-07-21T15:34:10Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.32.5</generator>
	<entry>
		<id>https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=99230&amp;oldid=prev</id>
		<title>ChasonBot at 09:39, 21 December 2015</title>
		<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=99230&amp;oldid=prev"/>
		<updated>2015-12-21T09:39:57Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 09:39, 21 December 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l7&quot; &gt;Line 7:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 7:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for shell-escaping for a [[Unix]] system. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press {{kbd|Ctrl|Z}} to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for shell-escaping for a [[Unix]] system. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press {{kbd|Ctrl|Z}} to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{nethack-343}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>ChasonBot</name></author>
		
	</entry>
	<entry>
		<id>https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=84708&amp;oldid=prev</id>
		<title>Bulwersator: delinkify operating system (Special:WantedPages)</title>
		<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=84708&amp;oldid=prev"/>
		<updated>2013-05-04T21:50:10Z</updated>

		<summary type="html">&lt;p&gt;delinkify &lt;a href=&quot;/wiki/Operating_system&quot; title=&quot;Operating system&quot;&gt;operating system&lt;/a&gt; (&lt;a href=&quot;/wiki/Special:WantedPages&quot; title=&quot;Special:WantedPages&quot;&gt;Special:WantedPages&lt;/a&gt;)&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 21:50, 4 May 2013&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot; &gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In game, the {{kbd|!}} key triggers the '''shell escape'''. This should send you to a command line; exit the shell to return to NetHack. The exact behavior varies by &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;[[&lt;/del&gt;operating system&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;]]&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In game, the {{kbd|!}} key triggers the '''shell escape'''. This should send you to a command line; exit the shell to return to NetHack. The exact behavior varies by operating system.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;It only works if the person who compiled the game had SHELL defined in [[config.h]]. Persons who build the game for [[public server]]s or other environments in which the player should not reach a shell will disable it.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;It only works if the person who compiled the game had SHELL defined in [[config.h]]. Persons who build the game for [[public server]]s or other environments in which the player should not reach a shell will disable it.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Bulwersator</name></author>
		
	</entry>
	<entry>
		<id>https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=48627&amp;oldid=prev</id>
		<title>Schneelocke: use {{kbd}}</title>
		<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=48627&amp;oldid=prev"/>
		<updated>2010-05-03T23:58:32Z</updated>

		<summary type="html">&lt;p&gt;use {{kbd}}&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 23:58, 3 May 2010&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l5&quot; &gt;Line 5:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 5:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In the [[source code]], the &amp;lt;tt&amp;gt;dosh&amp;lt;/tt&amp;gt; function handles this. The code for this function, if any, is somewhere under the &amp;lt;tt&amp;gt;nethack-3.4.3/sys&amp;lt;/tt&amp;gt; directory for your operating system.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In the [[source code]], the &amp;lt;tt&amp;gt;dosh&amp;lt;/tt&amp;gt; function handles this. The code for this function, if any, is somewhere under the &amp;lt;tt&amp;gt;nethack-3.4.3/sys&amp;lt;/tt&amp;gt; directory for your operating system.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for shell-escaping for a [[Unix]] system. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;Control-&lt;/del&gt;Z to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for shell-escaping for a [[Unix]] system. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;{{kbd|Ctrl|&lt;/ins&gt;Z&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;}} &lt;/ins&gt;to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Schneelocke</name></author>
		
	</entry>
	<entry>
		<id>https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=39238&amp;oldid=prev</id>
		<title>Paxed: kbd</title>
		<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=39238&amp;oldid=prev"/>
		<updated>2009-04-22T15:17:08Z</updated>

		<summary type="html">&lt;p&gt;kbd&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 15:17, 22 April 2009&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot; &gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In game, the &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;[[&lt;/del&gt;!&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;]] &lt;/del&gt;key triggers the '''shell escape'''. This should send you to a command line; exit the shell to return to NetHack. The exact behavior varies by [[operating system]].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In game, the &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;{{kbd|&lt;/ins&gt;!&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;}} &lt;/ins&gt;key triggers the '''shell escape'''. This should send you to a command line; exit the shell to return to NetHack. The exact behavior varies by [[operating system]].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;It only works if the person who compiled the game had SHELL defined in [[config.h]]. Persons who build the game for [[public server]]s or other environments in which the player should not reach a shell will disable it.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;It only works if the person who compiled the game had SHELL defined in [[config.h]]. Persons who build the game for [[public server]]s or other environments in which the player should not reach a shell will disable it.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l6&quot; &gt;Line 6:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 6:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for shell-escaping for a [[Unix]] system. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press Control-Z to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for shell-escaping for a [[Unix]] system. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press Control-Z to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Paxed</name></author>
		
	</entry>
	<entry>
		<id>https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=9050&amp;oldid=prev</id>
		<title>Eidolos: The source code for Unix in a single file? Wow! :)</title>
		<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=9050&amp;oldid=prev"/>
		<updated>2006-08-31T04:29:47Z</updated>

		<summary type="html">&lt;p&gt;The source code for Unix in a single file? Wow! :)&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 04:29, 31 August 2006&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l5&quot; &gt;Line 5:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 5:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In the [[source code]], the &amp;lt;tt&amp;gt;dosh&amp;lt;/tt&amp;gt; function handles this. The code for this function, if any, is somewhere under the &amp;lt;tt&amp;gt;nethack-3.4.3/sys&amp;lt;/tt&amp;gt; directory for your operating system.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;In the [[source code]], the &amp;lt;tt&amp;gt;dosh&amp;lt;/tt&amp;gt; function handles this. The code for this function, if any, is somewhere under the &amp;lt;tt&amp;gt;nethack-3.4.3/sys&amp;lt;/tt&amp;gt; directory for your operating system.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for [[Unix]]. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press Control-Z to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;shell-escaping for a &lt;/ins&gt;[[Unix]] &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;system&lt;/ins&gt;. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press Control-Z to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Commands]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Eidolos</name></author>
		
	</entry>
	<entry>
		<id>https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=9031&amp;oldid=prev</id>
		<title>Kernigh: In four paragraphs, describe the shell escape, including how it does upon Unix.</title>
		<link rel="alternate" type="text/html" href="https://nethackwiki.com/index.php?title=Shell_escape&amp;diff=9031&amp;oldid=prev"/>
		<updated>2006-08-31T00:05:51Z</updated>

		<summary type="html">&lt;p&gt;In four paragraphs, describe the shell escape, including how it does upon &lt;a href=&quot;/wiki/Unix&quot; title=&quot;Unix&quot;&gt;Unix&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;In game, the [[!]] key triggers the '''shell escape'''. This should send you to a command line; exit the shell to return to NetHack. The exact behavior varies by [[operating system]].&lt;br /&gt;
&lt;br /&gt;
It only works if the person who compiled the game had SHELL defined in [[config.h]]. Persons who build the game for [[public server]]s or other environments in which the player should not reach a shell will disable it.&lt;br /&gt;
&lt;br /&gt;
In the [[source code]], the &amp;lt;tt&amp;gt;dosh&amp;lt;/tt&amp;gt; function handles this. The code for this function, if any, is somewhere under the &amp;lt;tt&amp;gt;nethack-3.4.3/sys&amp;lt;/tt&amp;gt; directory for your operating system.&lt;br /&gt;
&lt;br /&gt;
The file &amp;lt;tt&amp;gt;nethack-3.4.3/sys/unix/unixunix.c&amp;lt;/tt&amp;gt; contains the source for [[Unix]]. If there is a &amp;lt;tt&amp;gt;SHELL&amp;lt;/tt&amp;gt; environment variable, then NetHack will start that program, else NetHack will attempt to run &amp;lt;tt&amp;gt;/bin/sh&amp;lt;/tt&amp;gt;. In most shells, the &amp;lt;tt&amp;gt;exit&amp;lt;/tt&amp;gt; command will then return you to NetHack. Since most Unix now have job control, you could just press Control-Z to suspend NetHack and return to the calling shell instead of starting a subshell; for that reason some players may never think to use the shell escape.&lt;br /&gt;
&lt;br /&gt;
[[Category:Commands]]&lt;/div&gt;</summary>
		<author><name>Kernigh</name></author>
		
	</entry>
</feed>