PersianDateShamsi 1.0.5
See the version list below for details.
dotnet add package PersianDateShamsi --version 1.0.5
NuGet\Install-Package PersianDateShamsi -Version 1.0.5
<PackageReference Include="PersianDateShamsi" Version="1.0.5" />
paket add PersianDateShamsi --version 1.0.5
#r "nuget: PersianDateShamsi, 1.0.5"
// Install PersianDateShamsi as a Cake Addin #addin nuget:?package=PersianDateShamsi&version=1.0.5 // Install PersianDateShamsi as a Cake Tool #tool nuget:?package=PersianDateShamsi&version=1.0.5
Persian Date Library
Persian Data Library is a library that can be convert Gregorian (Milady) year to Solar Hijri (Shamsi) year in simplest way!
Target | Branch | Version |
---|---|---|
Github | master | v1.0.5 |
Persian Date Public Version
Target | Branch | Version | Download link | Total downloads | CI Build Status | CD Build Status |
---|---|---|---|---|---|---|
Nuget | master | v1.0.5 | ||||
Release | master | v1.0.5 |
Cross Platform
Platform | Supported Version |
---|---|
.NET | 8.0 |
Code Example
PersianDateShamsi persianDateShamsi = new PersianDateShamsi();
Console.WriteLine(persianDateShamsi.GetShamsiYear(DateTime.Now));
//Result : 1398
Console.WriteLine(persianDateShamsi.GetShamsiMonthName(DateTime.Now));
//Result : بهمن
Console.WriteLine(persianDateShamsi.GetShamsiDayString(DateTime.Now));
//Result : 03
Console.WriteLine(persianDateShamsi.GetShamsiDayName(DateTime.Now));
//Result : پنجشنبه
Console.WriteLine(persianDateShamsi.GetShamsiDayShortName(DateTime.Now));
//Result : پ
Extension Method For DateTime
Console.WriteLine(DateTime.Now.ToShamsiDate());
//Result : 1398/11/03
Console.WriteLine(DateTime.Now.ToShortShamsiDate());
//Result : 98/11/03
Console.WriteLine(DateTime.Now.ToLongShamsiDate());
//Result : پنجشنبه 3 بهمن 1398
Version changes
Version 1.0.5
-Add support for .Net 8.0
Version 1.0.4
-Add support for .Net 5.0 and 6.0
Version 1.0.3
-Change .Net Standard 2.0 To .NET 7.0
Version 1.0.2
-Improve Flexibility
Version 1.0.1
-Change .Net Standard 2.1 To 2.0 To Support More Platforms
CI Pipeline
The CI pipeline is now integrated into the CD pipeline and is defined in .github/workflows/CD.yml
. It uses macos-latest
as the VM image. The pipeline handles manual triggers, pull requests, and releases. It restores NuGet packages, builds the solution, runs tests, and validates the NuGet package. The pipeline installs .NET version 8.0.x to ensure compatibility with all targeted frameworks.
CD Pipeline
The CD pipeline is defined in .github/workflows/CD.yml
and uses macos-latest
as the VM image. It includes steps for creating, validating, testing, and deploying the NuGet package. The pipeline handles manual triggers, pull requests, and releases. It uses environment variables for the NuGet directory and the latest versions of GitHub Actions for checkout, setup-dotnet, and upload-artifact. The pipeline installs .NET version 8.0.x to ensure compatibility with all targeted frameworks. Additionally, it includes a step to delete existing tags if they already exist before creating a new release to avoid the 'Validation Failed: already_exists' error. The step now handles the case where the tag deletion fails and ensures the deletion step successfully removes the existing tag before proceeding to create a new release.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.8.0 | 126 | 10/3/2024 |
1.3.0 | 114 | 9/12/2024 |
1.2.0 | 96 | 9/12/2024 |
1.0.8 | 100 | 9/12/2024 |
1.0.7 | 90 | 9/12/2024 |
1.0.6 | 96 | 9/12/2024 |
1.0.5 | 94 | 9/12/2024 |
1.0.4 | 345 | 5/16/2023 |
1.0.3 | 151 | 5/16/2023 |
1.0.2 | 953 | 1/24/2020 |
1.0.1 | 449 | 1/24/2020 |
1.0.0 | 537 | 1/23/2020 |
0.0.0-alpha.0.46 | 51 | 9/12/2024 |
0.0.0-alpha.0.45 | 59 | 9/12/2024 |
0.0.0-alpha.0.43 | 54 | 9/12/2024 |
Add support for .Net 8.0