Skip to content

Latest commit

 

History

History
271 lines (268 loc) · 13.7 KB

tool-install-guide.md

File metadata and controls

271 lines (268 loc) · 13.7 KB

Tool Install Guide

This guide will walk you through installing common engineering tools on your system. If you haven't read the computer setup guide yet, start there. This guide is written for Ubuntu derivatives using the BASH shell.

  1. Update your system.

    sudo apt-get update
    sudo apt-get upgrade -y
    sudo apt-get autoremove
  2. Terminator - iTerm2-like terminal emulator for Linux

    sudo apt-get install -y terminator
    1. Check Terminator > right-click > Preferences > Profiles > Scrolling > Infinite Scrollback.
    2. I like to invert the titlebar colors so "focused" is blue (#0076C9) or green (#3FBC6C), and "receiving" is red (#C80003). It is just less aggressive and more plesant to look at. These settings are in Terminator > right-click > Preferences > General > Terminal Titlebar.
  3. Vim - CLI text editor and related utilities

    sudo apt-get install -y vim vim-common
  4. VScode - GUI text editor

    sudo apt-get install -y code
    1. GitLens - VScode extension to view files in the context of their git history
    2. Dark+ Pure Black (OLED) - Optional extension to make the existing Dark+ theme distributed with VScode use true black, for OLED displays
  5. Zap - a package manager for *.AppImage programs

    sudo wget https://github.com/srevinsaju/zap/releases/download/continuous/zap-amd64 -O /usr/local/bin/zap
    sudo chmod +x /usr/local/bin/zap
  6. Bitwarden - secure, open-source password manager

    curl -fSL 'https://vault.bitwarden.com/download/?app=desktop&platform=linux&variant=appimage' -o ~/Downloads/Bitwarden.AppImage
    zap install bitwarden ~/Downloads/Bitwarden.AppImage

    Fix missing logo.

    sed -E "s_(Icon=).*$$_\1/home/$USERNAME/.local/share/zap/v2/icons/bitwarden.png_" -i ~/.local/share/applications/bitwarden.desktop
  7. Joplin - open-source, Evernote-like note taking app

    zap install --from 'https://github.com/laurent22/joplin/releases/download/v2.8.8/Joplin-2.8.8.AppImage' joplin

    Fix missing logo.

    sed -E "s_(Icon=).*$$_\1/home/$USERNAME/.local/share/zap/v2/icons/joplin.png_" -i ~/.local/share/applications/joplin.desktop
  8. Telegram Desktop - psuedo-secure instant messaging application

    sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
    flatpak install flathub org.telegram.desktop

    Log into and configure Telegram Desktop.

  9. Brave - privacy-focused Chromium-based web browser with builtin ad and tracker blocking

    sudo apt-get install -y apt-transport-https curl
    sudo curl -fsSLo /usr/share/keyrings/brave-browser-archive-keyring.gpg https://brave-browser-apt-release.s3.brave.com/brave-browser-archive-keyring.gpg

    Configure Brave, including logging into or creating a work sync profile, if you wish.

  10. Firefox - a privacy-focused web browser not built on software from an advertisement juggernaut

    sudo apt-get install -y firefox

    Configure Firefox, including logging into or creating a work Mozilla account, if you wish.

  11. pip - package manager for Python

    sudo apt-get install -y python3-pip python3-venv
  12. docker - container engine, like virtual machines but lighter

    sudo apt-get install -y ca-certificates curl gnupg lsb-release
    sudo mkdir -p /etc/apt/keyrings
    curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o ~/Downloads/docker.gpg
    cat ~/Downloads/docker.gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
    # note: this command will only work on Ubuntu and Ubuntu derivatives
    echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu $(source /etc/upstream-release/lsb-release 2>/dev/null && echo "$DISTRIB_CODENAME" || lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list
    sudo apt-get update
    sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin
    sudo service docker start
    sudo docker run hello-world
    1. Download Ubuntu docker images.
      docker pull ubuntu:18.04
      docker pull ubuntu:20.04
      docker pull ubuntu:22.04
  13. VirtualBox - type 2 hypervisor for running computers inside computers as a program

    sudo apt-get install -y virtualbox
  14. qBittorrent - open-source bittorrent client

    1. Optionally, install this OLED-dark theme.
    2. Download Ubuntu *.iso images for VirtualBox.
  15. Caffeine - keep your computer awake

    sudo apt-get install -y caffeine

    Make the caffeine indicator appear in the system tray on startup.

    ln -s /usr/share/applications/caffeine-indicator.desktop ~/.config/autostart/caffeine-indicator.desktop
  16. git - open-source, distributed version control software

    sudo apt-get install -y git
    1. Install git.
      brew install git
    2. Generate an SSH Key and associate it with your GitHub account.
      1. Generate an ed25519 SSH key using your work email.
        ssh-keygen -t ed25519 -f ~/.ssh/github.key -C [email protected]
      2. Enter a strong passphrase.
        • Convenient local JavaScript diceware generator, trust at your own risk. We recommend using Bitwarden to generate the password or passphrase.
      3. Check that SSH daemon is running
        ssh-agent -s 1>/dev/null && echo 'SSH daemon is running' || echo 'SSH daemon is not running'
      4. Add new key to keystore.
        ssh-add ~/.ssh/github.key
      5. Copy your public key to clipboard.
        cat ~/.ssh/github.key.pub
      6. In your browser, go to: GitHub > Settings > SSH and GPG keys > New SSH key
      7. Paste your public key into Key.
      8. Give your SSH key a meaningful title, for example "ENF" followed by your computer hostname.
      9. Click Add SSH Key.
      10. Test it.
        1. Connect to GitHub via SSH.
        2. Accept the GitHub RSA fingerprint.
          yes
          
        3. You should see:
          You've successfully authenticated, but GitHub does not provide shell access.
          
    3. Generate an ed25519 GPG Key and associate it with your GitHub account.
      1. Generate the key using your work email.
        1. Start GPG.
          gpg --expert --full-generate-key
        2. Select ECC and ECC.
          9, [Enter]
        3. Use an ed25519 key.
          1, [Enter]
        4. Set your desired key expiration period.
          0, [Enter]
          y, [Enter]
        5. Enter your name as you want it to appear next to your contributions in our open-source commit history.
        6. Enter either your work email address, or your GitHub no-reply email address.
          • This email address MUST match one of the emails attached to your GitHub account.
        7. Enter your computer's hostname for the comment.
        8. Confirm the settings.
          o (letter 'o' key)
        9. Enter a strong passphrase, twice.
          • Convenient local JavaScript diceware generator, trust at your own risk. We recommend using Bitwarden to generate the password or passphrase.
      2. Associate your GPG key with your GitHub account.
        1. Copy your public key to the clipboard.
          gpg --armor --export "$(gpg --list-secret-keys --keyid-format LONG | grep sec | awk '{print $2}' | cut -d '/' -f '2')"
        2. In your browser, go to: GitHub > Settings > SSH and GPG keys > New GPG key
        3. Paste your public key into Key.
        4. Click Add GPG Key.
    4. Configure your shell.
      1. Configure gpg to use gpg-agent, similar to ssh-agent.
        echo 'use-agent' > ~/.gnupg/gpg.conf
      2. Configure gpg-agent to use the keychain to store the GPG passphrase.
        echo 'pinentry-program /usr/bin/pinentry-gnome3' > ~/.gnupg/gpg-agent.conf
      3. Reload the gpg-agent daemon with the new settings.
        echo RELOADAGENT | gpg-connect-agent
      4. Load your keys in all shells.
        cat << 'BASH' >> ~/.bashrc
        ### GitHub ###
        export GPG_TTY=$(tty)
        
        BASH
        source ~/.bashrc
    5. Store your GPG passphrase in the keyring.
      1. Invoke a pinentry-gnome3 password prompt.
        echo '1234' | gpg -o /dev/null --local-user "$(gpg --list-secret-keys --keyid-format LONG | grep sec | awk '{print $2}' | cut -d '/' -f '2')" -as - && echo 'Looks good! Can we sign code next time?' || echo 'Oh noes! We could not authenticate!'
      2. Check Save in Keychain.
      3. Enter your GPG passphrase created earlier.
      4. Click OK.
    6. Configure git.
      1. Add your work email address.
        git config --global user.email [email protected]
      2. Add your real name.
        git config --global user.name 'First Last'
      3. Point git to your GPG key.
        git config --global user.signingkey "$(gpg --list-secret-keys --keyid-format LONG | grep sec | awk '{print $2}' | cut -d '/' -f '2')"
      4. Configure git to sign all commits pushed from this user account on this computer.
        git config --global commit.gpgsign true
      5. Configure git to use your preferred editor.
        git config --global core.editor 'vim'
      6. Configure git to use SSH for all submodules, even if the repo defines them with HTTPS.
        cat << 'BASH' >> ~/.gitconfig
        [url "ssh://[email protected]/"]
                insteadOf = https://github.com/
        BASH
        
    7. Verify that your work email is associated with your GitHub account. GitHub > Settings > Emails
      • If your work email is not associated with your GitHub account, your activity on GitHub (pull requests, issues, comments) will appear to come from a different account than your commits and pushes made from this device.
      • Performing this association later can retroactively associate commits with your account.
  17. Beyond Compare - side-by-side comparison, editing, and merging of text, hex, binaries, Office documents, pictures, MP3s, archives, and folders; with support for git integration and cloud locations such as FTP, SFTP, Dropbox, or buckets

    1. Install Beyond Compare.
      sudo apt-get install -y bcompare
    2. Configure git for diffs with Beyond Compare.
      git config --global diff.tool bc3
      git config --global difftool.bc3.trustExitCode true
       - The behavior of `git diff` cannot be changed, you use `git difftool` to diff with Beyond Compare.
      
    3. Configure git for resolving merge conflicts with Beyond Compare.
      git config --global merge.tool bc3
      git config --global mergetool.bc3.trustExitCode true
       - Invoke `git mergetool` when you want to use Beyond Compare to resolve merge conflicts.
      
  18. git-imerge - branch merge conflict resolution tool

    pip install git-imerge
  19. bpkg - BASH package manager

    curl -fsSL 'https://raw.githubusercontent.com/bpkg/bpkg/master/setup.sh' -o ~/Downloads/bpkg-install.sh
    chmod +x ~/Downloads/bpkg-install.sh
    ~/Downloads/bpkg-install.sh
  20. Make a work directory.

    mkdir -p ~/Work