AdBlock.ini auto updater

Iron Forum for english speaking people

Post Reply
ilboso
Posts: 11
Joined: Mon Nov 09, 2009 10:19 am

AdBlock.ini auto updater

Post by ilboso »

Hello everybody!
Since I didn't find anything around, I wrote a little program to automatically download adblock.ini and I want to share it.

Instructions:
  • download the attached file update_adblock.zip
  • unzip it
  • open update_adblock.vbs with your favorite text editor (Notepad works well)
  • near the top of the file, modify "source" and "destination" parameters to match your directories

    Code: Select all

    
    ' -----------------------------------------------------------------------------
    ' PARAMETERS
    ' -----------------------------------------------------------------------------
    const source = "http://fanboy.co.nz/adblock/iron/adblock.ini"
    const destination = "C:\Program Files (x86)\SRWare Iron\adblock.ini"
    ' -----------------------------------------------------------------------------
    
    
  • put the file in any directory of your choice
  • double click it!
  • if it's all ok, you can schedule it with Windows built-in scheduler!
hope it's useful! :D
You do not have the required permissions to view the files attached to this post.
jerrytouille
Posts: 23
Joined: Sun Feb 28, 2010 12:08 am

Re: AdBlock.ini auto updater

Post by jerrytouille »

This is GREAT!

Is there a way to add a custom list/block of filter texts to the updated adblock.ini automatically?
jerrytouille
Posts: 23
Joined: Sun Feb 28, 2010 12:08 am

Re: AdBlock.ini auto updater

Post by jerrytouille »

an error in Win7: "Permission denied"
User avatar
SRWare
Site Admin
Posts: 3247
Joined: Sat Jan 19, 2008 4:16 am

Re: AdBlock.ini auto updater

Post by SRWare »

jerrytouille wrote:an error in Win7: "Permission denied"
You have to configure the schedule so that it runs as admin, otherwise it can't write to Programs-Folder
Iron-Updates via Twitter: http://twitter.com/srware

Donations via Paypal and Bitcoin:
http://iron-start.com/spenden.php
jerrytouille
Posts: 23
Joined: Sun Feb 28, 2010 12:08 am

Re: AdBlock.ini auto updater

Post by jerrytouille »

SRWare wrote:
jerrytouille wrote:an error in Win7: "Permission denied"
You have to configure the schedule so that it runs as admin, otherwise it can't write to Programs-Folder
Actually I tried to test it first by changing the "destination" location and run it, but there is no "Run As Admin" in the right click menu :|
negated
Posts: 28
Joined: Sun Mar 07, 2010 9:31 pm

Re: AdBlock.ini auto updater

Post by negated »

That code needs to be changed to the following for people using a x86 (32-bit) OS:

Code: Select all


' -----------------------------------------------------------------------------
' PARAMETERS
' -----------------------------------------------------------------------------
const source = "http://fanboy.co.nz/adblock/iron/adblock.ini"
const destination = "C:\Program Files\SRWare Iron\adblock.ini"
' -----------------------------------------------------------------------------

ilboso wrote:Hello everybody!
Since I didn't find anything around, I wrote a little program to automatically download adblock.ini and I want to share it.

Instructions:
  • download the attached file update_adblock.zip
  • unzip it
  • open update_adblock.vbs with your favorite text editor (Notepad works well)
  • near the top of the file, modify "source" and "destination" parameters to match your directories

    Code: Select all

    
    ' -----------------------------------------------------------------------------
    ' PARAMETERS
    ' -----------------------------------------------------------------------------
    const source = "http://fanboy.co.nz/adblock/iron/adblock.ini"
    const destination = "C:\Program Files (x86)\SRWare Iron\adblock.ini"
    ' -----------------------------------------------------------------------------
    
    
  • put the file in any directory of your choice
  • double click it!
  • if it's all ok, you can schedule it with Windows built-in scheduler!
hope it's useful! :D
ilboso
Posts: 11
Joined: Mon Nov 09, 2009 10:19 am

Re: AdBlock.ini auto updater

Post by ilboso »

jerrytouille wrote:This is GREAT!

Is there a way to add a custom list/block of filter texts to the updated adblock.ini automatically?
Thanks!
uhm... I'm not sure I understood your question... :)
You want to download more than one file?
ilboso
Posts: 11
Joined: Mon Nov 09, 2009 10:19 am

Re: AdBlock.ini auto updater

Post by ilboso »

jerrytouille wrote:
SRWare wrote:
jerrytouille wrote:an error in Win7: "Permission denied"
You have to configure the schedule so that it runs as admin, otherwise it can't write to Programs-Folder
Actually I tried to test it first by changing the "destination" location and run it, but there is no "Run As Admin" in the right click menu :|
Can you run it with double-click?
If not, try to modify "destination" to a folder you're sure you can write to, maybe your documents folder.
:)
ilboso
Posts: 11
Joined: Mon Nov 09, 2009 10:19 am

Re: AdBlock.ini auto updater

Post by ilboso »

negated wrote:That code needs to be changed to the following for people using a x86 (32-bit) OS:
Thanks for the explanation! :D
negated
Posts: 28
Joined: Sun Mar 07, 2010 9:31 pm

Re: AdBlock.ini auto updater

Post by negated »

ilboso wrote:
negated wrote:That code needs to be changed to the following for people using a x86 (32-bit) OS:
Thanks for the explanation! :D
Ha, yeah...it's kind of obvious but just wanted to get it out there.

Maybe you can add an if/else in your code that checks for architecture and runs the appropriate line?
Post Reply