<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle21
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='color:#1F497D'>As far as I understand it, wpkg would inherently do what you want.<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Once p_1, p_2 and p_3 are all managed packages (i.e., added to wpkg.xml), future runs of wpkg would look at the profile. As long as p_1 is in the profile, all three packages remain (p_1 because it is explicitly listed, and p_2 and p_3 because they are dependencies).<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>When you remove p_1 from the profile, wpkg would not find any of the three packages mentioned in the profile, but still find them in wpkg.xml. Thus it will then remove these packages.<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Or maybe I’m mistaken about this.<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal style='margin-left:.5in'><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> wpkg-users-bounces@lists.wpkg.org [mailto:wpkg-users-bounces@lists.wpkg.org] <b>On Behalf Of </b>Andy Welch<br><b>Sent:</b> Thursday, October 14, 2010 7:00 PM<br><b>To:</b> wpkg-users@lists.wpkg.org<br><b>Subject:</b> [wpkg-users] Question: chained removals ?<o:p></o:p></span></p></div></div><p class=MsoNormal style='margin-left:.5in'><o:p> </o:p></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>Hi all<o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>If p_1 is uninstalled, can I cause the prerequisistes p_2 and p_3 to be uninstalled also if no other package depends on them?<o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>  <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>package</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>id</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>p_1</span>"<span style='color:blue'>><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>depends</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>package-id</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>p_2</span>"<span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>depends</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>package-id</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>p_3</span>"<span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>install</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>cmd</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>blah blah</span>"<span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>remove</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>cmd</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>moo moo</span>"<span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>  </</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>package</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>><o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>How about the following:-<o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>package</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>id</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>p_1</span>"<span style='color:blue'>><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>depends</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>package-id</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>p_2</span>"<span style='color:blue'> </span><b><u><span style='color:red'>chainremove</span><span style='color:blue'>=</span>"<span style='color:blue'>yes</span>"</u></b><span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>depends</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>package-id</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>p_3</span>"<span style='color:blue'> </span><b><u><span style='color:red'>chainremove</span><span style='color:blue'>=</span>"<span style='color:blue'>yes</span>"</u></b><span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>install</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>cmd</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>blah blah</span>"<span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in;text-autospace:none'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>    <</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>remove</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'> </span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:red'>cmd</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>=</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New"'>"<span style='color:blue'>moo moo</span>"<span style='color:blue'> /><o:p></o:p></span></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>  </</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:#A31515'>package</span><span lang=EN-NZ style='font-size:10.0pt;font-family:"Courier New";color:blue'>></span><span lang=EN-NZ><o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>This would require the application being ‘aware’ that packages “p_2” and “p_3” are no longer prerequisites for any other package – I’ll take a look at wpkg.js to see if this is supported.<o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>Is there any other way to achieve this?  <o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>Thx<o:p></o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:.5in'><span lang=EN-NZ>Andy Welch.<o:p></o:p></span></p></div></body></html>