Jackeoz' personal website
Ubuntu fixes and tricks
that I was storing in a .txt file somewhere. I'll leave it in
monospace because that's how I formatted it as plain text. I might
make it prettier later, but I doubt it.
FIXES:
run sudo 'lshw -C network' to check status of wireless driver
fix: install bcmwl-kernel-source and follow instructions
install vim and vim-gtk (to get clipboard support)
run 'dmesg' to check bluetooth status
fix: copy the related firmware file to /lib/firmware/brcm
from the winterheart/broadcom-bt-firmware GIT repository.
source:
https://www.nielsvandermolen.com/bluetooth-headphones-ubuntu/
for headset microphone not working:
change pulseaudio for pipewire
source:
https://askubuntu.com/questions/831331/failed-to-change-profile-to-headset-head-unit
something about ubuntu bluetooth
https://dev-pages.info/ubuntu-bluetooth/
if system insists on using external microphone when plugging
headphones in (even when there is none) one solution is installing
hdajackretask from alsa-tools-gui and overriding the mic jack to Not
Connected. Read documentation.
Note: Supposedly it's not good to run hdajackretask with sudo.
texlive:
make sure there is no texlive installed
install texlive from texlive website
softly symlink tlmgr, pdflatex and latexmk
from /usr/local/texlive/20XX/bin/x86_64-linux
to /usr/local/bin
indicator stickynotes
enable "use autoscrolling" in firefox
install vim-plug (requires curl and git, see instructions at github)
configure vimtex and ultisnips (See Guilles Castel guide)
my vimrc includes
set tw=70 tabstop=2 shiftwidth=2 expandtab number
download gnome-tweaks to customize screenshots folder
add shortcuts
for full screenshot: gnome-screenshot
for area screenshot: gnome-screenshot -a
for terminal at path: gnome-terminal --working-directory="/path"
for mp3 and mp4 etc, install ubuntu-restricted-extras
Fix opera:
install the chromium-ffmpeg from snap and link one of the
libffmpeg.so files to opera, for example
sudo ln -s /snap/chromium-ffmpeg/XX/chromium-ffmpeg-XXXXX/chromium-ffmpeg/libffmpeg.so /usr/lib/x86_64-linux-gnu/opera/
To restart open tablet driver and make sure gnome is not interfering
systemctl --user restart opentabletdriver
removed xserver-xorg-input-wacom
http://bolide.run/Wiki/FAQ/Linux
OTHER TRICKS
extract pages from pdf:
pdftk full-pdf.pdf cat 12-15 output outfile_p12-15.pdf
analyze startup times:
systemd-analyze blame
shell version: $SHELL --version
add pulse-audio sinks:
pactl load-module module-null-sink sink_name=MySink
pactl load-module module-loopback sink=MySink
pactl unload-module
convert png to pdf:
mogrify -format pdf -units PixelsPerInch *png
one can specify density with -density
if this doesn't work, edit /etc/ImageMagick-6/policy.xml of
ImageMagick-6. In that file, change the policy rights to read/write
change to
merge pdf files using ghost script:
gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -dAutoRotatePages=/None -sOutputFile=finished.pdf file1.pdf file2.pdf
rotate pdf +90 or -90 degrees:
pdftk input.pdf cat 1-endwest output output.pdf
pdftk input.pdf cat 1-endeast output output.pdf
convert mp4 to ogg
ffmpeg -i input.mp4 -codec:v libtheora -qscale:v 3 -codec:a libvorbis \
-qscale:a 3 -f ogv output.ogv
bulk conversion of webp to png:
find . -name "*.webp" | xargs -I {} dwebp {} -o {}.png
webm to mp4:
ffmpeg -i video.webm video.mp4
images to mp4:
ffmpeg -framerate 25 -pattern_type glob -i '*.png' -c:v libx264 -profile:v high -crf 20 -pix_fmt yuv420p output.mp4
youtube-dl -x --audio-format vorbis -a lista
| xargs -I {} program "{}"
tree -f -a > salida.txt
make git store username and password forever:
git config --global credential.helper store
make git store username and password for a session:
git config --global credential.helper cache
.bash_profile and .bashrc are specific to bash, whereas .profile is
read by many shells in the absence of their own shell-specific config
files. (.profile was used by the original Bourne shell).
.bash_profile or .profile is read by login shells, along with .bashrc;
subshels read only .bashrc
zbarimg is a command line tool that can read qr codes
one can find it in the ubuntu package called zbar-tools