-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Backdoors, GitHub Package Manager, cleanup. #228
Conversation
Fix typos
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
/// <param name="x"></param> | ||
/// <param name="y"></param> | ||
/// <returns></returns> | ||
public int Compare(List<string>? x, List<string>? y) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you do want to do it this way. I would strongly recommend just converting the numbers into numbers before listing them to make this way simpler.
I reread this and it looks like you are comparing actual strings in here not just numbers.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for (int i=0; i<minLength; i++)
{
if (int.TryParse(x[i], out int xInt) &&
int.TryParse(y[i], out int yInt))
{
if (xInt > yInt) return -1;
if (yInt > xInt) return 1;
}
else
{
var compValue = x[i].CompareTo(y[i]);
if (compValue != 0) return compValue;
}
}
If the strings are integers (e.g. the 234
in v1.234.56
and the 78
in v1.78.0
), then it should compare 234 to 78 as integers and show that 234 comes after it.
(Or maybe I missed something.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested and it does not sort integers like that when you pass them as strings. That said the string comparison looks like its only when something is not a number so I think it is OK. My comment was just explaining why I crossed out my initial comment.
> list
List<string>(0) { }
> list.Add("234");
> list.Add("73");
> list.Sort()
> list
List<string>(2) { "234", "73" }
@daalcant Could you take a look at the .csproj files (with me setting |
I'll need to update the build strategy. I think if we build each project individually then do a self-contained build of the solution it will achieve what we're looking for. After I test locally I'll update this PR. |
I added some changes to prepare for updating the pipeline build order. I expect builds to fail until I commit the next set of changes; just checking to make sure that tests run as expected. |
Running into more issues here. Looks like there was a recent breaking change to the way self-contained project references are validated in .NET 5. Going to fiddle with the configurations and the |
@scovetta Builds seem to be working again (for now). Unfortunately I'm pretty sure our setup is unsupported and could break in the future. The .NET docs suggest we shouldn't expect to bundle our executables in a single folder the way we have been, which is why we keep running into problems. I'm open to discuss later but I suppose this is fine for the short term. I performed some basic testing of the framework dependent netcore app and the self-contained Windows and Linux apps. All of the executables run, and I was able to successfully demo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed build items, LGTM
Thanks @daalcant! Merging now. |
This PR has a bunch of updates: