mirror of https://github.com/cheat/cheat.git
forgot to use absolute paths in the install script; fixed now
This commit is contained in:
parent
67cb9c10d4
commit
824e3dd99c
7
install
7
install
|
@ -6,12 +6,13 @@ import shutil
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
home = os.path.expanduser('~')
|
home = os.path.expanduser('~')
|
||||||
bindir = os.path.join(home, '/bin/')
|
thisdir = os.path.dirname(os.path.abspath(__file__))
|
||||||
|
bindir = os.path.join(home, 'bin')
|
||||||
try:
|
try:
|
||||||
if not os.path.isdir(bindir):
|
if not os.path.isdir(bindir):
|
||||||
os.path.mkdir(bindir)
|
os.path.mkdir(bindir)
|
||||||
os.symlink('./cheat', bindir)
|
os.symlink(os.path.join(thisdir, './cheat'), os.path.join(bindir, 'cheat'))
|
||||||
os.symlink('./.cheat', os.path.join(home, '/.cheat'))
|
os.symlink(os.path.join(thisdir, './.cheat'), os.path.join(home, '.cheat'))
|
||||||
print("cheat has been installed successfully.")
|
print("cheat has been installed successfully.")
|
||||||
except IOError as e:
|
except IOError as e:
|
||||||
sys.stderr.write("Something went wrong: %s\n" % e)
|
sys.stderr.write("Something went wrong: %s\n" % e)
|
||||||
|
|
Loading…
Reference in New Issue