File tree Expand file tree Collapse file tree 1 file changed +0
-21
lines changed Expand file tree Collapse file tree 1 file changed +0
-21
lines changed Original file line number Diff line number Diff line change @@ -103,27 +103,6 @@ jobs:
103103 AWS_REGION : ' us-west-1' # optional: defaults to us-east-1
104104 SOURCE_DIR : ' docs/_build/html' # optional: defaults to entire repository
105105
106- - name : Generate list of changed files for CloudFront to invalidate
107- if : env.PUBLISH == 'true'
108- run : |
109- FILES=$(find docs/_build/html -exec realpath --relative-to docs/_build/html {} \; | awk '{print "/"$0}' | grep "html\|searchindex.js\|custom.css\|.svg");
110-
111- for file in $FILES; do
112- echo $file
113- # add bare directory to list of updated paths when we see index.html
114- [[ "$file" == *"/index.html" ]] && echo $file | sed -e 's/\/index.html$/\//'
115- done | sort | uniq | tr '\n' ' ' > .updated_files
116-
117- - name : Invalidate on CloudFront
118- uses : chetan/invalidate-cloudfront-action@v2.3
119- if : env.PUBLISH == 'true'
120- env :
121- DISTRIBUTION : ${{ secrets.AWS_CLOUDFRONT_DISTRIBUTION }}
122- AWS_REGION : ' us-east-1'
123- AWS_ACCESS_KEY_ID : ${{ secrets.AWS_ACCESS_KEY_ID }}
124- AWS_SECRET_ACCESS_KEY : ${{ secrets.AWS_SECRET_ACCESS_KEY }}
125- PATHS_FROM : .updated_files
126-
127106 - name : Purge cache on Cloudflare
128107 uses : jakejarvis/cloudflare-purge-action@v0.3.0
129108 env :
You can’t perform that action at this time.
0 commit comments