mirror of
https://github.com/Matir/skel.git
synced 2026-05-25 21:19:09 -07:00
Run autostart .desktop files on i3 login.
This commit is contained in:
16
bin/autostart.py
Executable file
16
bin/autostart.py
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/python
|
||||
"""
|
||||
Launch desktop files from ~/.config/autostart
|
||||
"""
|
||||
|
||||
import glob
|
||||
import os.path
|
||||
from gi.repository import Gio
|
||||
|
||||
dirname = os.path.expanduser('~/.config/autostart')
|
||||
for desktop in glob.glob(os.path.join(dirname, '*.desktop')):
|
||||
try:
|
||||
fp = Gio.DesktopAppInfo.new_from_filename(desktop)
|
||||
except TypeError:
|
||||
continue
|
||||
fp.launch_uris([], None)
|
||||
Reference in New Issue
Block a user