Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
corbob committed Nov 21, 2024
1 parent 78783c6 commit 4f2d698
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public override void configure_argument_parser(OptionSet optionSet, ChocolateyCo
.Add(
"s=|source=",
"Source - Source location for install. Can use special 'webpi' or 'windowsfeatures' sources. Defaults to sources.",
option => configuration.Sources = option.remove_surrounding_quotes())
option => configuration.Sources = configuration.ExplicitSources = option.remove_surrounding_quotes())
.Add(
"l|lo|localonly|local-only",
"LocalOnly - Only search against local machine items.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public virtual void configure_argument_parser(OptionSet optionSet, ChocolateyCon
optionSet
.Add("s=|source=",
"Source - The source to find the package(s) to install. Special sources include: ruby, webpi, cygwin, windowsfeatures, and python. To specify more than one source, pass it with a semi-colon separating the values (e.g. \"'source1;source2'\"). Defaults to default feeds.",
option => configuration.Sources = option.remove_surrounding_quotes())
option => configuration.Sources = configuration.ExplicitSources = option.remove_surrounding_quotes())
.Add("version=",
"Version - A specific version to install. Defaults to unspecified.",
option => configuration.Version = option.remove_surrounding_quotes())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public virtual void configure_argument_parser(OptionSet optionSet, ChocolateyCon
optionSet
.Add("s=|source=",
"Source - Source location for install. Can use special 'webpi' or 'windowsfeatures' sources. Defaults to sources." + deprecationNotice,
option => configuration.Sources = option.remove_surrounding_quotes())
option => configuration.Sources = configuration.ExplicitSources = option.remove_surrounding_quotes())
.Add("l|lo|local|localonly|local-only",
localOnlyDescription,
option => configuration.ListCommand.LocalOnly = option != null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public virtual void configure_argument_parser(OptionSet optionSet, ChocolateyCon
optionSet
.Add("s=|source=",
"Source - The source to find the package(s) to install. Special sources include: ruby, webpi, cygwin, windowsfeatures, and python. To specify more than one source, pass it with a semi-colon separating the values (e.g. \"'source1;source2'\"). Defaults to default feeds.",
option => configuration.Sources = option.remove_surrounding_quotes())
option => configuration.Sources = configuration.ExplicitSources = option.remove_surrounding_quotes())
.Add("u=|user=",
"User - used with authenticated feeds. Defaults to empty.",
option => configuration.SourceCommand.Username = option.remove_surrounding_quotes())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public virtual void configure_argument_parser(OptionSet optionSet, ChocolateyCon
option => configuration.SourceCommand.Name = option.remove_surrounding_quotes())
.Add("s=|source=",
"Source - The source. This can be a folder/file share or an http location. If it is a url, it will be a location you can go to in a browser and it returns OData with something that says Packages in the browser, similar to what you see when you go to https://community.chocolatey.org/api/v2/. Required with add action. Defaults to empty.",
option => configuration.Sources = option.remove_surrounding_quotes())
option => configuration.Sources = configuration.ExplicitSources = option.remove_surrounding_quotes())
.Add("u=|user=",
"User - used with authenticated feeds. Defaults to empty.",
option => configuration.SourceCommand.Username = option.remove_surrounding_quotes())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public virtual void configure_argument_parser(OptionSet optionSet, ChocolateyCon
optionSet
.Add("s=|source=",
"Source - The source to find the package(s) to install. Special sources include: ruby, webpi, cygwin, windowsfeatures, and python. To specify more than one source, pass it with a semi-colon separating the values (e.g. \"'source1;source2'\"). Defaults to default feeds.",
option => configuration.Sources = option.remove_surrounding_quotes())
option => configuration.Sources = configuration.ExplicitSources = option.remove_surrounding_quotes())
.Add("version=",
"Version - A specific version to install. Defaults to unspecified.",
option => configuration.Version = option.remove_surrounding_quotes())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,12 @@ private void append_output(StringBuilder propertyValues, string append)
/// </summary>
public string Sources { get; set; }

/// <summary>
/// One or more source locations set by comamnd line only. Semi-colon delimited.
/// <strong>Do not set this anywhere other than parsing CLI arguments for commands.</strong>
/// </summary>
public string ExplicitSources { get; set; }

public string SourceType { get; set; }

// top level commands
Expand Down

0 comments on commit 4f2d698

Please sign in to comment.