@zaxebo1, thanks for the link!
I've modified it to this:
```bash
#!/bin/sh

socket=`xprop -root _NET_CURRENT_DESKTOP`
socket=${socket##* }

if [ "$socket" ]
then
    if [ "$DISPLAY" ]
    then
        socket="${DISPLAY%.*}-$socket"
        socket=${socket#*:}
    else
        socket="NODISPLAY-$socket"
    fi
    exec /usr/bin/geany --socket-file "/tmp/geany_socket_$socket" "$@"
else
    exec /usr/bin/geany "$@"
fi
```

Then I've saved it as `~/.local/bin/geany`, made it executable and added 
`~/.local/bin` to PATH.

SInce in Ubuntu `geany.desktop` uses simply `geany` instead of full path, all 
file types associations now use this new script as well as direct execution 
from menu. Works wonderfully, finally proper replacement for slow gedit.

IMHO, this should be the default behavior.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/1025#issuecomment-386770780

Reply via email to