Skip to content

Commit

Permalink
Revert "pkg-resolver script working dir agnostic"
Browse files Browse the repository at this point in the history
This reverts commit f81dcf7.
  • Loading branch information
pan3793 committed Nov 23, 2024
1 parent 04a39e1 commit 6f4d4c9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
5 changes: 1 addition & 4 deletions dev-support/docker/pkg-resolver/check_platform.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,15 @@
"""

import json
import os
import sys


current_directory = os.path.dirname(os.path.abspath(__file__))

def get_platforms():
"""
:return: A list of the supported platforms managed by pkg-resolver.
"""

with open('%s/platforms.json' % current_directory, encoding='utf-8', mode='r') as platforms_file:
with open('pkg-resolver/platforms.json', encoding='utf-8', mode='r') as platforms_file:
return json.loads(platforms_file.read())


Expand Down
5 changes: 1 addition & 4 deletions dev-support/docker/pkg-resolver/resolve.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,10 @@

import argparse
import json
import os
import sys
from check_platform import is_supported_platform


current_directory = os.path.dirname(os.path.abspath(__file__))

def get_packages(platform, release=None):
"""
Resolve and get the list of packages to install for the given platform.
Expand All @@ -38,7 +35,7 @@ def get_packages(platform, release=None):
specified release.
:return: A list of resolved packages to install.
"""
with open('%s/packages.json' % current_directory, encoding='utf-8', mode='r') as pkg_file:
with open('pkg-resolver/packages.json', encoding='utf-8', mode='r') as pkg_file:
pkgs = json.loads(pkg_file.read())
packages = []

Expand Down

0 comments on commit 6f4d4c9

Please sign in to comment.