Skip to content

Commit

Permalink
Try using node+rapydscript on appveyor as well
Browse files Browse the repository at this point in the history
  • Loading branch information
kovidgoyal committed Jun 10, 2017
1 parent e1f81c5 commit f863d3b
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 6 deletions.
9 changes: 9 additions & 0 deletions .appveyor.yml
Expand Up @@ -5,6 +5,15 @@ clone_depth: 5

cache:
- .build-cache
- node_modules -> .appveyor.yml

install:
- ps: Install-Product node 7
- node --version
- npm --version
- appveyor-retry npm install --no-optional rapydscript-ng regenerator uglify-js
- set PATH=node_modules\.bin;%PATH%
- rapydscript --version

environment:
SW: C:\sw
Expand Down
3 changes: 2 additions & 1 deletion setup/win-ci.py
Expand Up @@ -184,7 +184,7 @@ def sw():

def sanitize_path():
needed_paths = []
executables = 'git.exe curl.exe'.split()
executables = 'git.exe curl.exe rapydscript.cmd node.exe'.split()
for p in os.environ['PATH'].split(os.pathsep):
for x in tuple(executables):
if os.path.exists(os.path.join(p, x)):
Expand All @@ -195,6 +195,7 @@ def sanitize_path():
sw
).split() + needed_paths
os.environ[b'PATH'] = os.pathsep.join(paths).encode('ascii')
print('PATH:', os.environ[b'PATH'])


def vcenv():
Expand Down
10 changes: 5 additions & 5 deletions src/calibre/utils/filenames.py
Expand Up @@ -93,13 +93,13 @@ def shorten_components_to(length, components, more_to_take=0, last_has_extension
def find_executable_in_path(name, path=None):
if path is None:
path = os.environ.get('PATH', '')
if iswindows and not name.endswith('.exe'):
name += '.exe'
exts = '.exe .cmd .bat'.split() if iswindows and not name.endswith('.exe') else ('',)
path = path.split(os.pathsep)
for x in path:
q = os.path.abspath(os.path.join(x, name))
if os.access(q, os.X_OK):
return q
for ext in exts:
q = os.path.abspath(os.path.join(x, name)) + ext
if os.access(q, os.X_OK):
return q


def is_case_sensitive(path):
Expand Down

0 comments on commit f863d3b

Please sign in to comment.