summaryrefslogtreecommitdiffstats
path: root/pg_list_updater.sh
blob: 005aa370c48c7dfe27dd42fd235edbd9ab00d599 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/bin/sh
#----------------------------------------------------
# Version:      0.1.0
# Author:       Florian "Bluewind" Pritz <f-p@gmx.at>
#
# Copyright (C) 2008-2009 Florian Pritz
#
# Licensed under GNU General Public License v3
#   (see COPYING for full license text)
#    
#----------------------------------------------------
# download current blocklist and extract 
#----------------------------------------------------

failed() {
	notify-send -t 10000 -u critical "Updater" "PG list NOT updated!"
}
finished(){
	notify-send -t 10000  "Updater" "PG list update sucessfully"
}

cd $HOME/stuff/
wget http://peerguardian.sourceforge.net/lists/p2p.php -O level1.7z &&
7z x level1.7z &&
cat level1 | grep -vi moviex.info > p2p.pg &&
finished ||
failed

rm "level1.7z"
rm "level1"