Compare commits
38 Commits
e04a92cfd0
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| f89791d7ff | |||
| 4ee8c17fad | |||
| 0f6197f4e2 | |||
| c822db6021 | |||
| 9bc911a665 | |||
| edeb664f73 | |||
| 3b454065ae | |||
| dab4201158 | |||
| 906b218136 | |||
| e29003e594 | |||
| ed94e2047a | |||
| 0e9151390b | |||
| 59db8935ca | |||
| 2ee44c4120 | |||
| edd55b23fa | |||
| ff721a399e | |||
| 195b032b05 | |||
| 3c82eca615 | |||
| 7ce4beaa61 | |||
| 8f49df5fb1 | |||
| 1a0f8d5d0c | |||
| ad0ff1e15e | |||
| 743ea12eea | |||
| c02c6ef3c9 | |||
| 1697c94dd9 | |||
| cde4685bb0 | |||
| f5fae9ef1c | |||
| a1c2bcafac | |||
| c43b1467eb | |||
| 823adda10c | |||
| 127f07ae1f | |||
| aa9fb4548b | |||
| 4f94a072e3 | |||
| 41456ca499 | |||
| 15483e4e0f | |||
| 52e766899f | |||
| 918fc0c638 | |||
| a8eeedf9d5 |
72
.bashrc
72
.bashrc
@ -1,51 +1,61 @@
|
||||
# ==============================================================================
|
||||
# Personal $HOME/.bashrc file by James Blair <mail@jamesblair.net>
|
||||
# ==============================================================================
|
||||
|
||||
# If not running interactively, don't do anything
|
||||
[ -z "$PS1" ] && return
|
||||
|
||||
# don't put duplicate lines or lines starting with space in the history.
|
||||
# Don't put duplicate lines or lines starting with space in the history.
|
||||
HISTCONTROL=ignoreboth
|
||||
|
||||
# append to the history file, don't overwrite it
|
||||
# also ensure we write to history immediately instead of only on terminal close
|
||||
# Append to the history file, don't overwrite it
|
||||
# Also ensure we write to history immediately instead of only on terminal close
|
||||
shopt -s histappend
|
||||
export PROMPT_COMMAND="history -a; history -n"
|
||||
|
||||
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
|
||||
HISTSIZE=10000
|
||||
HISTFILESIZE=20000
|
||||
# Retain infinite bash history
|
||||
HISTSIZE=-1
|
||||
HISTFILESIZE=-1
|
||||
|
||||
# check the window size after each command and, if necessary,
|
||||
# Check the window size after each command and, if necessary
|
||||
# update the values of LINES and COLUMNS.
|
||||
shopt -s checkwinsize
|
||||
|
||||
# enable color support of ls and also add handy aliases
|
||||
if [ -x /usr/bin/dircolors ]; then
|
||||
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
|
||||
alias ls='ls -l --color=auto -h --group-directories-first'
|
||||
alias ll='ls -l --color=auto -h --group-directories-first'
|
||||
# Alias ls to eza
|
||||
if [ "$(command -v eza)" ]; then
|
||||
alias ll='eza -l --icons=auto --group-directories-first'
|
||||
alias ls='eza -l --icons=auto --group-directories-first'
|
||||
fi
|
||||
|
||||
# Alias cat to bat
|
||||
if [ "$(command -v bat)" ]; then
|
||||
alias cat='bat --style=plain --pager=never' 2>/dev/null
|
||||
fi
|
||||
|
||||
# Alias docker to podman
|
||||
alias docker=podman
|
||||
|
||||
# Custom git alias for pushing to all remotes at once
|
||||
alias gpa='git remote | xargs -L1 git push --all'
|
||||
# Alias df to dysk
|
||||
if [ "$(command -v bat)" ]; then
|
||||
alias df=dysk
|
||||
fi
|
||||
|
||||
# simplify bitwarden cli usage
|
||||
# Simplify bitwarden cli usage
|
||||
cpcmd="xclip -selection c"; if [[ "$XDG_SESSION_TYPE" == "wayland" ]]; then cpcmd="wl-copy"; fi
|
||||
alias bw='NODE_OPTIONS="--no-deprecation" /home/linuxbrew/.linuxbrew/bin/bw'
|
||||
alias bwu='export BW_SESSION=$(bw unlock --raw > ~/.bw_session && cat ~/.bw_session)'
|
||||
|
||||
function bwgp () {
|
||||
local test=$(export BW_SESSION=~/.bw_session) && bw get password "$1" | $cpcmd;
|
||||
|
||||
# If the login has a totp associated we should leave a follow-up prompt for it
|
||||
if totp=$(bw get totp "$1"); then
|
||||
read -p "Press enter when ready for totp"
|
||||
echo "${totp}" | $cpcmd
|
||||
# Retrieve full json
|
||||
local test
|
||||
test=$(eval $(export BW_SESSION=~/.bw_session) && bw get item "${1}");
|
||||
|
||||
# Update clipboard with initial value
|
||||
echo ${test} | jq -r '.login.password' | "${cpcmd}"
|
||||
|
||||
# Check if a totp is associated
|
||||
if [ $(echo ${test} | jq -r .login.totp) != "null" ]; then
|
||||
|
||||
# Retrieve totp in background
|
||||
exec 3< <(echo $(bw get totp "${1}"))
|
||||
read -r -p "Press enter when ready for totp"
|
||||
read -r <&3 line && echo "${line}" | "${cpcmd}"
|
||||
fi
|
||||
}
|
||||
function bwgt () { local test=$(export BW_SESSION=~/.bw_session) && bw get totp "$1" | $cpcmd; }
|
||||
@ -80,9 +90,7 @@ function bwai () {
|
||||
bw encode | bw create item && bw sync
|
||||
}
|
||||
|
||||
# enable programmable completion features (you don't need to enable
|
||||
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
|
||||
# sources /etc/bash.bashrc).
|
||||
# Enable programmable completion features
|
||||
if ! shopt -oq posix; then
|
||||
if [ -f /usr/share/bash-completion/bash_completion ]; then
|
||||
. /usr/share/bash-completion/bash_completion
|
||||
@ -152,6 +160,14 @@ if [ -z "$TMUX" ]; then
|
||||
fi
|
||||
fi
|
||||
|
||||
# Helper functions for bluetooth
|
||||
alias bthsc="bluetoothctl connect CC:98:8B:B6:F0:8E"
|
||||
alias bthsd="bluetoothctl disconnect CC:98:8B:B6:F0:8E"
|
||||
|
||||
# Add kubectl krew plugins to path
|
||||
export PATH="${KREW_ROOT:-$HOME/.krew}/bin:$PATH"
|
||||
|
||||
# Enable simple bash prompt
|
||||
SBP_PATH=/home/james/Downloads/sbp
|
||||
source /home/james/Downloads/sbp/sbp.bash
|
||||
|
||||
|
||||
12
.kuberc
Normal file
12
.kuberc
Normal file
@ -0,0 +1,12 @@
|
||||
---
|
||||
apiVersion: kubectl.config.k8s.io/v1alpha1
|
||||
kind: Preference
|
||||
overrides:
|
||||
- command: apply
|
||||
flags:
|
||||
- name: server-side
|
||||
default: "true"
|
||||
- command: delete
|
||||
flags:
|
||||
- name: interactive
|
||||
default: "true"
|
||||
@ -1,6 +1,8 @@
|
||||
text/html; lynx -assume_charset=%{charset} -display_charset=utf-8 -collapse_br_tags -dump %s; nametemplate=%s.html; copiousoutput
|
||||
application/pdf; firefox %s
|
||||
application/pdf; xdg-open %s & sleep 4
|
||||
application/vnd.openxmlformats-officedocument.wordprocessingml.document; libreoffice %s
|
||||
application/vnd.openxmlformats-officedocument.wordprocessingml.document; libreoffice --nologo %s; nametemplate=%s.docx; test=test -n "$DISPLAY"
|
||||
# application/vnd.openxmlformats-officedocument.wordprocessingml.document; pandoc --from=docx --to=plain %s | cat --squeeze-blank; nametemplate=%s.docx; copiousoutput
|
||||
application/vnd.openxmlformats-officedocument.wordprocessingml.template; libreoffice --nologo %s; nametemplate=%s.docm; test=test -n "$DISPLAY"
|
||||
image/jpeg; display '%s'; test=test -n "$DISPLAY"
|
||||
image/png; display '%s'; test=test -n "$DISPLAY"
|
||||
|
||||
52
.muttrc
52
.muttrc
@ -5,7 +5,7 @@ set imap_user=`bw get username hosted`
|
||||
set imap_pass=`bw get password hosted`
|
||||
|
||||
# This is the remote server and folder (optional)
|
||||
set folder=imaps://mail.jamesblair.net
|
||||
set folder=imaps://imap.dreamhost.com
|
||||
|
||||
# This is the folder your mail arrives into
|
||||
set spoolfile=+INBOX
|
||||
@ -24,12 +24,13 @@ set realname='James Blair'
|
||||
set header_cache="~/.mutt/cache/headers"
|
||||
set message_cachedir="~/.mutt/cache/bodies"
|
||||
set certificate_file="~/.mutt/certificates"
|
||||
set smtp_url="smtp://`bw get username hosted`@mail.jamesblair.net:587/"
|
||||
set smtp_url="smtp://`bw get username hosted`@smtp.dreamhost.com:587/"
|
||||
set smtp_pass=`bw get password hosted`
|
||||
set move=no
|
||||
set imap_keepalive=900
|
||||
set postponed="=INBOX.Drafts"
|
||||
set record="=INBOX.Sent"
|
||||
set sort=date-received
|
||||
unset imap_passive
|
||||
|
||||
macro index,pager \cb "<pipe-message> urlscan<Enter>" "call urlscan to extract URLs out of a message"
|
||||
@ -54,4 +55,49 @@ bind index,pager \Co sidebar-open
|
||||
# Configure html emails
|
||||
alternative_order text/plain text/html
|
||||
auto_view text/html
|
||||
set mailcap_path = ~/.mutt/mailcap
|
||||
set mailcap_path = ~/.muttmailcap
|
||||
|
||||
# Always include messages when replying
|
||||
set include
|
||||
|
||||
#================================================================
|
||||
# Dracula theme colors
|
||||
#================================================================
|
||||
# general ------------ foreground ---- background -----------------------------
|
||||
color error color231 color212
|
||||
color indicator color231 color241
|
||||
color markers color210 default
|
||||
color message default default
|
||||
color normal default default
|
||||
color prompt default default
|
||||
color search color84 default
|
||||
color status color141 color236
|
||||
color tilde color231 default
|
||||
color tree color141 default
|
||||
|
||||
# message index ------ foreground ---- background -----------------------------
|
||||
color index color210 default ~D # deleted messages
|
||||
color index color84 default ~F # flagged messages
|
||||
color index color117 default ~N # new messages
|
||||
color index color212 default ~Q # messages which have been replied to
|
||||
color index color215 default ~T # tagged messages
|
||||
color index color141 default ~v # messages part of a collapsed thread
|
||||
|
||||
# message headers ---- foreground ---- background -----------------------------
|
||||
color hdrdefault color117 default
|
||||
color header color231 default ^Subject:.*
|
||||
|
||||
# message body ------- foreground ---- background -----------------------------
|
||||
color attachment color228 default
|
||||
color body color231 default [\-\.+_a-zA-Z0-9]+@[\-\.a-zA-Z0-9]+ # email addresses
|
||||
color body color228 default (https?|ftp)://[\-\.,/%~_:?&=\#a-zA-Z0-9]+ # URLs
|
||||
color body color231 default (^|[[:space:]])\\*[^[:space:]]+\\*([[:space:]]|$) # *bold* text
|
||||
color body color231 default (^|[[:space:]])_[^[:space:]]+_([[:space:]]|$) # _underlined_ text
|
||||
color body color231 default (^|[[:space:]])/[^[:space:]]+/([[:space:]]|$) # /italic/ text
|
||||
color quoted color61 default
|
||||
color quoted1 color117 default
|
||||
color quoted2 color84 default
|
||||
color quoted3 color215 default
|
||||
color quoted4 color212 default
|
||||
color signature color212 default
|
||||
#================================================================
|
||||
|
||||
@ -13,7 +13,13 @@ set -g @plugin 'tmux-plugins/tmux-sensible'
|
||||
set -g @plugin 'dracula/tmux'
|
||||
|
||||
# Make dracula theme more minimal
|
||||
set -g @dracula-plugins " "
|
||||
set -g @dracula-plugins "cpu-usage gpu-usage ram-usage"
|
||||
set -g @dracula-cpu-usage-colors "grey dark_gray"
|
||||
set -g @dracula-ram-usage-colors "grey dark_gray"
|
||||
set -g @dracula-gpu-usage-colors "grey dark_gray"
|
||||
|
||||
|
||||
set -g @dracula-show-powerline true
|
||||
|
||||
# Initialise tpm
|
||||
run '~/.tmux/plugins/tpm/tpm'
|
||||
|
||||
19
Brewfile
19
Brewfile
@ -1,4 +1,3 @@
|
||||
tap "homebrew/bundle"
|
||||
brew "atuin"
|
||||
brew "awscli"
|
||||
brew "azure-cli"
|
||||
@ -8,27 +7,33 @@ brew "bitwarden-cli"
|
||||
brew "btop"
|
||||
brew "cekit"
|
||||
brew "cloudflared"
|
||||
brew "pcre2"
|
||||
brew "dict"
|
||||
brew "direnv"
|
||||
brew "dysk"
|
||||
brew "emacs"
|
||||
brew "eza"
|
||||
brew "fd", link: false
|
||||
brew "fd"
|
||||
brew "fzf"
|
||||
brew "gcc"
|
||||
brew "gh"
|
||||
brew "git-absorb"
|
||||
brew "git-lfs"
|
||||
brew "glab"
|
||||
brew "pcre2"
|
||||
brew "go"
|
||||
brew "go@1.21"
|
||||
brew "go@1.22"
|
||||
brew "go@1.24"
|
||||
brew "golangci-lint"
|
||||
brew "goreman"
|
||||
brew "govulncheck"
|
||||
brew "gpgme"
|
||||
brew "helm"
|
||||
brew "kind"
|
||||
brew "kn"
|
||||
brew "kubernetes-cli"
|
||||
brew "krew"
|
||||
brew "kubetail"
|
||||
brew "kwok"
|
||||
brew "lynx"
|
||||
brew "markdownlint-cli"
|
||||
brew "markdownlint-cli2"
|
||||
brew "mutt"
|
||||
@ -37,12 +42,16 @@ brew "npm-check-updates"
|
||||
brew "ocm"
|
||||
brew "openshift-cli"
|
||||
brew "pcre"
|
||||
brew "podman-compose"
|
||||
brew "ripgrep"
|
||||
brew "rosa-cli"
|
||||
brew "roxctl"
|
||||
brew "screenfetch"
|
||||
brew "shellcheck"
|
||||
brew "sshfs"
|
||||
brew "ugrep"
|
||||
brew "urlscan"
|
||||
brew "virtctl"
|
||||
brew "yamlfmt"
|
||||
brew "yamllint"
|
||||
brew "yq"
|
||||
|
||||
6
Flatfile
6
Flatfile
@ -1,3 +1,4 @@
|
||||
flathub app.zen_browser.zen
|
||||
flathub com.calibre_ebook.calibre
|
||||
flathub com.transmissionbt.Transmission
|
||||
flathub com.valvesoftware.Steam
|
||||
@ -7,7 +8,10 @@ flathub io.github.ungoogled_software.ungoogled_chromium.Codecs
|
||||
flathub io.podman_desktop.PodmanDesktop
|
||||
flathub org.gimp.GIMP
|
||||
flathub org.kde.kdenlive
|
||||
flathub org.mozilla.firefox
|
||||
flathub com.obsproject.Studio
|
||||
flathub org.fedoraproject.MediaWriter
|
||||
flathub app.polychromatic.controller
|
||||
flathub org.videolan.VLC
|
||||
flathub com.thincast.client
|
||||
flathub org.raspberrypi.rpi-imager
|
||||
flathub one.flipperzero.qFlipper
|
||||
|
||||
@ -1,14 +0,0 @@
|
||||
#+TITLE: Fairphone setup
|
||||
#+AUTHOR: James Blair
|
||||
#+EMAIL: mail@jamesblair.net
|
||||
#+DATE: <2023-11-03 Fri 16:45>
|
||||
|
||||
|
||||
Below are the steps I follow post standard installation of [[https://ubuntu-touch.io][ubuntu touch]] on my [[https://en.wikipedia.org/wiki/Fairphone_4][Fairphone 4]].
|
||||
|
||||
I've been using the fairphone 4 as a daily driver since April 2023, most recently with Ubuntu Touch.
|
||||
|
||||
|
||||
* Downgrade prior to installation
|
||||
|
||||
After initially purchasing the fairphone, while it was running android I had upgraded to android 12. Unfortunately the ubuntu touch installer is not fully working with Android 12 so I had to downgrade the phone to Android 11 by reinstalling a stock image before proceeding with the ubuntu touch installation.
|
||||
@ -1,188 +0,0 @@
|
||||
{
|
||||
"policy": {
|
||||
"DEFAULT": {
|
||||
"capabilities": [
|
||||
"frame",
|
||||
"fetch",
|
||||
"noscript",
|
||||
"other",
|
||||
"media"
|
||||
],
|
||||
"temp": false
|
||||
},
|
||||
"TRUSTED": {
|
||||
"capabilities": [
|
||||
"script",
|
||||
"object",
|
||||
"media",
|
||||
"frame",
|
||||
"font",
|
||||
"webgl",
|
||||
"fetch",
|
||||
"ping",
|
||||
"noscript",
|
||||
"unchecked_css",
|
||||
"lan",
|
||||
"other",
|
||||
"lazy_load"
|
||||
],
|
||||
"temp": false
|
||||
},
|
||||
"UNTRUSTED": {
|
||||
"capabilities": [],
|
||||
"temp": false
|
||||
},
|
||||
"sites": {
|
||||
"trusted": [
|
||||
"§:addons.mozilla.org",
|
||||
"§:ajax.aspnetcdn.com",
|
||||
"§:ajax.googleapis.com",
|
||||
"§:bootstrapcdn.com",
|
||||
"§:code.jquery.com",
|
||||
"§:google.com",
|
||||
"§:googlevideo.com",
|
||||
"§:gstatic.com",
|
||||
"§:maps.googleapis.com",
|
||||
"§:mozilla.net",
|
||||
"§:noscript.net",
|
||||
"§:paypal.com",
|
||||
"§:paypalobjects.com",
|
||||
"§:yimg.com",
|
||||
"§:youtube.com",
|
||||
"§:ytimg.com",
|
||||
"§:jamma.life",
|
||||
"§:github.com",
|
||||
"§:githubassets.com",
|
||||
"§:dreamhost.com",
|
||||
"§:redhat.com",
|
||||
"§:statuspage.io",
|
||||
"§:southerncross.co.nz",
|
||||
"§:azure.com",
|
||||
"§:stripe.com",
|
||||
"§:b2clogin.com",
|
||||
"§:farmlands.co.nz",
|
||||
"§:dynamics365commerce.ms",
|
||||
"§:amazon.com",
|
||||
"§:awsstatic.com",
|
||||
"§:k8s.io",
|
||||
"§:googleusercontent.com",
|
||||
"§:windy.com",
|
||||
"§:sharesies.nz",
|
||||
"§:slack.com",
|
||||
"§:slack-edge.com",
|
||||
"§:tsbbank.co.nz",
|
||||
"§:kiwibank.co.nz",
|
||||
"§:linuxfoundation.org",
|
||||
"§:cvent.com",
|
||||
"§:cvent-assets.com",
|
||||
"§:airnewzealand.com",
|
||||
"§:airnewzealand.co.nz",
|
||||
"§:airpointsstore.co.nz",
|
||||
"§:reddit.com",
|
||||
"§:redditstatic.com",
|
||||
"§:cve.org",
|
||||
"§:aquasec.com",
|
||||
"§:nist.gov",
|
||||
"§:cvefeed.io",
|
||||
"§:mitre10.co.nz",
|
||||
"§:cloudflare.com",
|
||||
"§:jamma.dev",
|
||||
"§:powershop.co.nz",
|
||||
"§:flux.app",
|
||||
"§:nzfarmsource.co.nz",
|
||||
"§:primehort.co.nz",
|
||||
"§:myworkday.com",
|
||||
"§:opentlc.com",
|
||||
"§:openshift.net",
|
||||
"§:jmhbnz.github.io",
|
||||
"§:redhatworkshops.io",
|
||||
"§:bunnings.co.nz",
|
||||
"§:openshiftapps.com",
|
||||
"§:westpac.co.nz",
|
||||
"§:kapiticoast.govt.nz",
|
||||
"§:discord.com",
|
||||
"§:farmlandspro.co.nz",
|
||||
"§:hnry.io",
|
||||
"§:trademe.co.nz",
|
||||
"§:bitwarden.com",
|
||||
"§:one.nz",
|
||||
"§:vodafone.co.nz",
|
||||
"§:cncf.io",
|
||||
"§:openshift.com",
|
||||
"§:force.com",
|
||||
"§:keddle.net.nz",
|
||||
"§:ycombinator.com",
|
||||
"§:snyk.io",
|
||||
"§:docker.com",
|
||||
"rhdemo.win",
|
||||
"§:clearscore.com",
|
||||
"§:projectbluefin.io",
|
||||
"§:pbtech.co.nz",
|
||||
"§:kde.org",
|
||||
"§:protondb.com",
|
||||
"§:sharesies.com",
|
||||
"§:ryobi.co.nz",
|
||||
"§:metlink.org.nz",
|
||||
"§:sched.com",
|
||||
"§:sched.co",
|
||||
"§:canva.com",
|
||||
"§:safing.io",
|
||||
"§:windcave.com",
|
||||
"§:azure.net",
|
||||
"§:microsoftonline.com",
|
||||
"§:microsoft.com",
|
||||
"§:msftauth.net",
|
||||
"§:mypaymentvault.com",
|
||||
"§:recaptcha.net",
|
||||
"§:salesforce.com",
|
||||
"§:acc.co.nz",
|
||||
"§:realme.govt.nz",
|
||||
"§:redhatstatic.com",
|
||||
"§:starlink.com",
|
||||
"§:quay.io",
|
||||
"§:airbnb.co.nz",
|
||||
"§:onetimesecret.com",
|
||||
"§:concursolutions.com",
|
||||
"§:etcd.io",
|
||||
"§:gitlab.com",
|
||||
"§:sessionize.com",
|
||||
"§:morganstanley.com",
|
||||
"§:hnry.co.nz",
|
||||
"§:wise.com",
|
||||
"§:deerstalkers.org.nz",
|
||||
"§:arcgis.com",
|
||||
"§:muscache.com",
|
||||
"§:ird.govt.nz",
|
||||
"§:p-airnz.com",
|
||||
"§:nzpost.co.nz"
|
||||
],
|
||||
"untrusted": [],
|
||||
"custom": {}
|
||||
},
|
||||
"enforced": true,
|
||||
"autoAllowTop": false
|
||||
},
|
||||
"local": {
|
||||
"debug": false,
|
||||
"showCtxMenuItem": true,
|
||||
"showCountBadge": true,
|
||||
"showFullAddresses": false,
|
||||
"showProbePlaceholders": true,
|
||||
"amnesticUpdates": true,
|
||||
"storage": "local"
|
||||
},
|
||||
"sync": {
|
||||
"global": false,
|
||||
"xss": true,
|
||||
"TabGuardMode": "incognito",
|
||||
"TabGuardPrompt": "post",
|
||||
"cascadeRestrictions": false,
|
||||
"overrideTorBrowserPolicy": false,
|
||||
"storage": "sync"
|
||||
},
|
||||
"xssUserChoices": {
|
||||
"https://mail.google.com>https://www.youtube.com": "allow",
|
||||
"https://drive.google.com>https://youtube.googleapis.com": "allow",
|
||||
"https://auth.redhat.com>https://sso.online.tableau.com": "allow"
|
||||
}
|
||||
}
|
||||
@ -8,7 +8,7 @@ This document captures my standard tooling for future replication and aims to ma
|
||||
|
||||
For the purposes of this repository I broadly refer to tooling as the "standard" way my devices are configured and which things are installed that are non-standard to the operating system.
|
||||
|
||||
The environment is based on [[https://projectbluefin.io/][Bluefin]] for my primary work device which is a 2021 Razer Blade 14". Additionally a subdirectory is included for my smartphone which is a [[https://en.wikipedia.org/wiki/Fairphone_4][Fairphone 4]] running [[https://en.wikipedia.org/wiki/Ubuntu_Touch][Ubuntu Touch]].
|
||||
The environment is based on [[https://projectbluefin.io/][Bluefin]] for my primary work device which is a 2021 Razer Blade 14".
|
||||
|
||||
|
||||
* How I get things done
|
||||
@ -18,14 +18,14 @@ Before diving into the technical details, below is a brief summary of how I get
|
||||
|
||||
** Code editing
|
||||
|
||||
For an editor I primarily rely on [[https://www.gnu.org/software/emacs/][emacs]], specifically [[https://github.com/doomemacs/doomemacs][doom emacs]].
|
||||
For an editor I primarily rely on [[https://www.gnu.org/software/emacs/][emacs]], specifically [[https://github.com/doomemacs/doomemacs][doom emacs]], running within a terminal.
|
||||
|
||||
The main feature that I rely on in emacs is [[https://orgmode.org/][org-mode]]. This allows me to do literate programming, writing my documentation with embedded code blocks that are actually executable or exportable via [[https://orgmode.org/worg/org-contrib/babel/intro.html][babel]].
|
||||
|
||||
|
||||
** Browsing the web
|
||||
|
||||
My primary browser is [[https://www.mozilla.org/en-GB/firefox/new/][firefox]]. Over the years various extensions have come and gone but [[https://github.com/gorhill/uBlock][u-block origin]] has remained a constant and something I use everywhere. Currently I also have [[https://addons.mozilla.org/en-US/firefox/addon/darkreader/][dark reader]] installed to make working in low light situations less harsh.
|
||||
My primary browser is [[https://zen-browser.app][zen]], a fork of firefox. Over the years various extensions have come and gone but [[https://github.com/gorhill/uBlock][u-block origin]] has remained a constant and something I use everywhere. Currently I also have [[https://addons.mozilla.org/en-US/firefox/addon/darkreader/][dark reader]] installed to make working in low light situations less harsh.
|
||||
|
||||
For monitoring traffic, blocking connections, enforcing secure dns and routing connections through other servers vpn style I rely on [[https://safing.io/portmaster/][portmaster]] + [[https://safing.io/spn/][spn]].
|
||||
|
||||
|
||||
43
setup.org
43
setup.org
@ -4,7 +4,7 @@
|
||||
#+DATE: <2022-11-15 Tue 09:15>
|
||||
|
||||
|
||||
This guide will walk through how I setup fresh installations of [[https://projectbluefin.io][Bluefin]]. Bluefin strives to cover these two use cases; For end users it provides a system as reliable as a Chromebook with near-zero maintainance, with the power of homebrew, flathub, and a container runtime to give you access to all the best software Open Source has to offer.
|
||||
This guide will walk through how I setup fresh installations of [[https://projectbluefin.io][Bluefin]]. For end users Bluefin provides a system as reliable as a Chromebook with near-zero maintainance, with the power of homebrew, flathub, and a container runtime to give you access to all the best software Open Source has to offer.
|
||||
|
||||
I use Bluefin as my daily driver operating system on a variety of different machines. The intent of this guide is to make it easy for me to get back up and running quickly whenver I do a fresh installation.
|
||||
|
||||
@ -14,7 +14,16 @@ I use Bluefin as my daily driver operating system on a variety of different mach
|
||||
Additional packages are ideally sourced from [[https://docs.brew.sh/Homebrew-on-Linux][Homebrew for Linux]], with [[https://flathub.org/][Flathub]] for anything I can't find in brew. Included in this repository is my ~Brewfile~ of packages.
|
||||
|
||||
#+begin_src tmux
|
||||
brew bundle install
|
||||
brew bundle install --cleanup
|
||||
#+end_src
|
||||
|
||||
|
||||
* Install flatpak packages
|
||||
|
||||
For anything I can't get through Homebrew for Linux I install via Flathub. Included in this repository is my ~Flatfile~ of packages. Unfortunately the ~flatpak~ cli [[https://github.com/flatpak/flatpak/issues/5876][does not yet support list based installs]] so below is a bash oneliner to get the job done.
|
||||
|
||||
#+begin_src
|
||||
while read line; do flatpak install --assumeyes `echo $line | awk '{print $2}'`; done < Flatfile
|
||||
#+end_src
|
||||
|
||||
|
||||
@ -34,7 +43,7 @@ bw login mail@jamesblair.net
|
||||
|
||||
I make extensive use of ~.dotfiles~ to further customise my environment. The script below restores my versions of key dotfiles automatically.
|
||||
|
||||
*** Obtain ssh key from bitwarden
|
||||
** Obtain ssh key from bitwarden
|
||||
|
||||
In order to be able to clone the repository in the next step we need to obtain our ssh keys from bitwarden. Given we have installed the bitwarden cli we can mostly automte this process minus the initial login to bitwarden.
|
||||
|
||||
@ -50,7 +59,7 @@ ssh-keygen -t rsa -f ~/.ssh/james -q -P ""
|
||||
export BW_SESSION=$(bw unlock --raw > ~/.bw_session && cat ~/.bw_session)
|
||||
|
||||
# Export both keys
|
||||
export key=$(bw get item desktop --pretty | grep notes)
|
||||
export key=$(bw get item "$(hostname)" --pretty | grep notes)
|
||||
|
||||
# Extract private key
|
||||
export private=${key:12}
|
||||
@ -62,7 +71,7 @@ export public=${key/*ssh-rsa/ssh-rsa} && echo ${public::-2} | awk '{gsub(/\\n/,"
|
||||
#+end_src
|
||||
|
||||
|
||||
*** Clone and restore dotfiles
|
||||
** Clone and restore dotfiles
|
||||
|
||||
Once our keys are available to us we can clone down our dotfiles and get back to our comfortable normal terminal environment.
|
||||
|
||||
@ -203,3 +212,27 @@ sbp toggle peekaboo k8s
|
||||
#+end_src
|
||||
|
||||
Congratulations - you should now have a functional, good looking and informative bash prompt! 🎉
|
||||
|
||||
|
||||
** Optional - bluetooth device names
|
||||
|
||||
On a fresh install a selection of bluetooth devices need to be paired. I prefer a custom naming scheme for these devices, so the snippet below can be used to bulk apply my preferred device names.
|
||||
|
||||
#+NAME: Rename bluetooth devices
|
||||
#+begin_src tmux
|
||||
bluetoothctl connect CC:98:8B:B6:F0:8E && bluetoothctl set-alias james-headphones
|
||||
bluetoothctl connect CA:20:FE:30:DA:C0 && bluetoothctl set-alias james-travel-mouse
|
||||
bluetoothctl connect 80:E1:26:6D:66:4A && bluetoothctl set-alias james-flipper
|
||||
bluetoothctl connect 88:C9:E8:5A:56:6C && bluetoothctl set-alias james-earphones
|
||||
bluetoothctl connect E2:A0:9F:BC:DB:27 && bluetoothctl set-alias james-home-mouse
|
||||
#+end_src
|
||||
|
||||
|
||||
** Optional - disable sleep
|
||||
|
||||
I just power off my devices when they aren't in use, the snippet below disables sleep buttons and also ensures my devices will never unintentionally sleep when closing lid etc.
|
||||
|
||||
#+NAME: Disable sleep
|
||||
#+begin_src bash
|
||||
sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
|
||||
#+end_src
|
||||
|
||||
Reference in New Issue
Block a user