[MacPorts] SummerOfCode2014_interactive modified
Page "SummerOfCode2014_interactive" was changed by shasha@macports.org Diff URL: <https://trac.macports.org/wiki/SummerOfCode2014_interactive?action=diff&version=4> Revision 4 Changes: -------8<------8<------8<------8<------8<------8<------8<------8<-------- Index: SummerOfCode2014_interactive ========================================================================= --- SummerOfCode2014_interactive (version: 3) +++ SummerOfCode2014_interactive (version: 4) @@ -71,25 +71,6 @@ }}} -=== Ambiguous activate === -Desc: When port activate command is run ambiguously, give a list of ports to the user to choose from. - -Message: A list of all the port versions/variants of the port name given. - -Question type: A single choice question having multiple options is what is required in this case. The user is asked to choose one of the options. - -Example- -{{{ -$> port activate foobar -The following variants of foobar exist: - foobar @0.0.1 +xzy - foobar @0.0.2 +xzy - foobar @0.1 -Type a number to select the variant to activate: 2 ----> foobar @0.0.2 +xzy activated. -$> -}}} - === Uninstall using -—follow-dependencies === Desc: When a user uninstalls using the flag —-follow-dependencies, ask for confirmation. @@ -110,6 +91,46 @@ ——-> Uninstalling foba @0.1 $> }}} + + +=== Variant specific dependency (Low-priority) === +Desc: When installing a port that requires a dependency to have a certain variant, but this variant is not set. Ask the user if it should reinstall the dependency with that variant. This interaction is currently marked low priority. + +Message: A warning message explaining that reinstalling with a specific variant could break any already-installed dependents that relied on the previously-selected variants. + +Question type: A yes/no question is suitable here. The correct variant will be selected and installed automatically so no need to provide options. + +Example- +{{{ +$> port install foobar +The package 'foobar +quartz' requires 'barfoo +quartz' but 'barfoo' is installed. +Warning: Reinstalling with a specific variant could break any already-installed dependents that relied on the previously-selected variants. +Do you wish to install barfoo +quartz? [Y/n]: Y +---> Installing barfoo @1.0.1 +xzy +——-> Installing foobar +$> +}}} + +=== Choose variants interactively (Low-priority) === +Desc: When installing a port the user can be given a list of all the variants of the port they wish to install and they can select them interactively. This interaction is currently flagged low priority. + +Message: A list of all the variants to choose from. + +Question type: A multiple choice question where the user can select the options they want. Then pressing enter proceeds with the install. + +Example- +{{{ +$> port install foobar +"foobar" has many variants. Which of the following variants do you want to install? + (1) foobar @0.0.1 +xzy + (2) foobar @0.0.2 +xzy + (3) foobar @0.0.3 +Enter a space separated string of choices to select the ports to uninstall: 1 +---> Installing foobar @0.0.1 +xzy +$> +}}} + += Use Cases Completed = === Ambiguous uninstall === Desc: When uninstalling a port if the user supplies an ambiguous name, list all the variants and ask to select the ones that should be uninstalled. @@ -131,44 +152,25 @@ $> }}} -=== Variant specific dependency (Low-priority) === -Desc: When installing a port that requires a dependency to have a certain variant, but this variant is not set. Ask the user if it should reinstall the dependency with that variant. This interaction is currently marked low priority. - -Message: A warning message explaining that reinstalling with a specific variant could break any already-installed dependents that relied on the previously-selected variants. - -Question type: A yes/no question is suitable here. The correct variant will be selected and installed automatically so no need to provide options. - -Example- -{{{ -$> port install foobar -The package 'foobar +quartz' requires 'barfoo +quartz' but 'barfoo' is installed. -Warning: Reinstalling with a specific variant could break any already-installed dependents that relied on the previously-selected variants. -Do you wish to install barfoo +quartz? [Y/n]: Y ----> Installing barfoo @1.0.1 +xzy -——-> Installing foobar -$> -}}} - -=== Choose variants interactively (Low-priority) === -Desc: When installing a port the user can be given a list of all the variants of the port they wish to install and they can select them interactively. This interaction is currently flagged low priority. - -Message: A list of all the variants to choose from. - -Question type: A multiple choice question where the user can select the options they want. Then pressing enter proceeds with the install. - -Example- -{{{ -$> port install foobar -"foobar" has many variants. Which of the following variants do you want to install? - (1) foobar @0.0.1 +xzy - (2) foobar @0.0.2 +xzy - (3) foobar @0.0.3 -Enter a space separated string of choices to select the ports to uninstall: 1 ----> Installing foobar @0.0.1 +xzy -$> -}}} - -= Use Cases Completed = + +=== Ambiguous activate === +Desc: When port activate command is run ambiguously, give a list of ports to the user to choose from. + +Message: A list of all the port versions/variants of the port name given. + +Question type: A single choice question having multiple options is what is required in this case. The user is asked to choose one of the options. + +Example- +{{{ +$> port activate foobar +The following variants of foobar exist: + foobar @0.0.1 +xzy + foobar @0.0.2 +xzy + foobar @0.1 +Type a number to select the variant to activate: 2 +---> foobar @0.0.2 +xzy activated. +$> +}}} === Rebuilding in rev-upgrade === Desc: Before rebuilding any port in rev-upgrade the user will be asked for confirmation. @@ -218,14 +220,11 @@ === ui_* calls === Under ui_ask_ namespace: -ui_ask_yesorno: deals with all the continue/abort type questions - -ui_ask_onechoice: deals with all the single choice selection questions - -ui_ask_manychoice: deals with questions that offer many more than one selections - -ui_ask_timeout: deals with questions that may have better functionality with timeouts - -=== Parameters === -qid: This parameter is most important as it will enable the port client to identify the question and print the correct interactivity case. -(Incomplete) +ui_ask_yesno: deals with all the continue/abort type questions + +ui_ask_singlechoice: deals with all the single choice selection questions + +ui_ask_multichoice: deals with questions that offer many more than one selections + +ui_timeout: deals with yes/no questions that may have better functionality with timeouts + -------8<------8<------8<------8<------8<------8<------8<------8<-------- -- Page URL: <https://trac.macports.org/wiki/SummerOfCode2014_interactive> MacPorts <http://www.macports.org/> Ports system for OS X This is an automated message. Someone added your email address to be notified of changes on 'SummerOfCode2014_interactive' page. If it was not you, please report to .
participants (1)
-
MacPorts