File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -115,9 +115,18 @@ svn cp "trunk" "tags/$VERSION"
115115
116116# Fix screenshots getting force downloaded when clicking them
117117# https://developer.wordpress.org/plugins/wordpress-org/plugin-assets/
118- svn propset svn:mime-type image/png assets/* .png || true
119- svn propset svn:mime-type image/jpeg assets/* .jpg || true
120- svn propset svn:mime-type image/gif assets/* .gif || true
118+ if test -d " $SVN_DIR /assets" && test -n " $( find " $SVN_DIR /assets" -maxdepth 1 -name " *.png" -print -quit) " ; then
119+ svn propset svn:mime-type " image/png" " $SVN_DIR /assets/*.png" || true
120+ fi
121+ if test -d " $SVN_DIR /assets" && test -n " $( find " $SVN_DIR /assets" -maxdepth 1 -name " *.jpg" -print -quit) " ; then
122+ svn propset svn:mime-type " image/jpeg" " $SVN_DIR /assets/*.jpg" || true
123+ fi
124+ if test -d " $SVN_DIR /assets" && test -n " $( find " $SVN_DIR /assets" -maxdepth 1 -name " *.gif" -print -quit) " ; then
125+ svn propset svn:mime-type " image/gif" " $SVN_DIR /assets/*.gif" || true
126+ fi
127+ if test -d " $SVN_DIR /assets" && test -n " $( find " $SVN_DIR /assets" -maxdepth 1 -name " *.svg" -print -quit) " ; then
128+ svn propset svn:mime-type " image/svg+xml" " $SVN_DIR /assets/*.svg" || true
129+ fi
121130
122131svn status
123132
You can’t perform that action at this time.
0 commit comments