Skip to content
This repository has been archived by the owner on Jun 5, 2020. It is now read-only.

Commit

Permalink
Add dist dir to default path
Browse files Browse the repository at this point in the history
  • Loading branch information
vmolsa committed May 9, 2017
1 parent 03cbc85 commit 7c8a519
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions install
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import subprocess
import urllib

root_path = os.getcwd()
root_dir = os.path.dirname(os.path.realpath(__file__))
base_url = 'https://github.com/vmolsa/libcrtc/releases/download'

target_platform = sys.platform
Expand All @@ -26,14 +27,21 @@ elif (target_cpu == 'i386'):
argc = len(sys.argv)
argv = str(sys.argv)

release_name = ''.join(subprocess.check_output(['git', 'describe', '--abbrev=0', '--tags']).split())
release_name = 'master'

os.chdir(root_dir)

try:
release_name = ''.join(subprocess.check_output(['git', 'describe', '--abbrev=0', '--tags']).split())
except ValueError:
release_name = 'master'

if (argc == 3):
release_name = str(sys.argv[2])
print 'Tag: ' + release_name

pkg_name = 'libcrtc-' + release_name + '-' + target_os + '-' + target_cpu + '.tar.gz'
target_path = root_path
target_path = os.path.join(root_dir, 'dist')

if (argc >= 2):
target_path = str(sys.argv[1])
Expand Down

0 comments on commit 7c8a519

Please sign in to comment.