Skip to content

Categories:

Win32 Perl Scripts

Note, my current setup doesn’t seem to like code much – so bear with me if there are missing backslashes, or other oddities. I’m currently figuring out where to put these files so that I can just link to them

Change Desktop Win32 – Change your desktop to a random picture. The path ($path) below should be set to where you have images which you want to have randomly on your desktop (and only those files). You’ll need the CPAN package ‘Win32::API’.

The problem I’ve had with this script is that it doesn’t seem to work properly outside of the Cygwin/Bash interactive shell.

Clipboard to Browser URL Win32 – Open Clipboard URL in your browser with a Hotkey. This perl snip will read your clipboard, and open your default browser with that URL.

This might need the package ‘Win32::Clipboard’, but that package might be included in Win32::API. If you put this in a shortcut which is on your desktop or in your start menu, you can assign a hotkey (like ctrl+alt+shift+o) and it will launch this automatically. Using the rundll32, it wont leave the commandline window open.

This new version also uses the CGI::Untaint library, specifically CGI::Untaint::url (which is a seperate package). This lets it pretty generally do URLs, http, https, ftp, mailto, etc.

Posted in Coding.


0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.



Some HTML is OK

or, reply to this post via trackback.