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

feat(scope): make Abstractions layer #131

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
dotnet-version: 8.0.x
- name: Build
env:
HUSKY: 0
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/publush.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
Expand All @@ -28,6 +28,12 @@ jobs:
PROJECT_FILE_PATH: src/Gridify/Gridify.csproj
INCLUDE_SYMBOLS: true
NUGET_KEY: ${{secrets.NUGET_API_KEY}}
- name: Publish Gridify.Abstractions
uses: alirezanet/[email protected]
with:
PROJECT_FILE_PATH: src/Gridify.Abstractions/Gridify.Abstractions.csproj
INCLUDE_SYMBOLS: true
NUGET_KEY: ${{secrets.NUGET_API_KEY}}
- name: Publish Gridify.EntityFramework
uses: alirezanet/[email protected]
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pullRequest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
Expand Down
3 changes: 1 addition & 2 deletions .husky/csx/version-updater.csx
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ Usage example:
*/

var paths = new[] {
@"src\Gridify\Gridify.csproj",
@"src\Gridify.EntityFramework\Gridify.EntityFramework.csproj",
@"root.props",
@"docs\.vuepress\configs\version.ts"
};

Expand Down
25 changes: 25 additions & 0 deletions docs/guide/abstractions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Abstractions

Gridify.Abstraction includes a set of interface and classes that act like contract with other libraries to use it without referencing gridify package itself.

its include:

- `GridifyQuery`
- `Paging`
- `IGridifyQuery`
- `IGridifyPagination`
- `IGridifyFiltering`
- `IGridifyOrdering`


### Package Manager

``` pm:no-line-numbers:no-v-pre
Install-Package Gridify.Abstactions -Version {{ $version }}
```

### .NET CLI

``` pm:no-line-numbers:no-v-pre
dotnet add package Gridify.Abstactions -Version {{ $version }}
```
6 changes: 4 additions & 2 deletions docs/guide/getting-started.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

# Getting Started

There are three packages available for gridify in the nuget repository.
Expand All @@ -12,7 +11,10 @@ If you are using the Entity framework in your project, you should install the `G

This package has the same functionality as the `Gridify` package, but it is designed to be more compatible with [Entity Framework](./entity-framework.md).

In order to use Gridify with Elasticsearch it's necessary to install `Gridify.Elasticsearch`. Please read [the separate thread of the documentation](./elasticsearch/getting-started.md).
In order to use Gridify with Elasticsearch it's necessary to install `Gridify.Elasticsearch`. Please
read [the separate thread of the documentation](./elasticsearch/getting-started.md).

[Gridify.Abstraction](abstractions.md) includes a set of interface and classes that act like contract with other libraries to use it without referencing gridify package itself.
:::

## Installation
Expand Down
15 changes: 15 additions & 0 deletions gridify.sln
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Gridify.Elasticsearch", "sr
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Gridify.Elasticsearch.Tests", "test\Gridify.Elasticsearch.Tests\Gridify.Elasticsearch.Tests.csproj", "{08E66DC6-A741-49D2-978B-E644EF3A5BA8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Gridify.Abstractions", "src\Gridify.Abstractions\Gridify.Abstractions.csproj", "{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -157,6 +159,18 @@ Global
{08E66DC6-A741-49D2-978B-E644EF3A5BA8}.Release|x64.Build.0 = Release|Any CPU
{08E66DC6-A741-49D2-978B-E644EF3A5BA8}.Release|x86.ActiveCfg = Release|Any CPU
{08E66DC6-A741-49D2-978B-E644EF3A5BA8}.Release|x86.Build.0 = Release|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Debug|x64.ActiveCfg = Debug|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Debug|x64.Build.0 = Debug|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Debug|x86.ActiveCfg = Debug|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Debug|x86.Build.0 = Debug|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Release|Any CPU.Build.0 = Release|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Release|x64.ActiveCfg = Release|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Release|x64.Build.0 = Release|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Release|x86.ActiveCfg = Release|Any CPU
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{CDFDBB16-1D9F-40FD-B693-96D1D4FB79EE} = {1BBCBA37-25E5-4BFF-A8E8-7EE582E0317F}
Expand All @@ -169,5 +183,6 @@ Global
{7C6699E7-7B6E-48D4-920F-6DD3568FBFD9} = {1BBCBA37-25E5-4BFF-A8E8-7EE582E0317F}
{21A86C33-1E72-4771-9C40-73EF9A21AFD5} = {0FCD2937-1953-465E-8608-42B8EB8757C7}
{08E66DC6-A741-49D2-978B-E644EF3A5BA8} = {1BBCBA37-25E5-4BFF-A8E8-7EE582E0317F}
{A0EE419D-7E37-4AC9-B204-0F6C23E33BF9} = {0FCD2937-1953-465E-8608-42B8EB8757C7}
EndGlobalSection
EndGlobal
25 changes: 25 additions & 0 deletions root.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<Project>
Copy link
Owner

Choose a reason for hiding this comment

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

we can also use this props file, for Gridify.Elasticsearch package

<PropertyGroup>
<Version>2.12.0</Version>
<Authors>Alireza Sabouri</Authors>
<Company>TuxTeam</Company>
<RepositoryUrl>https://github.com/alirezanet/Gridify</RepositoryUrl>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<LangVersion>latest</LangVersion>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Nullable>enable</Nullable>
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<PackageReadmeFile>README.md</PackageReadmeFile>
<TargetFrameworks>net5.0;net6.0;netstandard2.0;netstandard2.1;net7.0;net8.0</TargetFrameworks>
</PropertyGroup>

<PropertyGroup>
<EnableNETAnalyzers>true</EnableNETAnalyzers>
<AnalysisMode>Recommended</AnalysisMode>
</PropertyGroup>
</Project>
10 changes: 10 additions & 0 deletions src/Gridify.Abstractions/Gridify.Abstractions.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\root.props"/>
<PropertyGroup>
<PackageId>Gridify.Abstractions</PackageId>
<PackageDescription>Gridify.Abstractions, includes a set of interface and classes that act like contract.</PackageDescription>
</PropertyGroup>
<ItemGroup>
<None Include="..\..\README.md" Pack="true" PackagePath="\"/>
</ItemGroup>
</Project>
File renamed without changes.
File renamed without changes.
File renamed without changes.
17 changes: 2 additions & 15 deletions src/Gridify.EntityFramework/Gridify.EntityFramework.csproj
Original file line number Diff line number Diff line change
@@ -1,22 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\root.props" />

<PropertyGroup>
<PackageId>Gridify.EntityFramework</PackageId>
<Version>2.12.0</Version>
<Authors>Alireza Sabouri</Authors>
<Company>TuxTeam</Company>
<PackageDescription>Gridify (EntityFramework), Easy and optimized way to apply Filtering, Sorting, and Pagination using text-based data.</PackageDescription>
<RepositoryUrl>https://github.com/alirezanet/Gridify</RepositoryUrl>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<PackageReadmeFile>README.md</PackageReadmeFile>
<TargetFrameworks>net5.0;net6.0;netstandard2.0;netstandard2.1;net7.0</TargetFrameworks>
<LangVersion>default</LangVersion>
<Nullable>enable</Nullable>
</PropertyGroup>

<ItemGroup>
Expand Down
19 changes: 2 additions & 17 deletions src/Gridify/Gridify.csproj
Original file line number Diff line number Diff line change
@@ -1,28 +1,13 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\root.props" />

<PropertyGroup>
<PackageId>Gridify</PackageId>
<Version>2.12.0</Version>
<Authors>Alireza Sabouri</Authors>
<Company>TuxTeam</Company>
<PackageDescription>Gridify, Easy and optimized way to apply Filtering, Sorting, and Pagination using text-based data.</PackageDescription>
<RepositoryUrl>https://github.com/alirezanet/Gridify</RepositoryUrl>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<LangVersion>latest</LangVersion>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Nullable>enable</Nullable>
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<PackageReadmeFile>README.md</PackageReadmeFile>
<TargetFrameworks>net5.0;net6.0;netstandard2.0;netstandard2.1;net7.0</TargetFrameworks>

</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\Gridify.Abstractions\Gridify.Abstractions.csproj" />
<None Include="..\..\README.md" Pack="true" PackagePath="\" />
</ItemGroup>

Expand Down
Loading