Recommend extensions:
-
markdownlint: For markdown linting and style checking.
-
Markdown Preview Github Styling: Markdown preview in Github’s style.
Open the preview side-by-side with shortcut Ctrk+K V.
Recommend extensions:
markdownlint: For markdown linting and style checking.
Markdown Preview Github Styling: Markdown preview in Github’s style.
Open the preview side-by-side with shortcut Ctrk+K V.
This post is obsolete. Please check the new manual at this post
If you don’t care to battery and want to use NVIDIA card fulltime, check this post.
Add RPMFusion repositories
$ sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
For http and https protocol:
$ git config --global http.proxy $http_proxy
$ git config --global https.proxy $http_proxy
For git protocol
socat
./usr/bin/gitproxy
with content:
#!/bin/sh
proxy_host=<your_proxy_host>
proxy_port=<your_proxy_port>
proxy_user=<your_proxy_username>
proxy_pass=<your_proxy_password>
exec socat STDIO PROXY:$proxy_host:$1:$2,proxyport=$proxy_port,proxyauth=$proxy_user:$proxy_pass
sudo chmod +x /usr/bin/gitproxy
git config --global core.gitproxy gitproxy
git config --global http.sslverify false
Download kernel-qemu-4.14.79-stretch
and versatile-pb.dtb
at dhruvvyas90/qemu-rpi-kernel
.
Download Raspbian Stretch at the official site. I use ’lite’ version, but other version should be fine.
Create a Debian chroot
$ sudo debootstrap <code name> <chroot folder> <apt repo URL>
# Example
$ sudo debootstrap buster ./chroot-buster http://deb.debian.org/debian
Boot to live USB
Mount the partition we want to restore grub (assume /dev/sda1)
sudo mount /dev/sda1 /mnt
# If /boot folder in another partition (assume /dev/sda2)
# you need to mount it too
# sudo mount /dev/sda2 /mnt/boot
This post is obsolete. Please check the new manual at this post
Add negativo17’s repo
$ sudo dnf config-manager --add-repo=https://negativo17.org/repos/fedora-nvidia.repo
Install NVIDIA driver
$ sudo dnf install nvidia-driver nvidia-driver-libs.i686
Create a script file night_mode
#!/bin/sh
night_mode() {
xrandr --output VGA-1 --gamma $1 --brightness $2
}
case $1 in
off) night_mode 1:1:1 1.0 ;;
*) night_mode 1:0.85:0.6 1.0 ;;
esac
Assume we have 2 partitions: /dev/fedora/root
and /dev/fedora/home
, want to reduce the size of root and give it for home.
Boot to live boot USB.
Ensure that partitions are not mounted.
[Read More]Create a systemd drop-in directory for the docker service
$ sudo mkdir -p /etc/systemd/system/docker.service.d
Add proxy configuration into /etc/systemd/system/docker.service.d/http-proxy.conf
(create if not exist)
[Service]
Environment="HTTP_PROXY=<your_proxy>"
Environment="HTTPS_PROXY=<your_proxy>/"
Environment="NO_PROXY=localhost,127.0.0.1"
Flush change and restart service
$ sudo systemctl daemon-reload
$ sudo systemctl restart docker