Skip to content

Commit 5411282

Browse files
committed
Simplify to standard LFS checkout now that submodule URL is correct
1 parent 6a258a6 commit 5411282

File tree

1 file changed

+1
-29
lines changed

1 file changed

+1
-29
lines changed

.github/workflows/docs-build.yml

Lines changed: 1 addition & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -70,35 +70,7 @@ jobs:
7070
token: ${{ secrets.GITHUB_TOKEN }}
7171
# only Pytorch has/uses notebooks
7272
submodules: ${{ matrix.pkg-name == 'pytorch' }}
73-
lfs: false # Disable LFS during checkout to avoid auth issues
74-
- name: Configure Git LFS authentication
75-
if: ${{ matrix.pkg-name == 'pytorch' }}
76-
env:
77-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
78-
run: |
79-
# Configure Git LFS with proper authentication using recommended approach
80-
git config --global credential.helper store
81-
echo "https://${{ github.actor }}:${GH_TOKEN}@github.com" > ~/.git-credentials
82-
83-
# Set LFS configuration to use GitHub token
84-
git config --global lfs."https://github.com/".access basic
85-
git config --global lfs."https://github.com/".locksverify false
86-
87-
- name: Fetch LFS objects for submodule
88-
if: ${{ matrix.pkg-name == 'pytorch' }}
89-
working-directory: _notebooks
90-
env:
91-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
92-
run: |
93-
# Initialize LFS in submodule context
94-
git lfs install --local
95-
96-
# Set the correct LFS endpoint with authentication (using the actual repo name)
97-
git config lfs.url "https://${{ github.actor }}:${GH_TOKEN}@github.com/Lightning-AI/tutorials.git/info/lfs"
98-
99-
# Fetch and checkout LFS objects
100-
git lfs fetch --all
101-
git lfs checkout
73+
lfs: ${{ matrix.pkg-name == 'pytorch' }}
10274
- uses: actions/setup-python@v6
10375
with:
10476
python-version: "3.10"

0 commit comments

Comments
 (0)