User Tools

Site Tools



Well, check you package manger or direct from source:



Use a nice gtk2 theme (I use BleuFear)


Everything is done through ~/.gmrunrc

# gmrun configuration file
# gmrun is (C) Mihai Bazon, <>
# GPL v2.0 applies

# Set terminal
Terminal = urxvt
TermExec =
AlwaysInTerm = ssh telnet ftp lynx mc vi vim perldoc man htop task cal dfc

# Set window geometry (except height)
Width = 600
Top = 300
Left = 450

# History size
History = 256

# Shows last history line selected when invoked
ShowLast = 1

# Show files starting with '.'
# Default is 0 (off), set it to 1 if you want "hidden" files to show up
# in the completion window
ShowDotFiles = 0

# Timeout (in milliseconds) after which gmrun will simulate a TAB press
# Set this to NULL if do not like this feature.
TabTimeout = 0

# URL handlers
# If the entered text is "" then:
#   - %u gets replaced with the whole URL ("")
#   - %s gets replaced with "//".  This is useful for URL-s
#     like "man:printf" --> %s will get replaced with "printf"
URL_http = chromium %u
URL_g = firefox ''
URL_d = firefox ''
URL_mailto = thunderbird -compose "to=%s"
URL_man = ${TermExec} 'man %s'
URL_info = ${TermExec} 'info %s'
URL_pd = ${TermExec} 'perldoc %s'
URL_file = emelfm2 %s
URL_readme = ${TermExec} 'less /usr/doc/%s/README'
URL_info = ${TermExec} 'info %s'
URL_sh = sh -c '%s'
URL_paci = ${TermExec} 'pacman -S %s'
URL_pacs = ${TermExec} 'pacman -Ss %s'
URL_aur = firefox ''

# extension handlers
EXT:doc,rtf = lowriter %s
EXT:txt,cc,cpp,h,java,html,htm,epl,tex,latex,js,css,xml,xsl,am,php,css,js,py,rb = ${TermExec} vim %s
EXT:mpeg,mpg,avi,mkv,flv = vlc %s
EXT:mp3,ogg,m4a,wmv,wma = play %s
EXT:ps = gv %s
EXT:pdf = acroread %s Script

In order to launch a terminal command from gmrun and yet see the result (is you type ls /home, a terminal appears and closes directly – awesome), I tweaked a bit a script.
There was two ways:

  • Using -hold parameter but then the terminal is useless and has to be killed/closed
  • Find a way to get back the prompt afterwards - for this I created the following script and make it executable and in the PATH
# Launcher script
exec urxvt -e bash -c "$COMMAND; bash"

FIXME Give a proper nice name to the window and resource name to be automatically places and skinned

Fvwm - Integration

By default gmrun is closed after launching a command.
I workaround it using FvwmButton (works only under FVWM):

# Small Launcher that never dies (as default …) - works good with gtk-theme-bleufear
Style "FvwmLauncher" !Handles, !Title, Sticky, !Borders, WindowListSkip
DestroyModuleConfig FvwmLauncher: *
*FvwmLauncher: Geometry 605x60+10+10
*FvwmLauncher: Background black
*FvwmLauncher: Rows 1
*FvwmLauncher: Columns 1
*FvwmLauncher: Frame 0
*FvwmLauncher: (1x1, Swallow (UseOld,Respawn) "Gmrun" 'Exec exec gmrun')
DestroyFunc StartFvwmLauncher
AddtoFunc StartFvwmLauncher
+ I Module FvwmButtons FvwmLauncher
+ I Wait FvwmLauncher
+ I Next (FvwmLauncher) State 1 True
DestroyFunc ToggleFvwmLauncher
AddToFunc ToggleFvwmLauncher
+ I None (FvwmLauncher) StartFvwmLauncher
+ I TestRc (NoMatch) All (FvwmLauncher,State 1) AnimatedMove +10p +10p ewmhiwa
+ I TestRc (Match) All (FvwmLauncher) Focus
+ I TestRc (Match) All (FvwmLauncher) WarpToWindow 10 50
+ I TestRc (NoMatch) All (FvwmLauncher) AnimatedMove +10p -$[vp.height]p ewmhiwa
+ I Next (FvwmLauncher) State 1 toggle
# Application launcher (Win + r)
Key R A 4 ToggleFvwmLauncher



software/gui/gmrun.txt · Last modified: 2021/12/29 20:09 by warnaud