Skip to content

Commit

Permalink
chore: testing ci check
Browse files Browse the repository at this point in the history
  • Loading branch information
salman2013 committed Apr 3, 2024
1 parent 0e71e82 commit 2fdfb23
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/check_dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,16 @@ jobs:
with:
python-version: '3.8'

- name: Create repo_work directory
run: mkdir -p WORK_DIR/repo_work
- name: Create repo_work directory
run: |
WORK_DIR="/tmp/unpack_reqs"
mkdir -p "$WORK_DIR"/repo_work
- name: Copy Python requirements file
run: |
for req_file in "requirements/edx/base.txt" "requirements/base.txt" "requirements.txt"; do
if [ -f "$req_file" ]; then
cp "$req_file" WORK_DIR/repo_work/base.txt
cp "$req_file" "$WORK_DIR"/repo_work/base.txt
echo "Python requirements file found: $req_file"
echo "Content of base.txt:"
cat "$req_file"
Expand All @@ -37,22 +39,23 @@ jobs:
- name: Create virtual environment
run: python3 -m venv .venv
working-directory: WORK_DIR/repo_work
working-directory: $WORK_DIR/repo_work

- name: Upgrade pip
run: |
.venv/bin/python3 -m pip install -U pip
working-directory: WORK_DIR/repo_work
working-directory: $WORK_DIR/repo_work

- name: Download packages
run: |
echo "Downloading packages"
.venv/bin/python3 -m pip download --dest files -r base.txt
base_txt_path="${GITHUB_WORKSPACE}/files/base.txt"
echo "Path of base.txt: ${base_txt_path}"
working-directory: WORK_DIR/repo_work
working-directory: $WORK_DIR/repo_work

- name: Extract GitHub URLs from base.txt
id: extract
run: |
urls=()
base_txt_path="./files/base.txt"
Expand All @@ -61,9 +64,9 @@ jobs:
urls+=("${BASH_REMATCH[0]}")
fi
done < "${base_txt_path}"
echo "::set-output name=github_urls::${urls[*]}"
echo "::set-output name=urls::${urls[*]}"
- name: Display GitHub URLs
run: |
echo "GitHub URLs:"
echo "${{ steps.extract.urls }}"
echo "${{ steps.extract.outputs.urls }}"

0 comments on commit 2fdfb23

Please sign in to comment.