Skip to content

Commit

Permalink
Merge pull request #59 from joular/develop
Browse files Browse the repository at this point in the history
1.0.2
  • Loading branch information
adelnoureddine authored Jul 8, 2024
2 parents 579fe89 + 1841a2b commit 1cb2359
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 5 deletions.
2 changes: 1 addition & 1 deletion alire.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "powerjoular"
description = "Monitoring the power consumption of multiple platforms and processes"
version = "1.0.1"
version = "1.0.2"

authors = ["Adel Noureddine"]
maintainers = ["Adel Noureddine <[email protected]>"]
Expand Down
2 changes: 1 addition & 1 deletion installer/aur/PKGBUILD
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Maintainer: Adel Noureddine <[email protected]>
pkgname=powerjoular
pkgver=1.0.1
pkgver=1.0.2
pkgrel=1
pkgdesc="PowerJoular allows monitoring power consumption of multiple platforms and processes."
arch=('x86_64' 'aarch64' 'armv7h')
Expand Down
5 changes: 4 additions & 1 deletion installer/powerjoular.spec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Name: powerjoular
Version: 1.0.1
Version: 1.0.2
Release: 1%{?dist}
Summary: PowerJoular allows monitoring power consumption of multiple platforms and processes.

Expand All @@ -22,6 +22,9 @@ install -m 644 %{SOURCE1} $RPM_BUILD_ROOT/%{_sysconfdir}/systemd/system/%{name}.
%{_sysconfdir}/systemd/system/%{name}.service

%changelog
* Thu Jul 08 2024 Adel Noureddine <[email protected]> - 1.0.2-1
- Handle exceptions for invalid command line arguments
- Add doc for VM in -h command
* Thu Jul 04 2024 Adel Noureddine <[email protected]> - 1.0.1-1
- Fix RPi 5 detection
* Thu Jun 20 2024 Adel Noureddine <[email protected]> - 1.0.0-1
Expand Down
2 changes: 1 addition & 1 deletion release-version.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

VERSION=1.0.1
VERSION=1.0.2

# First cross compiler

Expand Down
4 changes: 3 additions & 1 deletion src/help_info.adb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ with Ada.Characters.Latin_1; use Ada.Characters.Latin_1;

package body Help_Info is

Version_Number : constant String := "1.0.1";
Version_Number : constant String := "1.0.2";

procedure Show_Help is
begin
Expand All @@ -39,6 +39,8 @@ package body Help_Info is
Put_Line (HT & "-o filename: save only last monitoring data to the given filename path (file overwritten with only latest power measures)");
Put_Line (HT & "-t: print data to the terminal");
Put_Line (HT & "-l: use linear regression models (less accurate than the default polynomial models) for Raspberry Pi energy models");
Put_Line (HT & "-m: specify a filename for the power consumption of the virtual machine");
Put_Line (HT & "-s: specify the format of the VM power, either powerjoular format (generated with the -o option: 3 columns csv file with the 3rd containing the power consumption the VM), or watts format (1 column containing just the power consumption of the VM)");
Put_Line ("You can mix options, i.e., powerjoular -tp 144 --> monitor PID 144 and will print to the terminal");
Put_Line ("--------------------------");
Put_Line (ESC & "[93m" & "Daemons/Systemd service:" & ESC & "[0m");
Expand Down
4 changes: 4 additions & 0 deletions src/powerjoular.adb
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,10 @@ begin
exit;
end case;
end loop;
exception
when Invalid_Switch | Invalid_Parameter =>
Put_Line ("Invalid command line option, or option not used properly.");
OS_Exit (0);

if (Argument_Count = 0) then
Show_Terminal := True;
Expand Down

0 comments on commit 1cb2359

Please sign in to comment.