<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
On 31/03/2011 18:36, Alex Tomlins wrote:
<blockquote cite="mid:4D94BBA9.80003@unboxedconsulting.com"
type="cite">
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
On 31/03/11 15:29, Alex Tomlins wrote:
<blockquote cite="mid:4D948FC4.3090202@unboxedconsulting.com"
type="cite">
<meta content="text/html; charset=UTF-8"
http-equiv="Content-Type">
On 31/03/11 15:00, Axel Beckert wrote:
<blockquote cite="mid:20110331140059.GD12557@sym.noone.org"
type="cite">
<pre wrap="">Hi Alex,
Alex Tomlins wrote:
</pre>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">
<pre wrap="">I've implemented this here:
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="https://gitorious.org/%7Ealext/xen-tools/alext-xen-tools/commits/apt_proxy">https://gitorious.org/~alext/xen-tools/alext-xen-tools/commits/apt_proxy</a>
</pre>
</blockquote>
<pre wrap="">Thanks!
From a first glance it looks good and I'll probably include your
patches. I'd though change two things:
* Change the option's name from apt_proxy to apt-proxy.
</pre>
</blockquote>
<pre wrap="">Makes sense. I wasn't sure which way to go as the existing options seem
to use a mixture.
</pre>
</blockquote>
<pre wrap="">Well, yeah, historically grown. But I'd prefer to not have underscores
in long options. Maybe we'll once change all of them to dashes, but
supoort underscores for backwards-compatibility.
</pre>
</blockquote>
<br>
</blockquote>
I've realised a problem here... xen-create-image exports all the
config variables as ENV vars so that they're available to the hook
and role scripts. The trouble is that bash doesn't seem to like
variables with - in them, I'm pretty sure it's not valid.<br>
<br>
I guess either they need to all use the _ variant, or when
exporting the environment the names need to be converted to use
the _ variant. That way they'd use the - variant on the
commandline and in the %CONFIG hash, but would use the _ variant
in the %ENV hash, and in hook scripts etc...<br>
<br>
There's even an argument for it to treat - and _ interchangeably
both on the commandline and in the config file.<br>
<br>
I'd be happy to take this on if it's considered a good idea.<br>
<br>
</blockquote>
Ok, I've made a small change to exportEnvironment in
xen-create-image so that it converts - to _ in variable names. This
option now works well as apt-proxy, and is referenced as apt_proxy
within the hook scripts.<br>
<br>
I've pushed this up to my apt_proxy branch on gitorious, and updated
the merge request.<br>
<br>
<br>
thanks,<br>
Alex<br>
<br>
<div class="moz-signature">-- <br>
<table style="width: 98%; margin-top: 10px; font-family:
arial,sans;" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border-bottom: 1px solid black; font-size: 20px;
line-height: 28px; font-family: Trebuchet MS,arial,sans;"
valign="bottom">Alex Tomlins</td>
<td style="border-bottom: 1px solid black;" align="right">
<table style="width: 145px;" align="right" border="0"
cellpadding="0" cellspacing="0" width="145px">
<tbody>
<tr>
<td style="font-family: Trebuchet MS,arial,sans;
font-weight: bold; font-size: 35px; color: rgb(0,
0, 0); letter-spacing: -1px; height: 27px;
line-height: 27px;" align="right" height="27px"
valign="top"> Unboxed </td>
</tr>
<tr>
<td style="font-family: Trebuchet MS,arial,sans;
font-weight: bold; font-size: 30px; color:
rgb(146, 39, 143); letter-spacing: -1px; height:
42px; line-height: 27px;" align="right"
height="42px;" valign="top"> Consulting </td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="border-top: 4px solid white;" align="left"
valign="top">
<table style="font-size: 12px; font-family: arial;"
align="left" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="width: 16px; color: rgb(146, 39, 143);">E:</td>
<td> <a
href="mailto:alex.tomlins@unboxedconsulting.com"
style="color: black; text-decoration: none;">alex.tomlins@unboxedconsulting.com</a></td>
</tr>
<tr>
<td style="width: 16px; color: rgb(146, 39, 143);">M:</td>
<td>+44 7824 696 890</td>
</tr>
<tr>
<td style="width: 16px; color: rgb(146, 39, 143);">T:</td>
<td>+44 20 3137 2930</td>
</tr>
<tr>
<td style="width: 16px; color: rgb(146, 39, 143);">F:</td>
<td>+44 20 7183 4251</td>
</tr>
</tbody>
</table>
</td>
<td style="font-size: 12px; font-family: arial; border-top:
4px solid white;" align="right" valign="top">
<table style="font-size: 12px; font-family: arial;"
align="right" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="right">17 Blossom Street</td>
</tr>
<tr>
<td align="right">London, E1 6PL</td>
</tr>
<tr>
<td align="right">United Kingdom</td>
</tr>
<tr>
<td align="right"><a style="color: rgb(146, 39,
143); text-decoration: none;"
href="http://www.unboxedconsulting.com">www.unboxedconsulting.com</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>