CFG_DIR="$(brew --prefix)/etc/buildkite-agent"
version="$(sw_vers -productVersion | sed -E 's/([0-9]+).([0-9]+).[0-9]+/\1.\2/')"
+arch="$(uname -m)"
# Setup the tags of the agent
-echo "tags=\"queue=libcxx-builders-macos,queue=libcxx-builders-macos${version}\"" >> "${CFG_DIR}/buildkite-agent.cfg"
+echo "tags=\"queue=libcxx-builders,arch=${arch},os=macos${version}\"" >> "${CFG_DIR}/buildkite-agent.cfg"
# Setup the BuildKite Agent token
sed -i '' "s/xxx/${BUILDKITE_AGENT_TOKEN}/g" "${CFG_DIR}/buildkite-agent.cfg"