Difference between revisions of "Create a Core Wallet desktop entry on Ubuntu Desktop"

From DigiByte Wiki
Jump to navigation Jump to search
 
(2 intermediate revisions by the same user not shown)
Line 3: Line 3:
 
A desktop entry file is used as a shortcut file. It retains information of a certain script or application on your Ubuntu machine, such as file location, icon, version, type, description etc.[https://specifications.freedesktop.org/desktop-entry-spec/latest/]
 
A desktop entry file is used as a shortcut file. It retains information of a certain script or application on your Ubuntu machine, such as file location, icon, version, type, description etc.[https://specifications.freedesktop.org/desktop-entry-spec/latest/]
 
===Why would you want a entry file?===
 
===Why would you want a entry file?===
You don’t need to start your wallet from the terminal. With a entry file set up you can simply start the DigiByte Core Wallet directly from the Ubuntu application browser.<br />
+
You don’t need to start your wallet from the terminal. With a entry file set up you can simply start the DigiByte Core Wallet directly from the Ubuntu application browser.<br>
 
Using something like Gnome Tweaks you can easily search and pick your desktop entry for autostart when you log in to your machine.
 
Using something like Gnome Tweaks you can easily search and pick your desktop entry for autostart when you log in to your machine.
  
== Create desktop entry ==
+
==Create desktop entry==
=== Download icon ===
+
===Automated script===
You don’t need to use a icon, but it makes for better looks and makes the wallet easier to find when browsing your applications.<br>
+
Instead of performing the following steps manually, you can find a link to an automated script that performs them for you in the [https://dgbwiki.com/index.php?title=Create_a_Core_Wallet_desktop_entry_on_Ubuntu_Desktop#Extra_notes Extra Notes] section at the bottom of this page.
Use the application browser or press <kbd>Ctrl</kbd>+<kbd>Alt</kbd>+<kbd>T</kbd> to open a terminal.<br>
+
======
 +
===Download icon===
 +
You don’t need to use a icon, but it makes for better looks and makes the wallet easier to find when browsing your applications.<br />
 +
Use the application browser or press <kbd>Ctrl</kbd>+<kbd>Alt</kbd>+<kbd>T</kbd> to open a terminal.<br />
 
Navigate to your DigiByte Core wallet location and create a new folder called
 
Navigate to your DigiByte Core wallet location and create a new folder called
 
<code>desktop</code>. Navigate to your new folder and download the icon with the <code>wget</code> command.
 
<code>desktop</code>. Navigate to your new folder and download the icon with the <code>wget</code> command.
<b>Example:</b><pre style="margin-top:0;">
+
'''Example:'''<pre style="margin-top:0;">
 
cd ~/digibyte-7.17.2/
 
cd ~/digibyte-7.17.2/
 
mkdir desktop
 
mkdir desktop
Line 18: Line 21:
 
wget https://github.com/DigiByte-Core/digibyte-logos/raw/master/Symbol%20Icons/512x512.png</pre>
 
wget https://github.com/DigiByte-Core/digibyte-logos/raw/master/Symbol%20Icons/512x512.png</pre>
  
=== Writing the file ===
+
===Writing the file===
It's important to perform these terminal commands as the user that is going to be using the wallet on the machine, no other users will have access to your desktop entry.<br>
+
It's important to perform these terminal commands as the user that is going to be using the wallet on the machine, no other users will have access to your desktop entry.<br />
Create a new file called <code>digibyte-qt.desktop</code> in <code>~/.local/share/applications/</code> using the <code>touch</code> command.<br>
+
Create a new file called <code>digibyte-qt.desktop</code> in <code>~/.local/share/applications/</code> using the <code>touch</code> command.<br />
 
<pre>touch ~/.local/share/applications/digibyte-qt.desktop</pre>
 
<pre>touch ~/.local/share/applications/digibyte-qt.desktop</pre>
 
<sub style="float:right;">The <code>~</code> represents your home folder(<code>/home/USERNAME/</code>).</sub>
 
<sub style="float:right;">The <code>~</code> represents your home folder(<code>/home/USERNAME/</code>).</sub>
  
Edit the file using a text editor.<br>
+
Edit the file using a text editor.<br />
 
For this example we will use the <code>nano</code> command from terminal.
 
For this example we will use the <code>nano</code> command from terminal.
 
<pre>nano ~/.local/share/applications/digibyte-qt.desktop</pre>
 
<pre>nano ~/.local/share/applications/digibyte-qt.desktop</pre>
Line 37: Line 40:
 
Exec=
 
Exec=
 
Icon=</pre>
 
Icon=</pre>
Write the <i>full path</i> to <code>digibyte-qt</code> after <code>Exec=</code>.<br>
+
Write the ''full path'' to <code>digibyte-qt</code> after <code>Exec=</code>.<br />
<b>Example:</b> <pre>Exec=/home/USERNAME/digibyte-7.17.2/bin/digibyte-qt</pre>
+
'''Example:''' <pre>Exec=/home/USERNAME/digibyte-7.17.2/bin/digibyte-qt</pre>
<br>
+
<br />
Now add the <i>full path</i> to your icon after <code>Icon=</code>.<br>
+
Now add the ''full path'' to your icon after <code>Icon=</code>.<br />
<b>Example:</b> <pre>Icon=/home/USERNAME/digibyte-7.17.2/desktop/512x512.png</pre>
+
'''Example:''' <pre>Icon=/home/USERNAME/digibyte-7.17.2/desktop/512x512.png</pre>
 
<sub style="float:right;"><code>USERNAME</code> should be replaced with your own username.</sub>
 
<sub style="float:right;"><code>USERNAME</code> should be replaced with your own username.</sub>
<br>
+
<br />
<i>Now save the file, and you're done!</i><br>
+
''Now save the file, and you're done!''<br  />
To save the file in nano, press <kbd>Ctrl</kbd>+<kbd>X</kbd> followed by <kbd>Y</kbd> to confirm, then press <kbd>Enter</kbd>.<br>
+
To save the file in nano, press <kbd>Ctrl</kbd>+<kbd>X</kbd> followed by <kbd>Y</kbd> to confirm, then press <kbd>Enter</kbd>.<br />
 
<u>If you have performed all of these steps correctly, you should now be able to launch the DigiByte Core Wallet from the application browser on your Ubuntu Desktop.</u>
 
<u>If you have performed all of these steps correctly, you should now be able to launch the DigiByte Core Wallet from the application browser on your Ubuntu Desktop.</u>
  
== Extra notes ==
+
==Extra notes==
 +
 
 
* <code>.desktop</code> files can also be placed in <code>/usr/share/applications/</code> but it is not recommended as any user on your machine could technically get access to your wallet.
 
* <code>.desktop</code> files can also be placed in <code>/usr/share/applications/</code> but it is not recommended as any user on your machine could technically get access to your wallet.
 
* This solution should work on most KDE & GNOME distro's according to freedesktop [https://specifications.freedesktop.org/desktop-entry-spec/latest/ documentation].
 
* This solution should work on most KDE & GNOME distro's according to freedesktop [https://specifications.freedesktop.org/desktop-entry-spec/latest/ documentation].
 +
* You can go to [https://github.com/Sbosvk/digibyte-desktop-install https://github.com/Sbosvk/digibyte-desktop-install] for a easy to use script instead.

Latest revision as of 04:23, 4 October 2021

Introduction

What is a desktop entry file?

A desktop entry file is used as a shortcut file. It retains information of a certain script or application on your Ubuntu machine, such as file location, icon, version, type, description etc.[1]

Why would you want a entry file?

You don’t need to start your wallet from the terminal. With a entry file set up you can simply start the DigiByte Core Wallet directly from the Ubuntu application browser.
Using something like Gnome Tweaks you can easily search and pick your desktop entry for autostart when you log in to your machine.

Create desktop entry

Automated script

Instead of performing the following steps manually, you can find a link to an automated script that performs them for you in the Extra Notes section at the bottom of this page.

==

Download icon

You don’t need to use a icon, but it makes for better looks and makes the wallet easier to find when browsing your applications.
Use the application browser or press Ctrl+Alt+T to open a terminal.
Navigate to your DigiByte Core wallet location and create a new folder called desktop. Navigate to your new folder and download the icon with the wget command.

Example:

cd ~/digibyte-7.17.2/
mkdir desktop
cd desktop
wget https://github.com/DigiByte-Core/digibyte-logos/raw/master/Symbol%20Icons/512x512.png

Writing the file

It's important to perform these terminal commands as the user that is going to be using the wallet on the machine, no other users will have access to your desktop entry.
Create a new file called digibyte-qt.desktop in ~/.local/share/applications/ using the touch command.

touch ~/.local/share/applications/digibyte-qt.desktop

The ~ represents your home folder(/home/USERNAME/).

Edit the file using a text editor.
For this example we will use the nano command from terminal.

nano ~/.local/share/applications/digibyte-qt.desktop

Paste the following:

[Desktop Entry]
Name=DigiByte Core Wallet
Comment=Official DigiByte Core Wallet for Linux
Terminal=false
Type=Application
Categories=Crypto;Network;Qt;
Keywords=dgb;core;digibyte;wallet;node;desktop;
Exec=
Icon=

Write the full path to digibyte-qt after Exec=.

Example:

Exec=/home/USERNAME/digibyte-7.17.2/bin/digibyte-qt


Now add the full path to your icon after Icon=.

Example:

Icon=/home/USERNAME/digibyte-7.17.2/desktop/512x512.png

USERNAME should be replaced with your own username.
Now save the file, and you're done!
To save the file in nano, press Ctrl+X followed by Y to confirm, then press Enter.
If you have performed all of these steps correctly, you should now be able to launch the DigiByte Core Wallet from the application browser on your Ubuntu Desktop.

Extra notes

  • .desktop files can also be placed in /usr/share/applications/ but it is not recommended as any user on your machine could technically get access to your wallet.
  • This solution should work on most KDE & GNOME distro's according to freedesktop documentation.
  • You can go to https://github.com/Sbosvk/digibyte-desktop-install for a easy to use script instead.