Commit 2a4efb84 authored by Darko Poljak's avatar Darko Poljak

Merge branch 'build/support-pip-from-git' into 'master'

Build/support pip from git

See merge request ungleich-public/cdist!808
parents 50a3130b 2d0af7b7
from distutils.core import setup
import cdist
from distutils.errors import DistutilsError
import os
import re
import subprocess
# We have it only if it is a git cloned repo.
build_helper = os.path.join('bin', 'build-helper')
# Version file path.
version_file = os.path.join('cdist', '')
# If we have build-helper we could be a git repo.
if os.path.exists(build_helper):
# Try to generate
rv =[build_helper, 'version', ])
if rv.returncode != 0:
raise DistutilsError("Failed to generate {}".format(version_file))
# Otherwise, should be present.
if not os.path.exists(version_file):
raise DistutilsError("Missing version file {}".format(version_file))
import cdist
def data_finder(data_dir):
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment