Skip to content

Commit

Permalink
Update for .net 8.0. Added additional instructions to readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
ThreeSevenths committed Nov 21, 2023
1 parent e0562dd commit 010d838
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 17 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal
- name: Publish
run: dotnet publish
2 changes: 2 additions & 0 deletions NoSleep.sln
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{F8C0ABFE-D352-47A0-90BA-4DA36A354F26}"
ProjectSection(SolutionItems) = preProject
.github\workflows\dotnet.yml = .github\workflows\dotnet.yml
LICENSE.txt = LICENSE.txt
README.md = README.md
EndProjectSection
EndProject
Global
Expand Down
7 changes: 6 additions & 1 deletion NoSleep/NoSleep.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<PublishAot>true</PublishAot>
</PropertyGroup>

<ItemGroup>
<Folder Include="Properties\" />
</ItemGroup>

</Project>
26 changes: 25 additions & 1 deletion NoSleep/Program.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,28 @@
using System;
/*
* THE MIT LICENSE
*
* Copyright 2018 TREVOR DAVIS
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*
*/
using System;

namespace NoSleep
{
Expand Down
13 changes: 0 additions & 13 deletions NoSleep/Properties/PublishProfiles/Net45Release.pubxml

This file was deleted.

19 changes: 18 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
NoSleep
# NoSleep

A simple utiltity to prevent Windows from entering idle and sleeping. Useful while working on a PC but not actively using it.

## Getting and Compiling NoSleep

You can easily clone the repository with something similar to

```
git clone https://github.com/ThreeSevenths/NoSleep.git
```

To build the solution

```
cd NoSleep/NoSleep
dotnet restore
dotnet build
dotnet publish
```

0 comments on commit 010d838

Please sign in to comment.