Notes

Install Firefox Nightly on Ubuntu Linux 18.04

Edit on GitHub

System Administration
2 minutes
 1# Create /opt directory
 2sudo mkdir --mode=755 /opt
 3
 4# create a directory for firefox
 5sudo mkdir /opt/firefoxnightly
 6
 7# Download latest Nightly 64-Bit
 8wget -O firefoxnightly.tar.bz2 "https://download.mozilla.org/?product=firefox-nightly-latest-ssl&os=linux64&lang=en-US"
 9
10# Extract firefox to the folder we created for it in /opt
11tar xjf ~/Downloads/firefoxnightly.tar.bz2 /opt/firefoxnightly
12
13# give rights so that it auto-updates
14sudo chown -R $USER:$USER /opt/firefoxnightly
15
16# start Firefox Nightly 
17cd /opt/firefoxnightly && ./firefox

1. Download Firefox Nightly

You’ll get a .tar.bz2 file. Mozilla doesn’t provide .deb or .rpm packages since binaries are more universal and work on all distributions.

Extract the file and you’ll get a folder called firefox.

2. Create an /opt directory

/opt is for system-wide installation of add-on software, while /usr/local is for single user and local installations. Since /opt is optional, Ubuntu doesn’t have one by default. You can create one, no big deal.

1sudo mkdir --mode=755 /opt

Whichever directory you want to install in is up to you.

3. Adding the Dock Icon

I was able to start Firefox Nightly but hwne right-clicked the icon, there were no options to add it as a Favorite.

1# Create a desktop icon
2touch ~/firefoxnightly.desktop

Add the following to the shortcut icon file. See /usr/share/applications/firefox.desktop for inspiration

 1#!/usr/bin/env xdg-open
 2
 3[Desktop Entry]
 4Version=1.0
 5Name=Firefox Nightly
 6Comment=Take a browse on the wild side
 7Terminal=false
 8Type=Application
 9Categories=Network;WebBrowser;
10#
11# WARNING: Remember to fix the path in Icon and Exec
12#
13Icon=/opt/firefoxnightly/browser/chrome/icons/default/default128.png
14Exec=/opt/firefoxnightly/firefox %u
15
16# Actions=Default;Mozilla;ProfileManager;
17
18# [Desktop Action ProfileManager]
19# Name=Profile Manager
20# Exec=/opt/firefoxnightly/firefox –no-remote –profile-manager
21
22# These actions show when you right-click the icon in the Dock
23Actions=new-window;new-private-window;
24
25# Open a New Window
26[Desktop Action new-window]
27Name=Open a New Window
28Exec=/opt/firefoxnightly/firefox -new-window
29
30# Open a New Private Window
31[Desktop Action new-private-window]
32Name=Open a New Private Window
33Exec=/opt/firefoxnightly/firefox -private-window

validate the file, no output means it passed

1desktop-file-validate ~/firefoxnightly.desktop 

add the shortcut to Dock

1# for current user
2desktop-file-install --dir=.local/share/applications firefoxnightly.desktop
3
4# for all users (/usr/share/applications/)
5sudo desktop-file-install firefoxnightly.desktop

At this point i can search for Firefox Nightly and see the icon to click. But not seeing the right-click menu options i added.

What i did was search for Firefox Nightly and then dragged the icon to the Dock to add it as Favorite. That added it to the dock as well as gave me the right-click options.