In the middle of the desert you can say anything you want
c.tabs.background = True
in config opens new tabs in the background when middle-clicking.
Nurse blocking anti lockdown protests in Denver : PublicFreakout and the imgur album: Health care workers stand in the street in counter-protest to hundreds of people who gathered at the State Capitol to demand the stay-at-home order be lifted in Denver, Colo., on Sunday, April 19, 2020. Photos by Alyson McClaran - Album on Imgur. As someone said, I really imagine seeing this in history books.
To visualize logs of screen
sessions, less -r filename
(-R
hates ^H
progress bars but I search seems to work a bit better) works very well. Even for the (tf) progress bars almost. ansifilter exists but deals with progress bars much worse.
Empirically - for searching and scrolling the same font size / terminal size is very helpful.
Just pasting the Vim macro on Day 469, while it did not break Jekyll this time (why?), seems to have broken the RSS script at the beginning of the page.
This page contains the following errors:
error on line 19 at column 73: PCDATA invalid Char value 27
Copypasted the lines from terminal and back, but I need a much better way to save and ‘publish’ the macros. Found Vim Macro Trickz • Hillel Wayne when looking for solutions.
.. can be added in a bath, but only in a carrier oil, olive oil works.
“For a single bath, three to 12 drops of essential oil in a tablespoon (15 ml) of carrier oil is sufficient to create a very aromatic, therapeutic bath” 1
Can I export a tensorflow summary to CSV? - Stack Overflow – yes I can, by clicking “show data download links” on the top left of interface and selecting what I want to download below the plots.
machine learning - Why training loss is increased at the beginning of each epoch? - Stack Overflow - probably because the dataset is not random enough, and the network overfits on the structure of the dataset. Happens with buffer_size
dramatically less then the size of the structured dataset.
Added config.bind('tw', 'set-cmd-text -s :open -w')
to config, now tw
is like a
, but for windows instead of tabs.
Added this macro:
let @R = 'viw"oyi[^^[^[^[^[A]^[^[^[Go[^^[^[^[^["opA]: ^[^[^[^['
When the last word in the line is selected, it gets transformed immediately to a reference. I’ll use this vim cheatsheet as 1.
Vim cheatsheetVim cheatsheet
As a bonus, this uses a non-default vim register so whatever is in my clipboard stays there. (But it destroys whatever I had in "o
). ↩︎
Mafia distributes food to Italy’s struggling residents
In recent days, the police in Naples have intensified their presence in the poorest quarters of the city, where men tied to the Camorra, the Neapolitan mafia, have organised home delivery of food parcels. Magistrates have already begun an investigation against a group of people who were questioned while distributing food to local residents.
The Science of Happiness | Greater Good is a podcast about happiness, found it while looking for The Happiness Lab which is also a podcast about happiness.
Screens named with screen -S myname
and attached by screen -r myname
- tab completion works with screen -r
!
entry
is the time the task was created. So:
task all sprint:$SPRINT status:pending entry.before:eow-3wk tags.not:s rc.report.all.columns:entry,end,tags,description rc.report.all.labels=Age,Done,Tags,Description rc.report.all.sort:end rc.verbose:label,blank
is what I’ll use in SIOM.
I missed this all my life.
If more than 1 GPU are visible, tensorflow will take some memory on all of them, even if its actively using only one. Restricting visibility the usual way helps.
task all status:completed end.after:eow-2wk
– I forgot you could do almost-math with the datetimes!
Editing the output, to sort it by project, divide different ones by newlines, and show the headers of the table but nothing else:
task all status:completed end.after:eow-2wk rc.report.all.columns:project,entry,end,tags,description rc.report.all.labels=Project,Created,Finished,Tags,Description rc.report.all.sort:project-/,end rc.verbose:label
This is a really nice video: How to Make Perfect Pizza | Gennaro Contaldo - YouTube
Using an userscript for this is overkill, but
#!/usr/bin/python3
import os
title = os.environ['QUTE_TITLE']
url = os.environ['QUTE_URL']
with open(os.environ['QUTE_FIFO'], 'w') as f:
f.write("yank inline \"[{} {}]\"".format(url, title))
Located at /home/shamotskyi/.local/share/qutebrowser/userscripts/yank_w.py
.
In the config, config.bind('yw', 'spawn --userscript yank_w.py')
EDIT: replaced this with config.bind('yw', 'yank inline "[{url} {title}]"')
.
I have not been using it to the fullest.
List tasks completed today: task all status:completed end:today
This might be something I can copypaste into my pages or in my reports, such as my weekly sprint review! Adding it as a module to siom
should be not too hard. Taskwarrior - Usage Examples contains more nice examples.
glob is not sorted!
glob.glob().sorted()
though is.
kitty - the fast, featureful, GPU based terminal emulator — kitty 0.17.2 documentation:
ctrl+shift+s
is paste from selection
ctrl+shift+u
for unicode characters
sudo update-alternatives --config x-www-browser
Doesn’t seem to work for kitty, but in the config open_url_with qutebrowser
works predictably.
gratuitous - Wiktionary - given freely, unearned; without reason, unjustified, unnecessary, uncalled for. Seen first in Behemoth by Peter Watts.
For the sake of consistency (to each other and especially to Google Calendar) now my sprint number and week number is the ISO week number:
export SPRINT=$(date +%-V)
Fixed this in:
tztime local {
format = "[%V] %a %Y-%m-%d %H:%M:%S"
}
Only place it’s left now is in my paper calendar, but I don’t use it too much these days.
balmy - Wiktionary - soothing, fragrant, mild, pleasant. Found in Behemoth by Peter Watts.
I should check vim modelines (Vim documentation: options) out, systematically.
Try adding cauliflower in my pasta water 1
And pasting my favourite Reddit comment for posterity:
[deleted] 385 points · 1 year ago · edited 1 year ago
This isn’t wrong, but not the tradition Italian way. The way we do it in Italy (Sicily) is to split the sauce in half. Take the pasta out about a minute or less before al dente. If you’re going for the creamy flavor, sauce permitting, mix some butter with the pasta as you’re draining the water. Then put the pasta in the sauce pan with half of the sauce and a (tiny) bit of pasta water. 1/4 of a cup is too much in our opinion because you don’t want to cook the pasta in the sauce for too long. Use the other half of the sauce to top it off. That’s not to say this is the only way Italians do it, but my Southern Italian family has been using this method for generations. I’m not a fan of OP’s method, if you want this kind of pasta just make a cacio e pepe.
On a separate but related note, tomato sauces (without meat) should only be cooked for 30 minutes, after that they lose the aroma. Of course I’m biased, but a simple tomato sauce is one of the easiest and most delicious things in the world to make. Simmer garlic until sizzling (add red pepper flakes with garlic for arrabbiata) add decent plum tomatoes (buy whole ones and hand crush them) with S&P, basil, oregano. You can add some butter if you like. Stir occasionally, 30 minutes later you’re done.
Edit: I always used to laugh to myself when I saw people getting excited about getting their first gold, and now I’m that person. Thanks kind stranger. 2
You can freeze bread without problems:
He starts with what not to freeze: “I never recommend freezing things like baguettes or ciabatta. Anything that has a large surface-to-crumb ratio just never refreshes the same.” 3
If baking, let your bread cool completely. This will prevent it from becoming soggy or moldy. Wrap each loaf tightly in plastic wrap. Then wrap it in foil or freezer paper. The double-wrap is your secret weapon for freshness.4
Unfreezing works overnight in the refrigerator. 4
While I’m at it, the yeast ratio is 2 1/4 teaspoons dry active, instant, or rapid-rise yeast granules (usually one 1/4-ounce packet) = 2/3 ounce fresh yeast 5
If I do annotations / sources / references, I have to put the definition on a new ’new’ line, so it’s a new block. This was my error back at the very beginning. Not one
Vim macro to create an reference based on a selected line.
What’s the deal with Italians not combining onion and garlic in dishes…? : Cooking ↩︎
LPT: If you like a lot of Parmesan cheese on your pasta, put it on the pasta and mix it around before you cover it in the sauce. Every noodle will be coated in cheese and covered in sauce. It will change your life. : LifeProTips ↩︎
Can You Freeze Bread? Yes, Here’s How. | Taste of Home ↩︎ ↩︎
Does Fresh Yeast Make a Difference When Baking Bread? | Kitchn ↩︎
config.bind('E', 'set-cmd-text -s :edit-url')
added to config.py
allows me to press E and the command will be prefilled.
Interesting arguments 1:
-b, --bg: Open in a new background tab.
-t, --tab: Open in a new tab.
-w, --window: Open in a new window.
-p, --private: Open a new window in private browsing mode.
Made the following changes and bumped the version to v5:
// Changing aoeu for umlauted letters
key <AC01> { [ a, A, adiaeresis, s] };
key <AC02> { [ o, O, odiaeresis, n] };
key <AC03> { [ e, E, ediaeresis, t] };
key <AC04> { [ u, U, udiaeresis, u] };
// Adding ~` to the better key for this
key <AD01> { [ apostrophe, quotedbl, grave, asciitilde] };
key <AD02> { [ comma, less, r, asciitilde] };
// Adding parentheses in a better place
key <AD08> { [ c, C, Up, parenleft ] };
key <AD09> { [ r, R, BackSpace, parenright ] };
key <AD07> { [ g, G, bracketleft, braceleft ] };
key <AD10> { [ l, L, bracketright, braceright] };
// Numbers!
key <AB01> { [ semicolon, colon,1, exclam] };
key <AB02> { [ q, Q, 2, at ] };
key <AB03> { [ j, J, 3, numbersign ] };
key <AB04> { [ k, K, 4, dollar ] };
key <AB05> { [ x, X, 5, percent ] };
key <AB06> { [ b, B, 6, asciicircum] };
key <AB07> { [ m, M, 7, ampersand] };
key <AB08> { [ w, W, 8, asterisk] };
key <AB09> { [ v, V, 9, asterisk] };
key <AB10> { [ z, Z, 0, asterisk] };
// A new delete key
key <AC06> { [ d, D, KP_Delete, asterisk] };
Now I have brackets on my right hand letters :) I’ll think later what other symbols I still have not learned by heart and move the below. (Numbers, maybe?)
Updated the userscript to the following, now it removes stuff Mediawiki doesn’t like from the name of the page (but not from the Title, which is not part of the URL!)
#!/usr/bin/python3
import os
from urllib.parse import quote_plus
def urlencode(string):
return quote_plus(string)
def replace(original):
new = original.replace("|", "-")
return new
def replace_name(original):
new = original.replace("|", "-")
new = new.replace("[", "(")
new = new.replace("]", ")")
new = new.replace("#", "(hash)")
new = new.replace("{", "(")
new = new.replace("}", ")")
new = new.replace("_", " ") # TODO test
return new
title = os.environ['QUTE_TITLE']
url = os.environ['QUTE_URL']
selected_text = os.environ['QUTE_SELECTED_TEXT']
newTitle = replace(title)
newArticleName = replace_name(title)
newUrl = replace(url)
newText = replace(selected_text)
print(newTitle)
article_title = urlencode(newTitle)
article_name = urlencode(newArticleName)
page_url = urlencode(newUrl)
selected_text = urlencode(newText)
fiammaUrl = 'https://pchr8.net/f/index.php'
url = fiammaUrl+'?title='+article_name+'&action=edit&preload=Template:NewLink&preloadparams[]='+page_url+'&preloadparams[]='+article_title+'&preloadparams[]='+selected_text
with open(os.environ['QUTE_FIFO'], 'w') as f:
f.write("open -w {}".format(url))
This is a nice wikipedia page that starts with “Q.” and not with “Q:”, because “Q:” is forbidden as start of page name: Q. Are We Not Men? A: We Are Devo! - Wikipedia
I’ll try to do this tomorrow: The Best Pizza Dough Recipe - Sugar Spun Run
For when I get to this, it’s easy, after I install matterhook
:
>>> mwh = Webhook('https://chat.mycompany.de', 'myAPIhook')
>>> mwh.send('test',channel='notif')
Very nice explanation here: GitHub - numberly/matterhook: Interact with Mattermost incoming webhooks easily.
Say I’m in folder2 and want to run folder2/folder/main.py
python3 -m folder.main
adds folder2 to $PATH
, while python3 folder/main.py
adds folder
to $PATH
. The first option makes all imports much much easier.