I have a custom launcher that opens a command such as:
leafpad ~/file1.txt
That opens a specific file that I must work on quite often.
Is it possible to adjust the command so that it is aware if the file has already been open in Leafpad, so by pressing it a second time, it just switches to that file and application, instead of opening a new instance?