docker logout
rm ~/.docker/config.json
sudo rm /usr/bin/docker-credential-pass
docker push stopped working after enabling credentials store. Above is how to disable the store.
Just another WordPress site
docker logout
rm ~/.docker/config.json
sudo rm /usr/bin/docker-credential-pass
docker push stopped working after enabling credentials store. Above is how to disable the store.
echo “Xft.dpi: 280” > ~/.Xresources
Set the following environment variable in session settings.
XCURSOR_SIZE
=100
Taken from here.
In the .config/lxsession/Lubuntu/desktop.conf change the following line:
iGtk/CursorThemeSize=72
Preferences > LXQt settings > Shortcut Keys
Taken from here.
(1) In a new tab, type or paste about:config in the address bar and press Return. Click the button accepting the risk.
(2) In the filter box, type or paste devp and pause while the list is filtered — there should only be one preference left.
(3) The layout.css.devPixelsPerPx normally has -1.0 which follows the Windows Text Size setting.
Double-click to open a small dialog where you can type a new value.
Taken from here.
Fonts in QT apps in Lubuntu on high-res displays are too small.
Solution is to add these 2 lines at the end of .basrc:
export QT_QPA_PLATFORMTHEME="qt5ct"
unset QT_STYLE_OVERRIDE
Then install qt5ct:
$ sudo apt-get install qt5ct
Then start qt5ct and configure font size to match your display resolution.
Based on this and this articles.
Ellipses below are short delays of a few seconds – to let your machine complete system requests after pressing the letters.
Hold Alt+SysRq and press one by one with small pauses r…e…i…s…u…b/o, b – for reboot, o – for shutdown.
Depending on your keyboard – say, it’s German, and the Right Alt is AltGr actually, then the Alt should be the Left Alt.
If SysRq is missing on your keyboard – try PrintScreen instead. The PrintScreen on multimedia keyboards sometimes is accessible in combination with a Fn button.
Based on this Wikipedia article.
Composite (or compound) data types consist of a few primitive data types or other composite types. Examples of composite data types are C/C++ structure and union.
Let’s look at the C/C++ structure example:
struct account {
int account_number;
char *first_name;
char *last_name;
float balance;
};
This type contains account_number AND first_name AND last_name AND balance fields – the AND makes it a product type, where product is boolean AND.
Let’s now look at the following example of C/C++ union:
union number {
int8_t i8;
int16_t i16;
int32_t i32;
int64_t i64;
float f32;
double f64;
};
This type can accommodate an int8_t OR int16_t OR int32_t OR int64_t OR float OR double number – the OR makes the type a kind of sum type (not quite yet), where sum is boolean OR.
This is not the whole of the sum data type yet. The actual type of the data currently stored in a C/C++ union is only known at run time, and the program that uses the union should be able to handle that at run time.
The union can be extended to tagged union, which may look like this:
struct number {
uint8_t tag;
union {
int8_t i8;
int16_t i16;
int32_t i32;
int64_t i64;
float f32;
double f64;
} value;
}
The tag specifies the type of the value at run time.
Such tagged union type is called sum data type.
Product and sum data types are the base algebraic data types. The data types composed of product and sum data types are called hybrid data types.
It probably makes not that much sense to use the struct number type for the balance field in the struct account, but here it is – a hybrid data type example:
struct account {
int account_number;
char *first_name;
char *last_name;
struct number balance;
};
The product, sum and hybrid data types are what is called algebraic data types.
Please keep in mind that the sequence described below presumes certain level of Linux and Android knowledge, e.g. how to mount SD-cards in Linux, how to edit Android boot configuration settings, or how to use Android Debug Bridge.
Follow emteria.OS download and install instructions – you will be asked to create an Emteria account.
If you decide to not yet pay for emteria.OS personal or business license, and use free evaluation license – be prepared to system reboots after 8 hours, and an evaluation license notice pop up now and then.
Mount the SD-card in your Linux box, edit emteria.OS’s /boot/config.txt, enable safe HDMI configuration:
hdmi_safe=1 #hdmi_group=2 #hdmi_drive=2 #hdmi_mode=82 #hdmi_cvt=1024 768 60 6 0 0 0 #hdmi_force_hotplug=1 disable_overscan=1 dtoverlay=vc4-kms-v3d,cma-256 avoid_warnings=2 dtparam=sd_force_pio=on dtparam=i2c1=on dtparam=i2c_arm=on dtparam=audio=on audio_pwm_mode=2 initial_turbo=30 start_x=1 kernel=u-boot.bin
Save the changed /boot/config.txt file, unmount the SD-card.
Alternatively, you might want to configure all HDMI parameters manually – this is a rather tricky process which only worked for me with a dated non-HD resolution display.
Insert the emteria.OS SD-card into your Raspberry Pi, connect display, keyboard and mouse, power up.
For the next step your Raspberry Pi has to be connected to internet – via ethernet or wifi. In case of wifi – choose your wifi network and enter password, as usually in Android. Check internet connectivity in the emteria.OS browser.
The emteria.OS comes without Google Play Store which we will need in the next step to install and unlock Synthesia. To install Google Play Store – follow the process explained here:
After reboot – start Google Play and configure your Google account
You have to be patient while Android is busy with “System optimization in progress, please wait…” – it takes quite some time (longer than 1 day) and a few reboots, Android will be rather unresponsive all that time.
That might be that the “Sytem optimization…” message, the evaluation license pop ups, and Android’s lack of responsiveness would feel a bit frustrating, and you would probably want to try to reboot your Raspberry Pi – just to check that it did not go south incidentally. Here is a way how to do that (please also see the screenshots further below):
### Connect $ adb connect 192.168.1.144 connected to 192.168.1.144:5555 ### Just checking if it's there $ adb devices List of devices attached 192.168.1.144:5555 device ### Reboot $ adb reboot
I downloaded and installed Synthesia APK manually in the emteria.OS browser – to do that you need to go to generate Synthesia APK download link – the APK will be downloaded and installed.
Alternatively, you can install Synthesia from Google Play Store.
If you have Synthesia unlock key – unlock Synthesia as usually. For that you will need Google Play Store installed and your Google account configured, otherwise Synthesia complains it has no internet connection.
Synthesia installed
Evaluation version pop-up
Synthesia
Emteria settings
Disabling auto-update Goolge apps
Google Play
Synthesia unlock
Play demo
YouTube streaming
How to debug with gdb on command line – see Raspberry Pi: gdb debugging, command line.
How to debug with gdb in Eclipse – see Raspberry Pi: gdb debugging in Eclipse.
Create Dart Remote Debug configuration for your Dart application:
Copy your application and open an ssh session to Raspberry Pi :
$ scp -r dartapp/ pi@192.168.0.60:/home/pi $ ssh pi@192.168.0.60
$ cd ~/dartapp $ pub get Resolving dependencies... (1.9s) Got dependencies! $ dart --enable-vm-service:5858/0.0.0.0 --pause_isolates_on_start bin/main.dart Observatory listening on http://0.0.0.0:5858/
Now you can start debugging your application in IntelliJ.
What is mlocate can be found here.
By default it is scheduled to execute daily – that might not meet your expectations what you computer should do when you power it on.
Here is how to reschedule it to execute weekly:
### In the terminal
sudo chmod -x /etc/cron.daily/mlocate
sudo cp /etc/cron.daily/mlocate /etc/cron.weekly/mlocate
sudo chmod +x /etc/cron.weekly/mlocate
This has been checked with Ubuntu 18.04 LTS.
The option for enabling/disabling automatic Android system updates is in Android Setting/Developer options.
If you have not enabled Android Developer options yet – please google how to do that, the Developer options are disabled (not shown in Settings) by default.
Based on the “Learning Functional Programming in Scala” book by Alvin Alexander. Below are all extracts (quotes) from the book. Continue reading “Functional Programming: Terminology”