Skip to content

Instantly share code, notes, and snippets.

View codedeep79's full-sized avatar

Nguyễn Trung Hậu codedeep79

View GitHub Profile
@codedeep79
codedeep79 / Ubuntu, Windows dual boot : How to solve "read-only" issue when trying to write on a NTFS mounted volume.md
Last active October 3, 2022 02:48
Ubuntu / Windows dual boot : How to solve "read-only" issue when trying to write on a NTFS mounted volume?

Open the terminal and write the command

sudo fdisk -l

It will show your file system, identify the partition you want permission for read and write. Then type the command and give the partition name like this to your specific sda

sudo ntfsfix /dev/sda3
@codedeep79
codedeep79 / Install Golang on Debian.md
Created October 3, 2022 01:52
Install Golang on Debian

Install Golang

sudo apt install golang-go

Uninstall Golang

sudo apt-get remove golang-go
sudo apt-get remove --auto-remove golang-go
@codedeep79
codedeep79 / Gitlab error: unable to rewind rpc post data - try increasing http.postBuffer.md
Created September 28, 2022 05:24
Gitlab error: unable to rewind rpc post data - try increasing http.postBuffer

Error:

error: unable to rewind rpc post data - try increasing http.postBuffer
error: RPC failed; curl 56 GnuTLS recv error (-54): Error in the pull function.
fatal: the remote end hung up unexpectedlyiB | 299.00 KiB/s  

Solution

Try modify the postBuffer size of git:

git config --global http.postBuffer 2097152000
@codedeep79
codedeep79 / Install OpenJDK 8 on Debian 10.md
Last active September 28, 2022 01:00
Install OpenJDK 8 on Debian 10

Install software source manager

sudo apt-get update
sudo apt-get install software-properties-common

Add mirror with Openjdk 8

sudo apt-add-repository 'deb http://security.debian.org/debian-security stretch/updates main'
sudo apt-get update
@codedeep79
codedeep79 / Simulating Wang algorithm in Prolog.md
Last active September 4, 2022 01:03
Simulating Wang algorithm in Prolog

Rules of inference in Wang algorithm

Rule 1: Transform hypotheses and conclusions in the negative form

Example:

p v q, !(r ^ s), !q, p v r -> s, !p <=> p v q, p v r, p -> s, r ^ s, q

Rule 2: Replace the ^ sign with the comma of the hypothesis

Example:

p ^ q, r ^ (!p v s) -> !q v !r <=> p, q, r, !p v s -> !q v !r
@codedeep79
codedeep79 / Install VLC on Debian 11 Bullseye Linux.md
Last active September 4, 2022 00:32
Install VLC on Debian 11 Bullseye Linux

Run System update

sudo apt update

Install VLC on Debian 11 Bullseye

sudo apt install vlc -y

Uninstall VLC using APT

@codedeep79
codedeep79 / Possible missing firmware update in debian.md
Last active September 2, 2022 04:06
Possible missing firmware update in debian 10, 11

I am having the following error after running apt update and apt upgrade on my server.

Processing triggers for initramfs-tools (0.133+deb10u1) ...
update-initramfs: Generating /boot/initrd.img-4.19.0-21-amd64
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8107e-2.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8107e-1.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168h-2.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168h-1.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168g-3.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168g-2.fw for module r8169
@codedeep79
codedeep79 / Install Foxit Reader on Debian.md
Created September 2, 2022 03:53
Install Foxit Reader on Debian
  • Download Software at this
  • Once the download is complete, you should be able to find the Foxit Reader archive you just downloaded in the ~/Downloads directory in your login users HOME directory.
  • Now, you have to extract the Foxit Reader archive. To do that, Right click (RMB) on the file and click on Extract Here as marked in the screenshot below.
  • The Foxit Reader archive should be extracted into a new directory as you can see in the screenshot below. Double click on the newly created directory.
  • You should see an executable setup file inside the directory as you can see in the screenshot below. Double click on the setup file.
  • Foxit Reader installer should start as you can see in the screenshot below. The default installation location of Foxit Reader is **/home//opt/foxitsoft
@codedeep79
codedeep79 / Create Android Studio Linux Desktop Shortcut and Command-Line launcher.md
Last active September 1, 2022 08:58
Create Android Studio Linux Desktop Shortcut and Command-Line launcher

Run the ./studio.sh script which is available inside the folder android-studio/bin. The location of this folder depends on where you have extracted it. Create a new Project or open some existing one. Here we are creating a new… For a Desktop shortcut and a launcher from Applications, select the “Create Desktop Entry…” option.

@codedeep79
codedeep79 / Bị lỗi khi cài libgtk-3-dev.md
Last active September 1, 2022 07:57
Bị lỗi ''unmet dependencies: libgtk-3-dev : Depends: libatk-bridge2.0-dev but it is not going to be installed ......" khi cài libgtk-3-dev

Khi cài libgtk-3-dev thì bị lỗi:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation: