Ask HN: Which recurring tasks have you automated?
From time to time, we might do some tasks that could easily be automated.
Knowing programmers, they could spend a lot of time automating boring repitive tasks.
So i'm wondering, what tasks have you automated and how much time does it save you?
31 comments
[ 3.0 ms ] story [ 73.6 ms ] threadI have a script that extracts our database of clients and checks their pagerank through their mail (of any contact) or the "website" field.
The pagerank gets saved in the clients "internal note" field
https://github.com/NicoJuicy/GetPageRankWinForms/blob/master...
You get the PageRank by this:
PS. First github published project :-)It ain't that clean though, it was never supposed to be on Github.
Perhaps i'll clean up some code later. It was just fast development ;)
If you work with Windows, this is a really awesome tool.
I use powershell to automaticly update multiple databases to the latest migration (but that's mostly because i'm using Entity Framework with .Net projects).
It would be great if, in the future, Powershell could be used for web automation. They already have WatiN, but you need to use C# to use it. While that is no problem, it would be great to be able to use Powershell for that as well.
There have been times when I have been working on a feature, and have noticed that the CMS content on local/staging is out of date with what is on live.
To fix this, I created a Powershell script to create a backup of the live db, copy it over to the staging server, backup the old db and restore the live db on staging, and to do the same on the local database. It's a bit awkward, but I wanted a one-click method that would sync all three databases, while ensuring that it would fail gracefully and would create backups in case something went wrong.
This works well for my personal projects, but I am looking to rewrite it for work at some point. I work at an agency, so a tool that can sync our db servers would be fantastic.
I have an XML which contains the different servers (testing, dev and production).
I'd just type UpdateDatabases -T in package manager console :)=> so testing servers are updated with the latest migration
It's a CLI Python script that copies templates to your desired location and asks you for replacement values. It works with regular expressions as well as strings and executes commands after cloning (e.g. initiate a git repo). It works of course for any language and any framework.
I started open-sourcing it and adding some things that will be useful for more people (e.g. files/folders to exclude, i18n, developer output, multiple template paths, install/setup script, etc.).
Is it template specific (eg. Bootstrap?)
I'm planning to make it a "Show HN" post once it's more or less tested and ready for others to check out.
I installed AutoHotKey (take that corporate security!) and over a few weeks wrote up a script that would let you supply an excel file with summarised stats about the orders you had that day. It would then physically automate the rest of the process using mouse/keyboard macros, like the office equivalent of a player piano.
It even had a little finite-state machine that knew where it was in the production system. For each order it knew where it had to be, and thus it could get from/to every other area of the production system by sending simulated keyboard/mouse-clicks.
I don't care what anyone says, sure an actual program would have been faster, but that wasn't an option.
In full flight it was awesome to behold. Like all the promises of labour saving technology made manifest! Of course, I soon learnt that labour saving was not the point of a corporation, but for the next few months until I quit, it was pretty cool...
For AutoIT you actually have a forum with a lot of scripts available: http://www.autoitscript.com/forum/forum/9-example-scripts/
So I run two instances of mysql, one is PROD and the other is read only replication. I can backup the read only replicated mysql instance without having to stop anything in production.
I am looking into the same for my nosql db's right now.
Regards,
resizing images i'd receive from clients for their websites to a standard size. it just runs through the folder and resizes.
image manipulation to add borders
automating a continuous integration environment, built a website where developers could enter ticket details and a front end component they require delivered to the lab, which then kicks off the build, makes the components and uploads to the client's server and sends mail
db2 package creation by looking up files on a unix filesystem and providing them to the dba's packaging tool
and everything i install i typically have a bash script for.
Currently, I have a Python script for format-converting and reapplying textures after an export from 3DS Max to an abandonware project called Mach Studio Pro, and I'm working on something similar to sort out opacity problems between Daz3D and Octane Render.
I've also made heavy use of a 3rd party script to mash converted World of Warcraft levels into a usable format for Max.
A prior version was a simple python script that ran as a cronjob but it needed lot of hand-holding as it would run at times when the filer was too heavy, and it was annoying to babysit it all the time esp. at odd hours.
The new version used snmp data from the filer to 'gauge' how idle or busy it was (as a feedback loop), and it would self-throttle or 'accelerate' itself in various stages as necessary. Saved the company a lot of grief in storage costs, and it ran like a charm with with hardly human intervention. It kept various stats and logs which could be queried as needed. Also saved a lot of time for other engineers/ops on-call team to focus on other areas.
Looking back at it, it used some crude mathematical models to gauge the busyness of the filer, but this portion was designed to be plugable and independent of how the filesystem was being crawled.
This simple program (set up as a forever loop daemon) got me thinking on autonomous agents and 'self-healing' software in general but never had time to pursue it in a more academic setting.