View previous topic :: View next topic |
Author |
Message |
audiodef Watchman


Joined: 06 Jul 2005 Posts: 6451 Location: /usr/lib64/lv2
|
Posted: Sat Jan 02, 2016 3:37 pm Post subject: How do I copy menu entries to new Xfce4 user? |
|
|
Is it possible to copy all the Xfce4 menu entry settings to a non-home directory somewhere and then run a script to copy those settings to any new user created? The reason I'm looking to do this is because I'm setting up a default user for Gentoo Studio with custom menu entries that make more sense in the audio/mixing/mastering world than the default category assignments, and I'd like those to persist for new users created on a Gentoo Studio system. _________________ Gentoo Studio: A Gentoo-based, professional digital audio workstation OS. |
|
Back to top |
|
 |
ct85711 Veteran

Joined: 27 Sep 2005 Posts: 1791
|
Posted: Sat Jan 02, 2016 5:01 pm Post subject: |
|
|
Hopefully this will help you, but the files that you are looking for is the .menu and .desktop files. From my understanding of the files, the .menu files specifies the menu structure, and the .desktop defines the menu options. Now the fun part in all this, they are not all stored in the same place. For user specific .menu, is (for me, in xfce4) is located in Code: | ct85711@Oate ~/.local $ locate .menu
/etc/xdg/menus/xfce-applications.menu
/etc/xdg/menus/xfce-settings-manager.menu
/home/ct85711/.config/menus/xfce-applications.menu
/home/ct85711/.config/menus/applications-merged/xdg-desktop-menu-dummy.menu
|
The .desktop files are located in Code: | ct85711@Oate ~/.local $ locate .desktop
/etc/xdg/autostart/Gentoo-print-applet.desktop
...
/etc/xdg/autostart/xscreensaver.desktop
/home/ct85711/.config/autostart/tracker-miner-fs.desktop
...
/home/ct85711/.config/autostart/xfce4-panel.desktop
/home/ct85711/.gnome/apps/calibre-ebook-edit.desktop
...
/home/ct85711/.gnome/apps/chrome-pjkljhegncpnkpknbcohdijeoejaedia-Default.desktop
/home/ct85711/.local/share/Trash/info/exo-file-manager.desktop.trashinfo
/home/ct85711/.local/share/applications/calibre-ebook-edit.desktop
/home/ct85711/.local/share/applications/calibre-ebook-viewer.desktop
...
/usr/share/applications/CMake.desktop
...
/usr/share/applications/blueman-adapters.desktop
|
|
|
Back to top |
|
 |
audiodef Watchman


Joined: 06 Jul 2005 Posts: 6451 Location: /usr/lib64/lv2
|
Posted: Sat Jan 02, 2016 5:47 pm Post subject: |
|
|
Cool. So I can find all the files I need. Now how would I write a script that automatically executes the first time a new user logs in to copy the files I need so that the new user's menu appears the way I want it to? _________________ Gentoo Studio: A Gentoo-based, professional digital audio workstation OS. |
|
Back to top |
|
 |
Syl20 Guru


Joined: 04 Aug 2005 Posts: 568 Location: France
|
Posted: Mon Jan 04, 2016 10:14 am Post subject: |
|
|
When you create a new user, all the files located in /etc/skel are copied into its home directory. You could add there a script that destructs itself, and is called by .bashrc (with a test -f command, to avoid errors when removed), for example.
I think there are cleaner solutions, but that will do the job. |
|
Back to top |
|
 |
audiodef Watchman


Joined: 06 Jul 2005 Posts: 6451 Location: /usr/lib64/lv2
|
Posted: Mon Jan 04, 2016 4:11 pm Post subject: |
|
|
I'll try that, thanks! _________________ Gentoo Studio: A Gentoo-based, professional digital audio workstation OS. |
|
Back to top |
|
 |
|