Clear Old Combat Logs from SWTOR

If you parse combat while playing SWTOR using Orbs (Old Republic: Battle Parse) or StarParse, you may have a buildup of old combat logs. StarParse & Orbs give warnings about the number and size of logs in the combat log folder, but it doesn’t delete old entries for you. I wrote a small PowerShell script that is run daily via Task Scheduler that deletes combat logs older than a number of days. I use 7 days myself, but it could even be 1 day because I’ve never gone back and looked at a log that old.

# Define the folder path and the age threshold (in days)
$folderPath = "C:\Path\to\your\CombatLogs"
$daysThreshold = 7

# Get the current date and calculate the threshold date
$currentDate = Get-Date
$thresholdDate = $currentDate.AddDays(-$daysThreshold)

# Get all files in the folder older than the threshold date
$filesToDelete = Get-ChildItem -Path $folderPath -File | Where-Object { $_.LastWriteTime -lt $thresholdDate }

# Delete each file
foreach ($file in $filesToDelete) {
    try {
        Remove-Item -Path $file.FullName -Force
        # (optional) Write-Output "Deleted file: $($file.FullName)"
    } catch {
        Write-Output "Failed to delete file: $($file.FullName). Error: $_"
    }
}

$folderPath: Your combat logs are typically located in your Documents folder, specifically: “C:\Users\[username]\OneDrive\Documents\Star Wars – The Old Republic\CombatLogs”

$daysThreshold: The number of days to keep combat logs before deletion

Running the Script Daily

To run this script daily, you can create a scheduled task in Windows Task Scheduler:

  1. Open Task Scheduler:
    You can find it by searching for “Task Scheduler” in the Windows start menu.
  2. Create a New Task:
    • Select “Create Basic Task”.
    • Name your task and give it a description.
    • Choose “Daily” for the trigger.
    • Set the start date and time for when you want the task to run.
    • Select “Start a Program” for the action.
    • Browse to powershell.exe as the program/script.
    • Add the script file path (e.g., C:\Path\To\Your\Script.ps1) in the “Add arguments” field.

It’s that simple, and you no longer need worry yourself with cleaning up your old useless combat logs.

61 Replies to “Clear Old Combat Logs from SWTOR”

  1. Yet another thing is that while searching for a good on-line electronics shop, look for online shops that are regularly updated, trying to keep up-to-date with the most current products, the top deals, along with helpful information on services and products. This will make sure that you are doing business with a shop which stays ahead of the competition and gives you what you should need to make knowledgeable, well-informed electronics acquisitions. Thanks for the vital tips I’ve learned from your blog.

  2. Unquestionably imagine that which you stated. Your favourite justification seemed to be at the internet the easiest thing to consider of. I say to you, I definitely get annoyed whilst other people think about concerns that they plainly don’t recognize about. You controlled to hit the nail upon the top as smartly as outlined out the whole thing with no need side effect , other folks could take a signal. Will probably be again to get more. Thanks

  3. Good web site! I truly love how it is easy on my eyes and the data are well written. I am wondering how I could be notified whenever a new post has been made. I’ve subscribed to your RSS which must do the trick! Have a nice day!

  4. whoah this blog is magnificent i love reading your articles. Keep up the great work! You know, lots of people are searching around for this information, you could aid them greatly.

  5. I’m truly enjoying the design and layout of your website. It’s a very easy on the eyes which makes it much more enjoyable for me to come here and visit more often. Did you hire out a developer to create your theme? Exceptional work!

  6. This design is steller! You definitely know how to keep a reader amused. Between your wit and your videos, I was almost moved to start my own blog (well, almost…HaHa!) Excellent job. I really enjoyed what you had to say, and more than that, how you presented it. Too cool!

  7. Thanks a lot for sharing this with all of us you really know what you’re talking about! Bookmarked. Kindly also visit my web site =). We could have a link exchange agreement between us!

  8. Good web site! I truly love how it is easy on my eyes and the data are well written. I am wondering how I could be notified whenever a new post has been made. I’ve subscribed to your RSS which must do the trick! Have a nice day!

  9. Greetings from Florida! I’m bored at work so I decided to check out your website on my iphone during lunch break. I enjoy the info you present here and can’t wait to take a look when I get home. I’m amazed at how fast your blog loaded on my cell phone .. I’m not even using WIFI, just 3G .. Anyways, very good site!

  10. This is really attention-grabbing, You’re an excessively professional blogger. I’ve joined your feed and look ahead to in the hunt for more of your excellent post. Additionally, I have shared your web site in my social networks!

  11. Great work! That is the type of information that are supposed to be shared across the internet. Shame on Google for not positioning this publish higher! Come on over and visit my web site . Thank you =)

  12. Right here is the perfect blog for everyone who hopes to find out about this topic. You understand so much its almost hard to argue with you (not that I actually will need to…HaHa). You definitely put a freshspin on a topic that has been written about for decades.Excellent stuff, just great!

  13. I’m not sure if this is a format issue or something to do with internet browser compatibility but I figured I’d post to let you know. The style and design look great though! Hope you get the issue fixed soon. Many thanks

  14. Hello there! I could have sworn I’ve been to this blog before but after checking through some of the post I realized it’s new to me.Anyways, I’m definitely glad I found it and I’ll be bookmarking and checking back frequently!

  15. My partner and I stumbled over here coming from a different page and thought I might check things out. I like what I see so i am just following you. Look forward to finding out about your web page yet again.

  16. The prose carries a reflective patience. It allows ideas to emerge slowly, creating a reading experience that is thoughtful, immersive, and quietly satisfying.

  17. That is a very good tip especially to those new to the blogosphere. Short but very accurate information… Many thanks for sharing this one. A must read article!

  18. It’s genuinely very difficult in this busy life to listen news on Television, so I just use world wide web for that reason, and take the most up-to-date news.

  19. Heya this is kinda of off topic but I was wanting to know if blogs use WYSIWYG editors or if you have to manually code with HTML. I’m starting a blog soon but have no coding know-how so I wanted to get guidance from someone with experience. Any help would be enormously appreciated!

  20. Thanks for discussing your ideas right here. The other factor is that if a problem arises with a personal computer motherboard, folks should not consider the risk regarding repairing it themselves because if it is not done correctly it can lead to permanent damage to all the laptop. It is almost always safe just to approach the dealer of that laptop with the repair of motherboard. They’ve technicians that have an competence in dealing with laptop computer motherboard problems and can carry out the right prognosis and perform repairs.

  21. This is very attention-grabbing, You are an excessively professional blogger.I’ve joined your feed and stay up for in quest of extra of your fantastic post. Also, I have shared your web site in my social networks。

  22. I feel this is one of the such a lot important information for me. And i’m satisfied reading your article. But should observation on some normal issues, The site style is perfect, the articles is actually nice :

  23. I’ve been surfing online more than 3 hours today, yet I never found any interesting article like yours. It’s pretty worth enough for me. Personally, if all webmasters and bloggers made good content as you did, the web will be much more useful than ever before.

  24. Hello There. I found your blog the use of msn. This is a really well written article. I will make sure to bookmark it and come back to read extra of your useful info. Thanks for the post.

  25. Great tip! For folks who don’t use PowerShell often, you might also include a batch file / files example (Windows) for deleting older logs, or even a script for *nix (if someone runs the logs on Wine). That way more readers can pick the variant that works for them.

  26. I recently checked my “CombatLogs” folder (enabled via Preferences → Combat Logging) and found it had ballooned to multiple GBs over just a month. Your approach will definitely help me keep things from getting out of control. Thanks for this!

  27. I’m glad you shared that PowerShell + Task Scheduler approach, automating the cleanup is such a time saver. I use 7 days too. Would you ever consider parameterizing the number of days in the script so users can set their own threshold more easily?

Leave a Reply

Your email address will not be published. Required fields are marked *