I have been lurking around the forums for awhile, and have used a lot of things that have been posted. I wanted to give something back instead of just taking. So I decided to post this.
I got the idea for this from Aeriwen's post on how to Automate the Downloading of TUJ Addon Updates, which I had used for awhile,. However, didn't like having to extract the file as I tend to forget. I built off this idea of using the Task Scheduler to keep the addon updated, but added more of automation to it using a batch file.
1. Programs you will need to have.
7Zip - file archiver
WGet - file retriever from most widely-used Internet protocols
Both programs are free to download and use. They work on both Windows and Linux. Sorry I don't use Mac so not sure if they have them for Macs.
2. What this guide will show you to do.
I am doing this in Windows 7 64bit.
In short, what I have it set up to do is the Task Scheduler runs a *.bat file. The batch file will download the Update using WGet. Check to see if the new file was downloaded, delete the old zip file and rename the new one. It will then use 7zip to extract and override the old folder in the AddOns directory (similar idea to what the CurseClient does for other AddOns).
This could probably be done a lot cleaner, but my (and my husband's) skill level and the time we did this in, this is what we have and it works.
3. Setting up your batch file.
This can be written in Notepad, so no need to get another software. You can name your batch file anything and place it anywhere, but you will want to put it in a place you won't be moving it around or deleting it. I saved mine as autoTUJ.bat and placed it in my AddOns folder.
In a Notepad document you will want to copy and paste the following:
Next, you will need to make some changes to the file to link to the pathings on your computer for the software.Code:@echo off set path="C:\World of Warcraft\Interface\AddOns" call "C:\Program Files (x86)\GnuWin32\bin\wget.exe" -N --no-check-certificate "http:\\your.addon.link.goes.here" if exist TheUndermineJournal.zip@* (del TheUndermineJournal.zip) else echo Error downloading data ren TheUndermineJournal.zip@* TheUndermineJournal.zip call "C:\Program Files (x86)\7-Zip\7z.exe" x -aoa "C:\World of Warcraft\Interface\AddOns\TheUndermineJournal.zip"
Replace the "http:\\your.addon.link.goes.here" with the link provided to you from TUJ where it says "Download Your Addon Here." Paste the update link between the quotes. You can right click on the link and select Copy Link Location. Then ctrl + V in between the quotes.
Save your batch file after you make the changes you need. You're batch file is complete!
4. How to set up the scheduler.
This set is a bit similar to what Aeriwen did. However, I did go about it a bit differently.
Open Task Scheduler. For those who can't find it: Start > Accessories > System Tools > Task Scheduler
You are going to want to Create Task... to start with. I prefer not using the wizard because I would have to go in and edit it anyways.
Under the General tab you will want to name the Task. I named mine something like "The Undermine Journal Updater". You will also want to make sure you check Run with highest privileges. You can also set it to run if you aren't logged into your account (ie share your computer), but I don't so not messing with it.
Under the Triggers tab, I have set it to happen daily starting at 12AM and to recur every day. I have also set the tasks to run every 6 hours Indefinitely. This allows for me to get updated information without hitting my 10 downloads a day limit. You can change this to better match your gaming time so it updates before you log in. As I sleep weird hours throughout the month it's just best to keep it as is for myself as I never really sure when I might be on.
Next under the Action tab, you'll want to set your action to Start a program. Use the Browse... button in the Program/script to select your batch file. Mine is autoTUJ.bat and I had placed it in my AddOns folder for easy access and so I don't have to worry about if I deleted it or not. Then in the Start in (optional): put the path to the folder your batch file is located in. For example, mine is K:\World of Warcraft \Interface\AddOns\ .
There rest of the tabs are default settings, which seem to work fine for me. You may want to look through them and make sure for yourself. When you are finished Save and you are done.
As mentioned before probably not the cleanest way to go about it, but it does seem to get the job done. Hope this helps some of you guys out.
Thank you Aeriwen, for the idea of using Task Scheduler for updating The Undermine Journal AddOn UpDates.