1+ name : GameTracking
2+
13on :
24 workflow_call :
35 inputs :
@@ -31,23 +33,25 @@ jobs:
3133 contents : write
3234 steps :
3335
34- - name : Checkout GameTracking
36+ # Checkout and cache
37+
38+ - name : Checkout shared GameTracking
3539 id : checkout-gametracking
3640 uses : actions/checkout@v6
3741 with :
3842 fetch-depth : 1
3943 repository : ' SteamTracking/GameTracking'
4044
41- - name : Grab cache
45+ - name : Restore tools cache
4246 id : cache
4347 uses : actions/cache@v5
4448 with :
4549 path : |
4650 ${{ github.workspace }}/tools/*
4751 !${{ github.workspace }}/tools/build.sh
4852 key : ${{ runner.os }}-tools-${{ steps.checkout-gametracking.outputs.commit }}
49-
50- - name : Checkout ${{ github.repository }}
53+
54+ - name : Checkout game repository ( ${{ github.repository }})
5155 uses : actions/checkout@v6
5256 with :
5357 fetch-depth : 1
7074 shell : bash
7175 run : ./tools/build.sh
7276
73- - name : Does package-lock.json exist
77+ # Optional Node.js setup
78+
79+ - name : Check for package-lock.json
7480 id : package-lock-json-exists
7581 shell : bash
7682 run : echo "exists=$(test -f ${{ github.workspace }}/${{ inputs.folder }}/package-lock.json && echo true || echo false)" >> $GITHUB_OUTPUT
@@ -83,29 +89,33 @@ jobs:
8389 cache : ' npm'
8490 cache-dependency-path : ${{ github.workspace }}/${{ inputs.folder }}/package-lock.json
8591
86- - name : Install Node dependencies
92+ - name : Install Node.js dependencies
8793 if : steps.package-lock-json-exists.outputs.exists == 'true'
8894 working-directory : ${{ github.workspace }}/${{ inputs.folder }}
8995 run : npm ci
9096
97+ # Download and process
98+
9199 - name : Configure git user
92100 run : |
93101 git config --global user.name "github-actions[bot]"
94102 git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
95103
96- - name : Download App ${{ inputs.appid }}
104+ - name : Download app ${{ inputs.appid }}
97105 working-directory : ${{ github.workspace }}/${{ inputs.folder }}
98106 shell : bash
99107 run : |
100108 . ../common.sh
101109 $STEAM_FILE_DOWNLOADER_PATH --username "${{ secrets.STEAM_USERNAME }}" --password "${{ secrets.STEAM_PASSWORD }}" --appid "${{ inputs.appid }}" --output . --branch "${{ inputs.branch }}" ${{ inputs.save-manifest && '--save-manifest' || '' }}
102110
103- - name : Execute
111+ - name : Run update script
104112 working-directory : ${{ github.workspace }}/${{ inputs.folder }}
105113 shell : bash
106114 run : ./update.sh
107-
108- - name : Dispatch to ValveProtobufs
115+
116+ # Post-processing
117+
118+ - name : Dispatch sync to ValveProtobufs
109119 run : gh api repos/SteamTracking/Protobufs/dispatches -f event_type=sync
110120 env :
111- GH_TOKEN : ${{ secrets.DISPATCH_TOKEN }}
121+ GH_TOKEN : ${{ secrets.DISPATCH_TOKEN }}
0 commit comments