first commit. dokuwiki.
[h2N7SspZmY.git] / data / cache / 5 / 5461232adf7bfe6598373011ae44ce88.xhtml
blob2ed10c2aeb04b203443f2bfbd8c2fb7b3f96990a
4 <h1><a name="bash" id="bash">Bash</a></h1>
5 <div class="level1">
7 </div>
8 <!-- SECTION "Bash" [1-20] -->
9 <h2><a name="escape_characters_association" id="escape_characters_association">Escape Characters Association</a></h2>
10 <div class="level2">
12 <p>
14 Sometimes you can&#039;t send a program some characters association (e.g. Ctrl+S) because the bash window intercepts then. In order to the program to work correctly, you must remove this character association from bash. Here is an example:
15 </p>
16 <pre class="code bash"><span class="co0"># see escape characters association</span>
17 $ <span class="kw2">stty</span> <span class="re5">-a</span>
18 <span class="co0"># shows ... ; stop = ^S; ...</span>
19 <span class="co0"># let's associate stop to Ctrl+Q</span>
20 $ ssty stop ^Q
21 <span class="co0"># now CTRL-S will be passed to the program running inside the bash</span></pre>
23 </div>
24 <!-- SECTION "Escape Characters Association" [21-510] -->
25 <h2><a name="changing_bash_configuration" id="changing_bash_configuration">Changing Bash Configuration</a></h2>
26 <div class="level2">
28 <p>
30 The file ~/.bashrc is read and executed every time you open bash. So if you want that a configuration change (like stty) to be true the next time you open bash, you must append it to the ~/.bashrc. Here is an example code:
31 </p>
32 <pre class="code bash"><span class="co0"># append to ~/.bashrc</span>
33 $ <span class="kw3">echo</span> <span class="st_h">'stty stop ^Q'</span> <span class="sy0">&gt;&gt;</span> ~<span class="sy0">/</span>.bashrc</pre>
35 </div>
36 <!-- SECTION "Changing Bash Configuration" [511-853] -->
37 <h2><a name="using_same_bash_configuration_file_on_many_pcs" id="using_same_bash_configuration_file_on_many_pcs">Using Same Bash Configuration File on Many PCs</a></h2>
38 <div class="level2">
40 <p>
42 If order to use the same configuration file on many PCs (e.g. your work and you home), you can include your main file on the ~/.bashrc of those PCs. Example:
43 </p>
44 <pre class="code bash"><span class="co0"># append to ~/.bashrc (do this on each PC)</span>
45 $ <span class="kw3">echo</span> <span class="st_h">'source /path/to/your/main/configuration/file/.bashrc'</span> <span class="sy0">&gt;&gt;</span> ~<span class="sy0">/</span>.bashrc</pre>
47 </div>
48 <!-- SECTION "Using Same Bash Configuration File on Many PCs" [854-] -->