Run:
sudo umount /dec/sdc3
sudo ntfslabel --new-serial=6F8ECB2C59114F1A /dev/sdc3 # where /dev/sdc3 is ntfs partition
# Install requirements | |
sudo apt update && sudo apt install -y build-essential gcc make perl dkms | |
# Install VirtualBox | |
mkdir ~/tempInstallationDir/ | |
wget https://download.virtualbox.org/virtualbox/6.1.42/virtualbox-6.1_6.1.42-155177~Debian~bullseye_amd64.deb -O ~/tempInstallationDir/virtualbox-6.1_6.1.42-155177~Debian~bullseye_amd64.deb | |
sudo dpkg -i ~/tempInstallationDir/virtualbox-6.1_6.1.42-155177~Debian~bullseye_amd64.deb | |
sudo apt install -f -y | |
sudo /sbin/vboxconfig | |
rm -rf ~/tempInstallationDir/ |
#!/bin/bash | |
# | |
# Bash script using xargs to run Matlab and Octave jobs in parallel. | |
# | |
n_parruns=16 # Total number of runs. | |
n_parproc=3 # Number of simultaneous parallel processes. | |
# Define Matlab/Octave executable and main m-scipt file to run. | |
export runcmd='/mnt/c/Octave/Octave-4.2.1/bin/octave-cli.exe' |
System Settings -> Application Style -> GNOME Application Style (GTK) -> GTK Themes -> Select a GTK3 Theme (set it to Breeze-Dark for example)
additionally there may be a need to adjust Icon Themes in order to make them visible with dark theme:
System Settings -> Application Style -> GNOME Application Style (GTK) -> GTK Themes -> Icon Themes (set it to the one you like)
Run:
conda config --set auto_activate_base false
The first time you run it, it'll create a ./condarc in your home directory with that setting to override the default. This wouldn't de-clutter your .bash_profile but it's a cleaner solution without manual editing that section that conda manages.
source: https://coderwall.com/p/7smjkq/multiple-ssh-keys-for-different-accounts-on-github-or-gitlab
Sometimes you need more accounts than one for access to Github or Gitlab and similar tools. For example you can have one account for your projects at home and second account for your company.
Case 1: Multiple accounts on Github Create SSH keys with different names
$ ssh-keygen -t rsa -C "your_name@home_email.com"
When you see this message
This is useful for trying to recover from an unresponsive system. However, by default, Ubuntu disables the key to gain raw keyboard access.\
Sometimes part of the issue is that X/Wayland display servers have crashed due to bad graphics drivers and keyboard input isn't processed anymore, whereby changing to another console, e.g. ctrl + alt + F1
doesn't work. Since the default disables keyboard control, alt + sysrq + r
, can't help salvage the situation. Hence the suggestion to at least enable system request raw keyboard control when trying to recover a system.
Ubuntu 16.04 LTS default value:
Alt + PrtSc + O == Shutdown the system immediately
Alt + PrtSc + B == Reboot the system immediately
Under graphical environments like Unity, Alt + SysRq takes a screenshot. You must hold down ctrl as well.
https://askubuntu.com/questions/53263/shut-down-computer-from-keyboard
Sometimes you need to slice a column from a numpy array and preserve its column shape, i.e. you want your vector to be an array of (m x 1) size. Numpy does not enable any straighforward way of doing it (slicing a vector from a matrix always gives a row vector, regardless you slice a row or a column). Here's a code that presents a bypass of this problem:
import numpy as np
def column(A,j):
Sometimes you need to keep two upstreams in sync with eachother. For example, you might need to both push to your testing environment and your GitHub repo at the same time. In order to do this simultaneously in one git command, here's a little trick to add multiple push URLs to a single remote.
Once you have a remote set up for one of your upstreams, run these commands with:
git remote set-url --add --push [remote] [original repo URL]
git remote set-url --add --push [remote] [second repo URL]