Hi guys. I had a really basic question. I see a lo...
# general
i
Hi guys. I had a really basic question. I see a lot in the Pants documentation for how to run tests and lint in CI, but I don't see too much when it comes to actually deploying built assets. Is there any recommend way of doing this? Is there an easy way of doing this in a way that only detect changed assets?
👆 1
c
Not sure if this is recommended but here’s what we use to check what needs to get built and deployed.
Copy code
(./pants --changed-since=${CHANGEDSINCE} filedeps | sort) > filechanges
(./pants filedeps --transitive src/${APP}:${APP} | sort) > filedeps
FILE_CHANGE_COUNT=$(comm -12 filechanges filedeps | wc -l)
if [ ${FILE_CHANGE_COUNT} -gt 0 ]
then
    echo "Changes detected for ${APP} kicking off the build"
    ./build/scripts/build_publish_deploy.sh ${APP}
else
    echo "No changes for ${APP}"
fi
i
Thanks @clean-city-64472 I assumed this was the approach people were taking.
c
@clean-city-64472 I found what I want, too! Thanks!