All Posts
Kill process listening on a specific port
- 09 June 2024
Possible title underline, too short for the title. Treating it as ordinary text because it’s so short.
Expression programming languages
- 20 April 2024
According the Chomsky hierarchy, there are 4 categories. From most expressive to least:
QES
- 19 March 2024
Penneo is a qualified trust provider: https://eidas.ec.europa.eu/efda/tl-browser/#/screen/tl/DK/3
Implementing One-to-Many relationship
- 04 March 2024
Let’s say we have to implement a relationship between a Folder and a File.
Json in Postgres
- 02 November 2023
Let’s say you have a json object stored in a table called process:
How to send notifications from server to client?
- 17 October 2023
There are 3 ways of getting notified by the server:
Connect to the host from a docker container
- 01 September 2023
Use the extra_hosts option in docker-compose:
Readonly role for Postgres
- 09 August 2023
Let’s create a readonly role for a database called postgres and schema public.
VS Code and Copilot on Debian
- 04 July 2023
Run the daemons and export the env variables for dbus and the keyring:
Principles of communicating with your line manager
- 04 March 2023
Make the communication effective by using one of the following 4 cases:
Watch and run typescript file
- 21 February 2023
Assuming that you want to compile and watch main.ts, then compile it and run the .js equivalent:
Code formatting
- 29 January 2023
There are a number of tools to format code with potentially overlapping features:
NPM Dependencies
- 21 January 2023
Installed transitively e.g. two packages A and B have to be installed and each depend on a different version of C, then the following graph is installed:
myers-briggs
- 16 January 2023
Myers-Briggs Type Indicator (MBTI) is a type of personality tests that categorizes people in the following groups:
Org links
- 24 December 2022
Copy a link: org-store-link or SPC a o l Past the link: org-insert-link-global
Preflight Requests
- 24 November 2022
A preflight request is a CORS (Cross Origin Request Sharing) request to check if the CORS protocol is understood by the server.
Think clearly
- 21 November 2022
“Influence” by Robert B. Cialdini: https://www.goodreads.com/book/show/28815.Influence
Install Debian
- 24 September 2022
Download the complete iso from: https://cdimage.debian.org/cdimage/weekly-builds/amd64/iso-dvd/
Dual boot (UEFI)
- 24 September 2022
update-grub automatically takes care of this by probing the EFI directory.
AdES vs QES
- 12 August 2022
According to the eiDAS regulation, there are 3 levels of electronic signatures:
Deep partial
- 03 August 2022
There is no native Partial functionality if we want to apply it to the nested properties of an object as well.
Debugging external monitor issues in Linux
- 02 August 2022
Sometimes when I connect the external monitor using usb-c, it gives the following error:
Update a package in Arch Linux
- 25 June 2022
For packages installed using the native package manager i.e. pacman:
Get installed packages in Arch Linux
- 25 June 2022
Get all the installed packages. Use the query -Q switch:
Virtual environments
- 04 January 2022
Python 3.3+ comes with venv. Prevously, it was required to install virtualenv using pip.
Syed Balkhi
- 04 January 2022
Heard about him on The Hustle MFM as owner of a number of wordpress plugins and generating a revenue of 30-40 Million DKK. It seems like that intro is a bit simplified when you look at his website.
NLP
- 04 January 2022
Hyponum/hypernym: Hierarchical relationships e.g. types of fruits and then peach, apple, etc. Meronym: Relationshiop between Part and whole e.g. wheel and car. Coreference: she is the same as ‘Mary’ Constituency trees: another way to represent syntax Stemming: removing/replacing suffixes to get the root form Lemmatization: base form of a word e.g. ‘good’ is a lemma of better’
Alexander Lew
- 04 January 2022
[Talk] Probabilistic scripts for automating common-sense tasks: https://www.youtube.com/watch?v=MiiWzJE0fEA&feature=youtu.be&ab_channel=StrangeLoop
Cross site request forgery (CSRF)
- 24 October 2021
An exploit when the attacker lures the victim on a legit domain e.g. acme.com, to a domain they control e.g. evil.com, and tricks them into clicking a button that sends a request to the legit domain.
Clojure Spec
- 24 October 2021
Note: Instrumentation only works for :args in a function definition. :fn and :ret are only used during generative / property based testing.
Angel Investing
- 02 April 2021
Best way to get into it is to get involved into a fund managed by someone else. According to angel list, there are 3 options:
clj
- 30 December 2020
Here is an example how you can enhance the vanilla clj tool: https://github.com/seancorfield/clj-new
Virtual Machine
- 30 December 2020
I’ve tried virtual box before. I’ve heard that KVM is faster so I want to give it a try:
Traffic sniffing
- 30 December 2020
When all fails, wireshark is the tool. However, I just found out about mitmproxy which seems to be the winner … hands down!
Track Memory Usage of a Process
- 30 December 2020
Image that you want to track the memory usage of dotnet, use the watch command with ps to get an overview of the memory usage:
Stocks vs Options vs Futures vs Bonds
- 30 December 2020
Simple definition from: https://www.quora.com/What-are-the-differences-between-stock-options-futures-bonds-ETFs-forex
Software Transactional Memory
- 30 December 2020
A high level abstraction to simplify concurrent programming. It allows a group of read/write instructions to execute in an atomic way.
SciKit vs PyTorch
- 30 December 2020
SciKit it for classical machine learning, easier to use, not as configurable. PyTorch is for deep learning, relatively difficult to start using, more configurable
Ratios : Liquidity vs Solvency
- 30 December 2020
It is how easily can the assets be converted to cash.
PlantUML
- 30 December 2020
Spacemacs comes with a plantuml
layer which has a major mode for modifying such files.
Markdown vs Restructured Text
- 30 December 2020
Emacs has good support for markdown: - folding - create tables
Laziness
- 30 December 2020
Let’s create a lazy list of numbers, only realized as we ask for the values. The IEnumerable interface in conjunction with the yield operator allows this.
Language
- 30 December 2020
def: defines an immutable label for the right side content which is lazily evaluated - evaluate by name.
Internet Computer
- 30 December 2020
Possible title underline, too short for the title. Treating it as ordinary text because it’s so short.
Intermediate Language (IL)
- 30 December 2020
Also referred to CIL (Common IL) or MSIL (Microsoft IL).
HyperLogLog sketch
- 30 December 2020
HyperLogLog is an algorithm for the count-distinct problem, approximating the number of distinct elements in a multiset. [1]
Graphing (n more) Libraries
- 30 December 2020
Here are some of the graphing libraries that I have found:
Graph databases
- 30 December 2020
Graph databases make sense when you want to create relationships between data and quickly query them.
Domain name resolution
- 30 December 2020
Information is stored in the form of DNS records. There are different types of records and some of them required for our discussion are mentioned below:
Conway’s Game of Life
- 30 December 2020
Dylan Beattie on Game of Life: https://www.youtube.com/watch?v=6avJHaC3C2U&feature=youtu.be&t=264
Build systems
- 30 December 2020
Reid McKenzie’s talk about ‘Tools, Deps, Magic Balls’: https://www.youtube.com/watch?v=ze7OI9iVCiI
Bind mount
- 30 December 2020
Using a bind mount might seem to accomplish what a symlink does but it happens at a lower level and changes the underlying topology of the filesystem (and hence it requires root privileges).
At your fingertips
- 30 December 2020
Some operations should be extremely convenient - they should be second nature:
Unmap a symbol from a namespace
- 17 February 2020
The simplest would be to update the expression that loads everything e.g.:
Interactively discard hunks
- 17 February 2020
With the following command, the staged changes can be unstaged:
Corecursion
- 17 February 2020
The co- is to indicate that it is opposite of recursion (e.g. sine and cosine).
Clojure runner
- 17 February 2020
The runner, invoked by calling clojure or simply clj is a tool/script to invoke the clojure compiler and the repl.
Terminology
- 14 January 2020
Buffer When you open a file in emacs, it creates a buffer to visit that file. Frame This is what I call a floating window. Emacs had a different meaning for window. Window It is that space on the screen or view that shows you the buffer. It might be that multiple buffers are open but only a few windows are showing those buffers.
C4 model
- 14 January 2020
Buildings have specific floor plans, site plans, etc. There is no standard for software architecture. C4 tries to solve this.
Function composition
- 04 December 2019
Here are a few ways to create new functions from existing functions:
WASB
- 30 November 2019
Windows Azure Storage Blob (WASB) is a filesystem on top of HDFS. This allows persistence of the data in Azure Storage Accounts instead of local disk. This way the hadoop cluster can be shut down when no computation is taking place.
Configuring External Monitors
- 30 November 2019
xrandr is a popular lib. For a GUI version, use arandr which lets you create a screen layout and save it as a bash script.
Azure Data Lake
- 30 November 2019
Azure data lake can be used to store any type of data whether it is:
Getting started
- 13 November 2019
Emacs uses CIDER to work with clojure. There are quirks that I am getting used to but the following is good enough to get started. CIDER comes packaged with the spacemacs clojure layer.
Generate project dependency graph
- 13 November 2019
ns-dep-graph is a lein plugin for visualizing the dependency graph of a project.
Azure Service Fabric
- 13 November 2019
Plural site course (focusing on ‘Reliable Services’) https://app.pluralsight.com/course-player?clipId=ec014437-6f1b-49e0-a70f-47878c055bcb
Use the swap partition instead of the swap file
- 16 October 2019
To persist these changes across reboots, update the fstab file and edit /swapfile to /dev/nvme0n1p3
Resize the mounted parition
- 16 October 2019
Start the machine using a ‘recovery’ usb. This makes it possible to work with the partition as it is not mounted.
OAuth 2.0 vs OpenID Connect
- 17 September 2019
These are different tools for different jobs, you can use both of them at the same time:
HTTP functions
- 17 September 2019
To encode values use url-hexify-string (which is similar to encodeURIComponent in JS)
Ansible
- 08 September 2019
If we want that jq is installed on a Debian machine, the following playbook can be used:
Pact
- 13 July 2019
Pact is an implementation of “consumer driven contract” testing that allows mocking of responses in the consumer codebase, and verification of the interactions in the provider codebase.
Authentication
- 13 July 2019
Validating tokens: https://docs.microsoft.com/en-us/azure/active-directory/develop/access-tokens#validating-tokens
HTTP Response Header: X-Content-Type-Options
- 28 May 2019
This is how the X-Content-Type-Options header is used:
Find a lost commit
- 16 May 2019
Git reflog contains the complete history of everything that happened. So if you committed something and then lost the commit due to a reset or a rebase, you can still find the commit by looking into the reflog:
Displaylink on Ubuntu 18.04
- 14 May 2019
I want to use additional monitors and I got a ThinkPad Hybrid USB-C with USB-A Dock It looks like this: