Skip to content
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

Update the Samples (v6) #1479

Merged
merged 3 commits into from
Dec 29, 2024
Merged

Conversation

lipchev
Copy link
Collaborator

@lipchev lipchev commented Dec 28, 2024

  • projects converted to Sdk style
  • added a new Directory.Packages for the Samples folder and updated the references to the latest (working) versions
  • minor fixes to the UnitConverter.Wpf

- projects converted to Sdk style
- added a new Directory.Packages for the Samples folder and updated the references to the latest (working) versions
- minor fixes to the UnitConverter.Wpf
@lipchev
Copy link
Collaborator Author

lipchev commented Dec 28, 2024

I've been experimenting (locally) with the following trick:

  1. I've added another Nuget.config with two package sources: one for https://api.nuget.org/v3/index.json and one for ../Artifacts/NuGet
  2. In the project properties I add a condition (for now this is simply $(Configuration)' != 'Release' ) in which I override the UnitsNet package version: <PackageReference Include="UnitsNet" VersionOverride="6.0.0-pre012" />
  3. Building the main solution using the build script generates the nuget with it's pre-release version which is then picked up by the Samples projects that have these conditions (I'm not sure how to avoid hard-coding the pre-release version number)

I'm not sure if this is going to work on the build server, so after this is merged- I thought I'd give it a try and see what happens.. Ideally, along with the godzilla PR I was hoping to introduce a new project in the samples called UnitsNetSetup.Configuration, targeting the pre-release nuget (that should hopefully get build on the server), in which I showcase the new features, regarding the different configuration options, extending with custom units etc..

- Remove `CommonServiceLocator` nuget, use `Prism.Ioc.ContainerLocator.Container` instead
- Remove implicit `Unity.Container` nuget, bundled by `Prism.Unity`
- Upgrade nugets, remove version overrides
<PackageVersion Include="Prism.Wpf" Version="7.1.0.431" />
<PackageVersion Include="Unity.Abstractions" Version="5.11.7" />
<PackageVersion Include="Unity.Container" Version="5.8.11" />
</ItemGroup>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was a little bit on the fence on this one, since sample apps are so varied and use so little common code, but then again they are rarely touched and this may just help manage upgrades a little bit. We can keep it.

<HintPath>..\..\packages\Prism.Wpf.7.1.0.431\lib\net45\Prism.Wpf.dll</HintPath>
</Reference>
<Reference Include="System" />
<!-- managing these dependencies is a nightmare -->
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have no experience with these nugets, seems weird we need to override to specific versions and not just use latest defined in Directory.Packages.props?
Or is Directory.Packages.props not supported in this project?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay I think I figured out a solution where we can upgrade all nugets and fix the dependency issue, see 0f552b9.

Also added solution files for scripts and .props file.

On a related note, fuck WPF and particularly fuck XAML. What a trainwreck to work with.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, come on.. I love WPF. They just need to update the XAML to the latest specs, and fix those 20 year old issues with CollectionChanged and what not.. 😄

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

..and we'll be good for another 20 years..

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nooo

@angularsen angularsen merged commit 8164326 into angularsen:release/v6 Dec 29, 2024
1 check was pending
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants