Grab Ruby documentation path before switching Git branches
@@ -11,6 +11,7 @@ py)
;;
rb)
bazel run //rb:docs || exit
+ docs="$(bazel cquery --output=files //rb:docs 2> /dev/null).runfiles/selenium/docs/api/rb"
;;
*)
echo "Selenium API docs generation"
@@ -41,7 +42,7 @@ py)
;;
rb)
rm -rf docs/api/rb
- mv "$(bazel cquery --output=files //rb:docs 2> /dev/null).runfiles/selenium/docs/api/rb" docs/api/rb
+ mv $docs docs/api/rb
;;
*)
echo "ERROR: unknown parameter \"$API_DOCS_LANGUAGE\""
