AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

BetterRun 1.0

 
Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
gahks



Joined: 10 Jan 2009
Posts: 32

PostPosted: Sat Sep 26, 2009 7:14 pm    Post subject: BetterRun 1.0 Reply with quote

BetterRun! 1.0

Download exe + source
You can download them separately here, I cannot link them, something to do with the exclamation mark in the name.
Screenshots

Features:
- Launching files, folders, urls, by typing simple short commands in Windows Run, command shell, explorer address bars
- Opening multiple files, folders, urls at the same time
- Ability to pass command line parameters to the files/folders/urls even when mass-launching them (see the example below)

What with all the fancy dock applications I still prefer to use win+r, Windows Run to launch most of my applications, and access some of my files.
To make this easier and faster, first I used batch files: I added a directory to my PATH, and I wrote a batch to open each file or application I used often, and I saved them under two ot three letter names. What I got myself this way, was short commands to access those files and folders. So when I typed, say "np" in Run, it opened Notepad. Well, not an elegant solution, but it worked nonetheless.

This is exactly what this script does, only it's a little more sophisticated, specifically:
- using a Shortcut file, an ini, and the main executable to launch a short command and this way:
- it's capable of launching multiple files, folders, urls at the same time
- it accepts any number of parameters for the added applications/folders/urls
- and it provides an icon-enabled gui to add, edit and delete short commands, relocate the short command directory, back up short commands and load backups, and remove the whole thing from my PC with one click
- it provides a configuration gui for a quick setup.

It's simple stuff, nothing fancy. Old-fasioned ftw!Very Happy

Examples:
Instead of clicking around or typing this in Run:
Code:
"c:\Program Files\Autohotkey\autohotkey.exe"

"d:\XYZ\Programs\Total CommanderX\Totalcmd.exe"

firefox.exe

c:\Folder\Subfolder\Important

"c:\Program Files\Videlan\VLC.exe"

http://somewebsite.com

c:\SoftwareOnC\xampp\apache-start.bat


Open run and type this:
Code:
ahk tc ff if vlc sms xa


And instead of this:
Code:
"c:\Program Files\Autohotkey\autohotkey.exe" d:\somedir\domesubdir\anotherone\thisisascript.ahk -xy -zz -xxx -yyy

"d:\XYZ\Programs\Total CommanderX\Totalcmd.exe" /L="c:\somedir" /R="e:\"

firefox.exe "somesearchstring"

c:\Folder\Subfolder\Important

"c:\Program Files\Videlan\VLC.exe" file://e:\somedir\anotherdir\subdir\media_file.avi

http://somewebsite.com

c:\SoftwareOnC\xampp\apache-start.bat


Open run and type this:
Code:
ahk @d:\somedir\domesubdir\anotherone\thisisascript.ahk&&-xy&&-zz&&-xxx&&-yyy tc @/L="c:\somedir"&&/R="e:\" ff @somesearchstring vlc @file://e:\somedir\anotherdir\subdir\media_file.avi sws xa


You can pass parameters to the launched applications, websites, or folders:
Syntax:
[short command] @[first parameter]&&[second parameter]&&[third parameter] ...etc.

Example:
Let's you've got three short comands: "ggl" for "http://www.google.com/search?q=", "tc" for "Totalcmd.exe" and "dtp" for "Windows Desktop".
When you type this in Windows Run:
Code:
ggl ff dtp

...it will open Google, Windows Desktop and launch Total Commander.

But when you type this:
Code:
ggl @"some search string for google" tc @/L="c:\"&&/R="d:\somedir\subdir" dtp @AnImageOnDesktop.jpg

...it will launch a google search for "some search string for google", open Total Commander with C:\ in its left tab in d:\somedir\subdir in its right tab, and launch the image AnImageOnDesktop.jpg which resides on the Desktop.

Notes:
- it uses current users Path and HKCU to add software subkey to avoid the need for admin rights
- because of this, it's not system-wide, works only for the current user; to change this
- change the sections in the script, where it's adding/reading registry entries to use the system-wide Path variable and HKLM's Software subkey to store script settings (Search for ;REGISTRY! in the script to find registry related sections)
Installation:
- it will create a subkey in HKCU\Software\BetterRun! where it stores settings and add the created/selected BetterRun dir to current users path variable
- every changes on hard drive and in the registry made by BetterRun! can be removed with: "Delete configuration" in the main window
- stored settings are: Configured - 1 or 0, ExecutableName, ShortCommand - the BetterRun executables own short command, ShortCutDir - the location of the short command directory
- I'm using it on both Vista and XP boxes, it seems to be working OK so far
- please post the bugs if you find any

Cheers,

gahks
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group