<div dir="ltr">After looking at this and the code more, I find myself very against this feature. This adds code to core that is performing a tasks that most people already know is handled by their shell. Even our Windows users can install PowerShell and have aliases for commands. This adds no benefit to core, it adds more complexity, and attempts to perform a task that is already well handled by the users shell. If anything, this itch could be scratched by adding some contrib documentation about some of your favourite and/or most used aliases.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Oct 26, 2015 at 10:51 AM, Wayne Witzel <span dir="ltr"><<a href="mailto:wayne.witzel@canonical.com" target="_blank">wayne.witzel@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">What is the advantage of this over using a standard alias in my shell profile?<br></div><div class="gmail_extra"><div><div class="h5"><br><div class="gmail_quote">On Fri, Oct 23, 2015 at 11:05 AM, Aaron Bentley <span dir="ltr"><<a href="mailto:aaron.bentley@canonical.com" target="_blank">aaron.bentley@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">bzr has a similar feature, but the problem with such a feature is that<br>
it can break scripts that expect the normal behaviour. That's why bzr<br>
provides a --no-aliases option, which all scripts calling bzr should use.<br>
<br>
The same applies to Juju. If "status" gets defaulted to "status<br>
--format=tabular", most of our test scripts will break. This isn't<br>
likely to happen on our test machines, but could easily happen when<br>
devs run our test scripts.<br>
<br>
Could you please provide a similar --no-aliases option for juju, so<br>
that we can ensure people don't break our scripts by specifying<br>
surprising defaults?<br>
<br>
Thanks,<br>
<br>
Aaron<br>
<div><div><br>
On 2015-10-23 12:12 AM, Tim Penhey wrote:<br>
> Hi folks,<br>
><br>
> I scratched a personal itch yesterday and added the ability for<br>
> users to specify their own aliases for juju commands.<br>
><br>
> There are two primary use cases that I was trying to address.<br>
><br>
> Firstly, the ability to specify default flags for commands: status<br>
> = status --format=tabular<br>
><br>
> I could never remember the right environment variable to set to<br>
> get tabular by default.<br>
><br>
> The second was to allow quicker iteration around playing with new<br>
> CLI structure. As most people are aware, the 2.0 CLI is going to<br>
> be somewhat different to the current one, and I thought it would be<br>
> good to provide a way in which we could "test drive" the new CLI<br>
> with the existing codebase without having to actually code<br>
> anything.<br>
><br>
> The aliases files lives in JUJU_HOME, and is a simple text file.<br>
> Each non blank line that doesn't start with a '#' is considered to<br>
> be an alias. The format is expected to be:<br>
><br>
> <command> = <command> [<args>...]<br>
><br>
> So we can do things like:<br>
><br>
> # stat is like two whole letters shorter... stat = status<br>
> --format=tabular<br>
><br>
> # list tests list-environments = system environments list-users =<br>
> user list<br>
><br>
> and so on.<br>
><br>
> Tim<br>
><br>
<br>
--<br>
Juju-dev mailing list<br>
<a href="mailto:Juju-dev@lists.ubuntu.com" target="_blank">Juju-dev@lists.ubuntu.com</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/juju-dev" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailman/listinfo/juju-dev</a><br>
</div></div></blockquote></div><br><br clear="all"><br></div></div><span class="HOEnZb"><font color="#888888">-- <br><div><div dir="ltr"><div>Wayne Witzel III</div><div><a href="mailto:wayne.witzel@canonical.com" target="_blank">wayne.witzel@canonical.com</a></div></div></div>
</font></span></div>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr"><div>Wayne Witzel III</div><div><a href="mailto:wayne.witzel@canonical.com" target="_blank">wayne.witzel@canonical.com</a></div></div></div>
</div>