<div class="gmail_quote">On 9 November 2011 13:48, Rafael Barbosa <span dir="ltr"><<a href="mailto:rrbarbosa@gmail.com">rrbarbosa@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div>After months (maybe years?) of using ipython, I just realized that it does not "see" the alias I define in my .bash_profile. For instance, I made an alias to rm="rm -i", but executing: '!rm a-file' inside ipython does not ask for confirmation. Is this expected? Is there a way around it?</div>
</blockquote><div><br>If you're in the terminal, we use Python's os.system call, which I believe will call the default platform shell (what you get if you run 'sh' - typically not bash). In the Qt console (or other frontends), the call doesn't go through a shell at all.<br>
<br>You might want to look at how to define aliases in IPython:<br><br><a href="http://ipython.org/ipython-doc/stable/interactive/reference.html#system-command-aliases">http://ipython.org/ipython-doc/stable/interactive/reference.html#system-command-aliases</a><br>
<br>Thomas<br></div></div><br>