Skip to content

Commit

Permalink
Extend the functions further. (#24)
Browse files Browse the repository at this point in the history
* Extend the functions further

* Update README.md

* Update directory.build.props

* Update from preview of net 8 to release
  • Loading branch information
ChrisPulman authored Nov 24, 2023
1 parent f389a54 commit 02e66fe
Show file tree
Hide file tree
Showing 8 changed files with 467 additions and 53 deletions.
20 changes: 2 additions & 18 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: Build

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand All @@ -16,34 +14,20 @@ jobs:
outputs:
nbgv: ${{ steps.nbgv.outputs.SemVer2 }}
steps:
- name: Get Current Visual Studio Information
shell: bash
run: |
dotnet tool update -g dotnet-vs
echo "-- About RELEASE --"
vs where release
- name: Update Visual Studio Latest Release
shell: bash
run: |
echo "-- Update RELEASE --"
vs update release Enterprise
vs modify release Enterprise +mobile +desktop +uwp +web
echo "-- About RELEASE Updated --"
vs where release

- name: Checkout
uses: actions/[email protected]
with:
fetch-depth: 0
lfs: true

- name: Install .NET Core
- name: Setup .NET 6/7/8
uses: actions/[email protected]
with:
dotnet-version: |
6.0.x
7.0.x
8.0.x
- name: NBGV
id: nbgv
Expand Down
27 changes: 3 additions & 24 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,34 +16,20 @@ jobs:
outputs:
nbgv: ${{ steps.nbgv.outputs.SemVer2 }}
steps:
- name: Get Current Visual Studio Information
shell: bash
run: |
dotnet tool update -g dotnet-vs
echo "-- About RELEASE --"
vs where release
- name: Update Visual Studio Latest Release
shell: bash
run: |
echo "-- Update RELEASE --"
vs update release Enterprise
vs modify release Enterprise +mobile +desktop +uwp +web
echo "-- About RELEASE Updated --"
vs where release

- name: Checkout
uses: actions/[email protected]
with:
fetch-depth: 0
lfs: true

- name: Install .NET Core
- name: Setup .NET 6/7/8
uses: actions/[email protected]
with:
dotnet-version: |
6.0.x
7.0.x
8.0.x
- name: NBGV
id: nbgv
Expand All @@ -54,15 +40,8 @@ jobs:
- name: NuGet Restore
run: dotnet restore
working-directory: src

- name: Build
run: dotnet build --configuration=${{ env.configuration }} --verbosity=minimal --no-restore
working-directory: src

- uses: nuget/setup-nuget@v1
name: Setup NuGet

- name: Pack
- name: Build and Pack
run: dotnet pack --configuration=${{ env.configuration }} --verbosity=minimal --no-restore
working-directory: src

Expand Down
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,36 @@

## Overview
Extensions for concerns found in System.Reactive that make consuming the library and using it to build an application easier.

## The library contains the following extensions

### `ReactiveMarbles.Extensions`

#### `ReactiveExtensions`

- WhereIsNotNull
- AsSignal
- SyncTimer
- BufferUntil
- CatchIgnore
- CombineLatestValuesAreAllFalse
- CombineLatestValuesAreAllTrue
- GetMax
- GetMin
- DetectStale
- Conflate
- Heartbeat
- WithLimitedConcurrency
- OnNext
- ObserveOnSafe
- Start
- ForEach
- ScheduleSafe
- FromArray
- Using
- While
- Schedule
- Filter
- Shuffle
- OnErrorRetry
- TakeUntil
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public void GivenNull_WhenDisposeWith_ThenExceptionThrown()
var sut = Disposable.Create(() => { });

// When
var result = Record.Exception(() => sut.DisposeWith(null));
var result = Record.Exception(() => sut.DisposeWith(null!));

// Then
result
Expand Down
4 changes: 4 additions & 0 deletions src/ReactiveMarbles.Extensions/DisposableExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,14 @@ public static class DisposableExtensions
public static T DisposeWith<T>(this T item, CompositeDisposable compositeDisposable)
where T : IDisposable
{
#if NETSTANDARD
if (compositeDisposable is null)
{
throw new ArgumentNullException(nameof(compositeDisposable));
}
#else
ArgumentNullException.ThrowIfNull(compositeDisposable);
#endif

compositeDisposable.Add(item);
return item;
Expand Down
Loading

0 comments on commit 02e66fe

Please sign in to comment.