Fedora

Softwares

Installation

1
2
3
4
5
6
7
sudo dnf upgrade
sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
sudo dnf install https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
sudo dnf install gnome-extensions-app apostrophe thunderbird vim pip git tweak-tool zsh alacarte vlc gpick libreoffice-langpack-fr keepassxc clementine nextcloud-client nextcloud-client-nautilus seahorse transmission-remote-gtk youtube-dl ffmpeg syncthing
pip install yt-dlp
sudo dnf remove totem rhythmbox cheese
mkdir ~/Builds ~/Workspace

Git

Configuration

1
2
3
4
git config --global user.name "pierre"
git config --global user.email ***********@gmail.com
git config --global push.default simple
git config --global core.editor vim

Alias

1
2
3
4
5
git config --global alias.graph "log --graph --all --max-count 25 --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(bold blue)— %an%C(reset)%C(bold red)%d%C(reset)' --abbrev-commit --date=relative"
git config --global alias.co checkout
git config --global alias.ci commit
git config --global alias.st status
git config --global alias.br branch

SSH Key

Create and display SSH Key:

1
2
ssh-keygen -t ed25519 -C "ThinkPad/pierre"
cat ~/.ssh/id_ed25519.pub

Put the SSH Key in git services account:

Firefox

Hide “View saved login” dialog

Go to about:config

Then set signon.showAutoCompleteFooter to False

Theme

https://addons.mozilla.org/en-US/firefox/addon/one-dark-life/

Extensions

Tree Style Tab add-ons

Go to about:config, and change the value of toolkit.legacyUserProfileCustomizations.stylesheets to true.

Help > Troubleshooting Information > Profile Directory > Open Directory

Then Right click > Open in terminal

Then :

1
2
3
mkdir chrome
cd chrome
vim userChrome.css 

Write :

1
2
3
4
5
6
7
#tabbrowser-tabs {
  visibility: collapse !important;
}

#sidebar-header {
  visibility: collapse !important;
}

Source: https://medium.com/@Aenon/firefox-hide-native-tabs-and-titlebar-f0b00bdbb88b

Gnome

OS name

Settings > About > Device Name

Shortcuts

Settings > Keyboard > Keyboard Shortcuts > View and Customize Shortcuts

Switch window / Alt+Tab :

Set Switch windows to Alt+Tab

Gnome Terminal :

Click on Custom Shortcuts

1
2
3
Name:        Gnome Terminal
Command:     ptyxis --new-window
Accelerator: CTRL+ALT+T

Date format

Settings > Region & Language > Formats > United States (English)

Compose key

Settings > Keyboard > Special Character Entry > Compose key > Right Alt

Theme

  • Tweak Tool > Appearance > Legacy Applications > Adwaita-dark
  • Tweak Tool > Top Bar > Clock > Weekday
  • Tweak Tool > Top Bar > Clock > Date

Extensions

VPN

ProtonVPN

Download OpenVPN configuration files from: https://account.protonvpn.com/downloads

Then Settingd > Network > VPN > + > Import from file…

Use ProtonVPN - OpenVPN credentials.

Guest

1
2
3
sudo useradd -m guest
sudo chfn guest -f "Guest"
sudo passwd -f guest

ZSH

Gnome Terminal

In gnome-terminal:

Preferences > Profiles >

  • + > Zsh
  • Zsh >
    • Command >
      • Run a custom command instead of my shell > true
      • Custom commande > zsh
    • Colors >
      • Text and Background Color >
        • Use colors from system theme > false
        • Built-in schemes > Tango dark
      • Palette
        • Built-in schemes > Tango

Oh-My-Zsh

1
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Source: https://github.com/robbyrussell/oh-my-zsh

Zxcv Theme

Get Zxcv theme:

1
wget https://gitlab.com/home650/sh-oh-my-zsh-theme-zxcv/-/raw/v1.0/zxcv.zsh-theme -P ~/.oh-my-zsh/themes/

Source:

.zshrc config

1
vim ~/.zshrc

Set ZSH_THEME to zxcv.

Set plugins to (history sudo).

Append:

1
2
3
4
5
6
7
8
9
if [ -f "$HOME/.zshrc.d/aliases.zshrc" ]; then
   source "$HOME/.zshrc.d/aliases.zshrc"
fi

# Custom configuration
# Fix less behavior
LESS="-XRF"; export LESS
# Fix '\*' behavior
unsetopt nomatch
1
2
mkdir .zshrc.d
vim .zshrc.d/aliases.zshrc

Append:

1
2
3
4
5
# Aliases
alias cll='clear ; ll'

alias g=git
alias gst='clear ; g st'

Sources

Snap & Flatpak

Try to not to use it!

DNS

See : https://sebsauvage.net/wiki/doku.php?id=dns-blocklist

Syncthing

Gnome Extension

Add this gnome extension.

Thunderbird

Configuration

  • Menu > View >
    • Layout > Vertical view
    • Sort by > Threaded
  • Settings > General > Reading & Display > Automatically mark message as read > false
  • Settings > Composition > Spelling > Enable spellcheck as you type > true
    • Enable spellcheck as you type > true
    • Langage > French (France) > true
  • Account Settings >
    • Copies & Folders > When sending messages, automatically: > Place replies in the folder of the message being reply to > true
    • OpenPGP Security >
      • Enable OpenPGP support (Enigmail) for this identity > true
      • Encrypt messages by default > true
      • Sign messages by default > true

Remove unused dictionaries

// TODO

LibreOffice

Configuration

1
mkdir -p /home/pierre/.config/libreoffice/4/user/template

Tools > Options > LibreOffice > Paths > Template > Edit > […].config[…] > select

Addons

Clementine

Configuration

right click on sidebar > Plain sidebar

Tools > Preferences >

  • General
    • Playback > Fading >
      • Fade out when stoping a track > false
      • Cross fade when changing track manually > false -Behavior > Show tray icon > false
    • Music Library >
      • Add new folder > ~/Music
      • Automatic updating > Save ratings in file tags when possible > true
  • user Interface
    • Appearance > Background image > No Background image
    • Moodbars > Moodbar style > Angry

TODO → .WMA ?

Organise files

%artist/{%year - }%album{ (Disc %disc)}/{%track - }%title.%extension

Youtube-dl examples

source: https://github.com/ytdl-org/youtube-dl/blob/master/README.md#output-template

In ~/.zshrc.d/aliases.zshrc, add these aliases :

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
alias ydl='youtube-dl --add-metadata --ignore-errors'
alias ydlp='yt-dlp --add-metadata --ignore-errors'

args_base='--add-metadata --ignore-errors'
args_archive='--download-archive download-archive'
args_playlist='-o "%(upload_date)s - %(title)s.%(ext)s"'
args_audio='-x -f "bestaudio[ext=flac]/bestaudio[ext=m4a]/bestaudio" --embed-thumbnail'
args_video='-f "best[ext=webm][height<=720]/best[height<=720]/best" --all-subs --embed-subs'

alias ydl-audio="ydl $args_audio"
alias ydl-video="ydl $args_video"
alias ydl-playlist-audio="ydl $args_archive $args_playlist $args_audio"
alias ydl-playlist-video="ydl $args_archive $args_playlist $args_video"

alias ydlp-audio="ydlp $args_audio"
alias ydlp-video="ydlp $args_video"
alias ydlp-playlist-audio="ydlp $args_archive $args_playlist $args_audio"
alias ydlp-playlist-video="ydlp $args_archive $args_playlist $args_video"

Valentina

1
2
sudo dnf config-manager --add-repo https://download.opensuse.org/repositories/home:dismine/Fedora_Rawhide/home:dismine.repo
sudo dnf install valentina

Source: https://software.opensuse.org/download.html?project=home%3Adismine&package=valentina

If you have Wayland focus related error, try to edit valentina.desktop command line entry with alacarte as:

1
sh -c "QT_QPA_PLATFORM=xcb valentina %F"

Remove fedora splash screen

remove rhgb quiet from:

1
sudo vim /etc/default/grub

Then:

1
sudo grub2-mkconfig -o /boot/grub2/grub.cfg

PyCharm

Try to not use Snap! source: https://www.jetbrains.com/help/pycharm/installation-guide.html#standalone

Ruby

1
sudo dnf install ruby
1
vim ~/.gemrc

Append:

1
2
install:
  --bindir ~/.local/bin

Jekyll

https://jekyllrb.com/docs/

Java

Install JDK 8:

Then

1
2
sudo update-alternatives --config java
sudo update-alternatives --config javac

Gnome Boxes - Development VM

Create a VM with Fedora Server (netinst).

Select custom partitioning to ensure LVM partitioning.

In Softwares, select Minimal install, then Editors.

Set root password as root.

Create user user with user as password and make him root user.

Then :

1
sudo dnf install sshfs vim gcc

Shared folders

On Host

1
systemctl start sshd.service

On Guest

1
2
mkdir ~/Workspace
sshfs user@[HOST_IP]:~/Workspace ~/Workspace

Python

1
2
sudo dnf install python3-virtualenv python3-virtualenvwrapper
sudo pip install -U pip

autoenv

1
2
3
cd ~/Builds
git clone git://github.com/inishchith/autoenv.git
vim ~/.zshrc

Append:

1
2
3
4
AUTOENV_ENV_FILENAME=.env
AUTOENV_ENV_LEAVE_FILENAME=.env.leave
AUTOENV_ENABLE_LEAVE="TRUE"
source ~/Builds/autoenv/activate.sh

Maria DB

1
2
3
4
sudo dnf install mariadb-server mariadb-devel
sudo systemctl enable mariadb
sudo systemctl start mariadb
sudo mysql_secure_installation

PhpMyAdmin

1
2
3
4
5
sudo dnf install phpMyAdmin
sudo systemctl enable httpd
sudo systemctl start httpd
sudo firewall-cmd --add-service={http,https} --permanent
sudo firewall-cmd --reload

To allow connection from local network see : https://computingforgeeks.com/install-and-configure-phpmyadmin-on-fedora/

Android Studio

Install

Find latest version from https://developer.android.com/studio/index.html

1
2
3
4
5
6
7
8
9
10
cd ~/Downloads
sudo unzip // android-studio-ide-143.2637817-linux.zip
sudo rm // android-studio-ide-143.2637817-linux.zip
cd /opt/google
sudo cp -R ~/Downloads/android-studio/ .
sudo chown -R root:wheel android-studio
sudo chmod -R g+w android-studio
sudo mkdir android-sdk
sudo chown -R root:wheel android-sdk
sudo chmod -R g+w android-sdk

Use alacarte to add an entry for Android Studio.

Plugins

  • ADB uninstall
  • CodeGlance
  • Gitlab integration

Configuration

1
2
3
File > Settings... > Editor > General > Smart Keys > Use "CamelHumps" words
File > Settings... > Editor > General > Honor "CamelHumps" words settings when selecting on double click
File > Settings... > Build, Execution, Deployment > Instant Run > Enable Instant Run to hot swap...

Gnome configuration

Open keyboard,
find alt + F7 shortcut, remove it (backspace),
find ctrl + alt + left shortcut, remove it (backspace),
find ctrl + alt + right shortcut, remove it (backspace).

Make Fedora see your physical device

1
sudo vim /tmp/android.rules

Fill it with:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
SUBSYSTEM=="usb", ATTRS{idVendor}=="0bb4", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0e79", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0502", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0b05", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="413c", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0489", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="091e", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="18d1", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0bb4", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="12d1", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="24e3", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="2116", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0482", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="17ef", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="1004", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="22b8", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0409", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="2080", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0955", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="2257", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="10a9", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="1d4d", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0471", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="04da", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="05c6", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="1f53", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="04e8", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="04dd", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0fce", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="0930", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="19d2", MODE="0666"
SUBSYSTEM=="usb", ATTRS{idVendor}=="1bbb", MODE="0666"

Then:

1
2
3
4
5
6
sudo cp /tmp/android.rules /etc/udev/rules.d/51-android.rules
sudo chmod 644   /etc/udev/rules.d/51-android.rules
sudo chown root. /etc/udev/rules.d/51-android.rules
sudo rm /tmp/android.rules
sudo service udev restart
sudo killall adb

Source: http://stackoverflow.com/questions/9210152/set-up-device-for-development-no-permissions

VirtualBox

https://www.if-not-true-then-false.com/2010/install-virtualbox-with-yum-on-fedora-centos-red-hat-rhel/

Genymotion

Find latest version from https://www.genymotion.com/account/login/

Settings > ADB > Use custom Android SDK tools > /opt/android-sdk

GAPPS

http://opengapps.org/

Download x86 version.

Troubleshooting

For libjpeg.so.8

1
2
sudo dnf install libtool
sudo dnf install autoconf

Source: https://ask.fedoraproject.org/en/question/82485/libjpegso8-cannot-open-shared-object-file-no-such-file-or-directory/

For symbol lookup error: /usr/lib64/libX11.so.6

Source: http://stackoverflow.com/questions/39316164/genymotion-usr-lib64-libx11-so-6-undefined-symbol-xcb-wait-for-reply64/39318571#39318571

For symbol lookup error: /lib64/libX11.so.6: undefined symbol: xcb_poll_for_reply64

Source: http://stackoverflow.com/questions/39316164/genymotion-usr-lib64-libx11-so-6-undefined-symbol-xcb-wait-for-reply64

For [Genymotion Player] [Fatal] Could not initialize GLX

1
sudo mv /opt/genymobile/genymotion/libdrm.so.2 /tmp

Source: https://aur.archlinux.org/packages/genymotion/?setlang=it&comments=all


Netlify status