forked from ptoribi/lightning
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathuninstall
More file actions
executable file
·31 lines (26 loc) · 2.14 KB
/
uninstall
File metadata and controls
executable file
·31 lines (26 loc) · 2.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/bash
###############################################################################################
## ##
## Universidad Carlos III de Madrid (UC3M) ##
## ##
## Lightning - The simple and lightweight network simulator based on Docker containers ##
## ##
## author: Pablo Toribio (under supervision of professor C.J. Bernardos Cano) ##
## ##
## project site: https://github.com/ptoribi/lightning ##
## ##
## file description: uninstaller of the program ##
## --- WARNING!!! --- ##
## This will delete all the files of the program!, including the ##
## personalized_functions file and the scenarios-local folder! ##
## ##
## usage: sudo ./uninstall ##
## ##
###############################################################################################
# LIGHTNING_INSTALLATION_PATH -> The default value is usually /usr/local/lightning
LIGHTNING_INSTALLATION_PATH=$(dirname $(readlink -f $(which lightning)))
# SYMLINK_INSTALLATION_PATH -> The default value is usually /usr/local/bin/lightning
SYMLINK_INSTALLATION_PATH=$(which lightning)
rm -rf $LIGHTNING_INSTALLATION_PATH
rm -f $SYMLINK_INSTALLATION_PATH
echo $(tput setaf 0)$(tput setab 2) "Lightning was properly uninstalled" $(tput sgr 0)