Skip to content

Commit

Permalink
Merge branch 'Dev-2.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
gbakeman committed Nov 15, 2023
2 parents c12aace + b33d486 commit 3df38df
Show file tree
Hide file tree
Showing 153 changed files with 64,073 additions and 71,520 deletions.
56 changes: 56 additions & 0 deletions .github/workflows/build-validate.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: build-debug

defaults:
run:
working-directory: WinNUT_V2

on:
workflow_dispatch:
pull_request:
branches: [ main, Dev-2.2 ] # Build for dev primarily, probably don't need main...?
paths:
- '**.vb'
- '**.vbproj'

env:
DOTNET_VERSION: '4.8' # The .NET SDK version to use
SLN_FILE: WinNUT_V2.sln
DEBUG_OUTPUT: WinNUT_V2/WinNUT-Client/bin/Debug

jobs:
build:

name: debug-build-${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-2019] # Should have MSBuild.
steps:
# Make MSBuild available from $PATH.
- name: setup-msbuild
uses: microsoft/[email protected]

- name: Checkout Code
uses: actions/checkout@v3

- name: Restore Packages
run: msbuild -t:restore

# msbuild cannot handle .vdproj Installer projects, so only build debug for now.
- name: Build solution
run: msbuild $env:SLN_FILE -p:Configuration=Debug

# For now, let msbuild continue autogenerating assembly versions and base everything off of that.
- name: Get AssemblyVersion generated by msbuild
id: getversion
uses: berglie/assembly-version/get@v1
with:
directory: ${{ env.DEBUG_OUTPUT }}

- name: Upload Artifact
uses: actions/upload-artifact@v3
with:
name: ${{ format('WinNUT-Client-debugbuild-v{0}', steps.getversion.outputs.version) }}
if-no-files-found: error
path: ${{ env.DEBUG_OUTPUT }}

95 changes: 35 additions & 60 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,90 +1,65 @@
# WinNUT-Client
WinNUT is a WinForms client for connecting to a Network UPS Tools monitoring server.

[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/donate?hosted_button_id=FAFJ3ZKMENGCU)
- 📈 Monitor important values of your UPS like voltage and power consumption
- 🌩️ Receive notifications for abnormal power conditions (power outage)
- ❤️ Keep your hardware and data safe with configurable suspend and shutdown triggers

## Installation
To use it, please follow the following steps:
1. Get the [last available Releases](https://github.com/gawindx/WinNUT-Client/releases)
2. Install WinNUT-Client using the "WinNUT-Setup.msi" file obtained previously
3. If you were using an older version of WinNUT (v1.x), copy your "ups.ini" configuration file to the WinNUT-Client installation directory (by default "C:\Program Files(x86)\WinNUT-Client ") for an automatic import of your parameters during the first launch
4. Start WinNUT V2 and modify the parameters according to your needs

## Specific Configuration
<br />
<br />

### For Synology NAS
If your NUT server is hosted on a Synology NAS, be sure to provide the following connection information (default):
Login: upsmon
Password: secret
# Future development
WinNUT has gone through a long evolution with several different programming languages and maintainers. The time has come to retire this iteration of WinNUT and begin planning for the next version. See [issue #40](https://github.com/nutdotnet/WinNUT-Client/issues/40) for more information. Join in the discussions at [Coco.Nut](https://github.com/nutdotnet/Coco.Nut), and shape the future of the next iteration of WinNUT.

It will probably be necessary to allow the WinNUT-Client IP to communicate with the NUT server.
*See issue 47 for more information, specifically [this commentary](https://github.com/gawindx/WinNUT-Client/issues/47#issuecomment-759180793).*

###
## Translation
WinNUT-Client V2 is natively multilingual, so it is no longer necessary to select your language from the software interface.
Currently, WinNUT-Client supports:
- English
- German
- French
- Simplified Chinese
- Russian
# Installation
1. Get the [latest Release](https://github.com/nutdotnet/WinNUT-Client/releases)
2. Install WinNUT using the downloaded executable
3. If you were using an older version of WinNUT (v1.x), copy your "ups.ini" configuration file to the WinNUT-Client installation directory (by default "C:\Program Files(x86)\WinNUT-Client ") for an automatic import of your parameters during the first launch
4. Start WinNUT and modify the settings according to your needs

#### To add / correct a language
## Synology NAS
If you are connecting to a Synology NAS with a UPS attached, there is some additional configuration that needs to be done.

##### Method 1 (preferred)
1. Fork this repository
2. In the translation directory:
Referring to the [Synology documentation](https://kb.synology.com/en-us/DSM/help/DSM/AdminCenter/system_hardware_ups?version=7), note that you must add your client computer's IP address to the *Permitted DiskStation Devices* window. In addition, WinNUT requires the following settings:

For a new translation:
1. Use the new_translation.csv file to translate the texts
2. Save this file in xx-XX corresponding to the language code
- **Login**: upsmon
- **Password**: secret
- **UPS Name**: ups

For a correction:
1. Edit the wrong language file
2. Make the necessary corrections

3. Save it instead
4. Create a pull request on this repository to take into account the translation.
*See [issue 47](https://github.com/gawindx/WinNUT-Client/issues/47#issuecomment-759180793) for more information.*

##### Method 2
1. Get the file [new_translation.csv](./Translation/new_translation.csv)
2. Perform the necessary translations
3. Save this file in csv format (IMPORTANT)
4. Create a gist via [gist github](https://gist.github.com) and paste the contents of the previously created csv file
5. Open a new issue and tell me:
- the link of the gist
- the language to create / correct
## QNAP NAS
If your NUT server is hosted on a QNAP NAS, be sure to provide the following connection information (default):

Your translation / correction will be added on a new version and will thus be available to the entire community.
- **UPS Name**: qnapups
- (Login and Password can be empty)

## Update WinNUT-Client
Also check the "Enable network UPS master" box on the Control Panel -> External device page on the QNAP webinterface and add the IP address of the WinNUT-Client to allow the client to connect to the QNAP for UPS information.

Since version 1.8.0.0, WinNUT-Client includes a process for checking for updates.
This process can be started automatically on startup or manually on demand (and you can choose whether you want to update from the stable or development version)
# Contributing
- [Translations](https://github.com/nutdotnet/WinNUT-Client/wiki/Translations)
- [Code/Bug fixes](https://github.com/nutdotnet/WinNUT-Client/wiki/Development)

During this update, the new installation file will be automatically downloaded and you can easily update your version of WinNUT-Client.
# Updates

This process is fully integrated and no longer requires a second executable.
WinNUT has built-in update functionality. This process can be started automatically on startup or manually on demand, and you can choose whether you want to update to the stable or development version. During this process, the new files will be automatically downloaded and installed.

## Third Party Components / Acknowledgments

WinNUT-Client uses:
WinNUT uses:
- a modified version of AGauge initially developed by [Code-Artist](https://github.com/Code-Artist/AGauge) and under [MIT license](https://opensource.org/licenses/MIT)
- Class IniReader developed by [Ludvik Jerabek](https://www.codeproject.com/Articles/21896/INI-Reader-Writer-Class-for-C-VB-NET-and-VBScript) and under [The Code Project Open License](http://www.codeproject.com/info/cpol10.aspx)
- Newtonsoft.Json Library is used in this Project [Newtonsoft.json Website](https://www.newtonsoft.com/json) and under [MIT license](https://opensource.org/licenses/MIT)

## License

WinNUT-Client is a NUT windows client for monitoring your ups hooked up to your favorite linux server.
Copyright (C) 2019-2021 Gawindx (Decaux Nicolas)

- Copyright (C) 2019-2021 Gawindx (Decaux Nicolas)
- Copyright (C) 2022+ NUT Dot Net project

This program is free software: you can redistribute it and/or modify it under the terms of the
GNU General Public License as published by the Free Software Foundation, either version 3 of the
License, or any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY

## Donation
If you want to support this project or reward the work done, you can do so here:

[![paypal](https://www.paypalobjects.com/en_US/FR/i/btn/btn_donateCC_LG.gif)](https://www.paypal.com/donate?hosted_button_id=FAFJ3ZKMENGCU)
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY.
Loading

0 comments on commit 3df38df

Please sign in to comment.