In the middle of the desert you can say anything you want
Nice discussion: How do you manage your dotfiles across multiple and/or new developer machines? - DEV Community
This article also provides a really nice explanation of the general practice that many people seem to be taking: store dotfiles in GitHub, and then install them via a simple script that symlinks files and runs any additional init logic.
… not that I’ve ever used it or plan to (google, don’t ban me before I finished switching to FastMail!), but - NewPipe supports searching and playing videos from Youtube Music!
Serial-position effect “is the tendency of a person to recall the first and last items in a series best, and the middle items worst”. Related is the Von Restorff effect about the most different stimuli being easier to remember.
.. never used it because didn’t find it pleasant to use because no scrolling and clicking as I’m used to, but I can fix this! Google told me I should install synaptics stuff and use synclient to config it, but..
(21:30:13/11094)~/$ synclient
Couldn't find synaptics properties. No synaptics driver loaded?
Google led me here: x11 - synclient does not find synaptics properties despite Synaptics Touchpad in xinput list - Unix & Linux Stack Exchange
So in fact the “problem” is that touchpads is nowadays handled by
libinput, not bysynaptics. This is why xinput still lists the device, but synclient cannot find it.The touchpad properties can also be controlled using xinput, via
xinput list-propsandxinput set-prop
Which works! xinput set-prop $device $propID $value, where the property id is given in parentheses in xinput list-props output:
libinput Tapping Drag Enabled Default (330): 1
So I (in case gets reset after restart):
xinput set-prop 15 327 1 #enabled tapping
xinput set-prop 15 312 0 1 0 # scroll through side of touchpad
Interestingly, xinput set-prop 15 312 1 1 0 didn’t work, apparently I have to choose one. (Same for “click methods”)
Now we pray the xorg/synaptics drivers I installed at the beginning don’t mess up everything after restart ^^ I followed this: How to Activate Two-Finger Scrolling in Ubuntu 18.04 LTS
The ArchWiki is excellent as usual. TIL a tap with three fingers is a shortcut for “paste” and you can change/remap that as everything else! Wow.
TODO - play with buttons and three-taps and two-taps and the physical buttons. Also, where does it define that button N is “paste”? And which clipboard are we talking about?
And - I can do it with my usb mouse!
Extremely helpful answer: Revisions to Passing a dictionary to a function as keyword parameters - Stack Overflow
I also really like this approach:
A few extra details that might be helpful to know (questions I had after reading this and went and tested):
- The function can have parameters that are not included in the dictionary
- You can not override a parameter that is already in the dictionary
- The dictionary can not have parameters that aren’t in the function. Examples:
(Connects with my long-forgotten way of ‘after reading something, ask questions, try to find faults, try to find places this isn’t going to work, try to find connections with stuff you already know, try to find contradictions with stuff you already know’ etc., I have to start doing this again)
Main culprit is this code, and changing that value to anything makes life better:
.adg3 .issue-container {
max-width: 1280px;
}
This line toggles between solarized-everything1 and the above snippet for making jira wide again.
config.bind(',c', 'config-cycle content.user_stylesheets "~/.config/qutebrowser/css/solarized-dark-generic.css" "~/.config/qutebrowser/css/jira.css"')
Sadly no automatic per-website-css possible yet, it seems.
alphapapa/solarized-everything-css: A collection of Solarized user-stylesheets for…everything?
Had issues with NoiseTorch microphone not working, fixed by changing the microphone and then back. (…) While I’m at it, updated NoiseTorch, and added this snippet to the polkit config to not-enter passwords: I don’t want to enter my password everytime · lawl/NoiseTorch Wiki
Still exists and still works!
sshfs me@server:/some/folder /my/local/folder -p 12345umount /my/local/folder
An insecure faster version is: sshfs -o Ciphers=aes128-ctr -o Compression=no me@server:/some/folder /my/local/folder -p 12345
(In my case, most of my lag was from zsh git prompt plugin, removing it made it much faster)
When a monitor stops working, sometimes it is fixed by deactivating/applying/activating/applying in arandr, or doing any changes to it intead of deactivating it. I’ve been changing its resolution, but to maximally preserve the layout, just inverting it (and back) works too!
Nomacs is extremely slow when viewing images located on a remote server, any other viewer works for me. The default one is eog / “Eye of Gnome”
tracemalloc is part of the python standard library!
This snippet from the docs1 has everything:
import linecache
import os
import tracemalloc
def display_top(snapshot, key_type='lineno', limit=10):
snapshot = snapshot.filter_traces((
tracemalloc.Filter(False, "<frozen importlib._bootstrap>"),
tracemalloc.Filter(False, "<unknown>"),
))
top_stats = snapshot.statistics(key_type)
print("Top %s lines" % limit)
for index, stat in enumerate(top_stats[:limit], 1):
frame = stat.traceback[0]
print("#%s: %s:%s: %.1f KiB"
% (index, frame.filename, frame.lineno, stat.size / 1024))
line = linecache.getline(frame.filename, frame.lineno).strip()
if line:
print(' %s' % line)
other = top_stats[limit:]
if other:
size = sum(stat.size for stat in other)
print("%s other: %.1f KiB" % (len(other), size / 1024))
total = sum(stat.size for stat in top_stats)
print("Total allocated size: %.1f KiB" % (total / 1024))
tracemalloc.start()
# ... run your application ...
snapshot = tracemalloc.take_snapshot()
display_top(snapshot)
Added <Shift+Alt+C> for “commit”, since <Ctrl+K> doesn’t work (and afaik is not used for anything else).
(<Ctrl+Shift+C> is still “copy path”)