Compare commits

..

No commits in common. '63152190a89a9b463d7de42fd9fffbd4318f9ce3' and '5aec50e85efa751f19bab154fdd61648978f0c43' have entirely different histories.

  1. 2
      .tito/packages/patrix
  2. 5
      patrix.spec
  3. 22
      scripts/patrix

@ -1 +1 @@
0.1.13-1 ./ 0.1.12-1 ./

@ -1,5 +1,5 @@
Name: patrix Name: patrix
Version: 0.1.13 Version: 0.1.12
Release: 1%{?dist} Release: 1%{?dist}
Summary: Command line client for Matrix Summary: Command line client for Matrix
@ -52,9 +52,6 @@ room via the command line.
%{_bindir}/patrix %{_bindir}/patrix
%changelog %changelog
* Mon Jan 03 2022 Daniel Berteaud <dbd@ehtrace.com> 0.1.13-1
- Check config readability and global /etc/patrixrc (dbd@ehtrace.com)
* Thu Dec 09 2021 Daniel Berteaud <dani@lapiole.org> 0.1.12-1 * Thu Dec 09 2021 Daniel Berteaud <dani@lapiole.org> 0.1.12-1
- Revert requiring LWP::Protocol::connect (dani@lapiole.org) - Revert requiring LWP::Protocol::connect (dani@lapiole.org)

@ -52,29 +52,13 @@ GetOptions(
"perm_reset|reset-permission" => \$opt->{perm_reset} "perm_reset|reset-permission" => \$opt->{perm_reset}
); );
if (!$opt->{conf}){ if (-e File::HomeDir->my_home . "/.patrixrc" && !$opt->{conf}){
# Read global config if it exists and is readable $opt->{conf} = File::HomeDir->my_home . "/.patrixrc";
if (-f '/etc/patrixrc' && open(CONFIG, '<', '/etc/patrixrc')){ debug("Using default config file $opt->{conf}");
$opt->{conf} = '/etc/patrixrc';
close CONFIG;
debug("Using global config file $opt->{conf}");
}
# If there's a user defined config, use it instead
if (-f File::HomeDir->my_home . "/.patrixrc" && open(CONFIG, '<', File::HomeDir->my_home . "/.patrixrc")){
$opt->{conf} = File::HomeDir->my_home . "/.patrixrc";
close CONFIG;
debug("Using default config file $opt->{conf}");
}
} }
if ($opt->{conf} && -e $opt->{conf}){ if ($opt->{conf} && -e $opt->{conf}){
read_conf(); read_conf();
} }
else {
die "No configuration found.\nYou should either create one in ~/.patrixrc " .
"or give the path of a custom config with --config /path/to/patrixrc";
}
# alias for --action=foo is --foo # alias for --action=foo is --foo
my @actions = qw( my @actions = qw(

Loading…
Cancel
Save