Skip to content

Instantly share code, notes, and snippets.

@maky-hnou
maky-hnou / install_cuda10.1_ubuntu18.04.sh
Last active April 21, 2023 10:31
A bash script to install CUDA 10.1 on Ubuntu 18.04.
#!/bin/bash
# 1- Download the script: wget https://gist.githubusercontent.com/maky-hnou/bbb936857a67a614e9fba0dbe2c87233/raw/889b2cf637a6c1af8dc886a996276e7878ed4187/install_cuda10.1_ubuntu18.04.sh
# 2- sudo chmod +x install_cuda10.1_ubuntu18.04.sh
# 3- sudo ./install_cuda10.1_ubuntu18.04.sh
# 4- Restart your computer.
if [[ $EUID -ne 0 ]];then echo "Please run as root";exit 1;fi
if [ ! -n "$BASH" ];then echo Please run this script $0 with bash;exit 1;fi