summaryrefslogtreecommitdiffstats
path: root/bin/archweb-login.pl
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2018-02-18 17:12:48 +0100
committerFlorian Pritz <bluewind@xinu.at>2018-02-18 17:12:48 +0100
commit4bdc103664eba676fdee79140595cc7e8063b1eb (patch)
tree7e100d9a6657d0cc4ae1fb11a252b4abefd32e95 /bin/archweb-login.pl
parenta4cc90817a4613654d0e477749c27b3d3cfcdb84 (diff)
downloadarch-mirror-tools-4bdc103664eba676fdee79140595cc7e8063b1eb.tar.gz
arch-mirror-tools-4bdc103664eba676fdee79140595cc7e8063b1eb.tar.xz
Automatically log in when necessary
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'bin/archweb-login.pl')
-rwxr-xr-xbin/archweb-login.pl24
1 files changed, 0 insertions, 24 deletions
diff --git a/bin/archweb-login.pl b/bin/archweb-login.pl
deleted file mode 100755
index d66ecff..0000000
--- a/bin/archweb-login.pl
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/usr/bin/perl
-
-use warnings;
-use strict;
-
-use File::Basename;
-use Config::Tiny;
-use WWW::Mechanize;
-use HTTP::Cookies;
-
-my $Config = Config::Tiny->new();
-$Config = Config::Tiny->read(dirname($0) . "/../settings.conf");
-
-my $cookie_jar = HTTP::Cookies->new(file => dirname($0) . "/../cookie_jar", autosave => 1);
-my $mech = WWW::Mechanize->new(agent => "arch-mirror-tools", cookie_jar => $cookie_jar);
-
-$mech->get("https://www.archlinux.org/login/");
-my $res = $mech->submit_form(
- form_id => "dev-login-form",
- fields => {
- username => $Config->{account}->{username},
- password => $Config->{account}->{password}
- }
-);