Closed qrkourier closed 1 year ago
you know. i don't think there is any good reason to keep it. i would rather shorten it by slapping it up onto the new docusaurus site. Funny enough, I had planned to do that but didn't put an issue in. Then it could be just something like:
source /dev/stdin <<< "$(wget -qO- https://openziti.github.io/ziti-cli-functions.sh)"; expressInstall
or maybe using openziti.io (eventually):
source /dev/stdin <<< "$(wget -qO- https://get.openziti.io/ziti-cli-functions.sh)"; expressInstall
or something like that?
I do think there's some value in simply shortening the URL. It's less visual noise which is easy to appreciate so early in the developer experience. I'd like to suggest a more minimal and BASHful syntax, though, unless there's some particular problem we're solving with the source /dev/stdin
approach:
source <(curl -s https://openziti.github.io/ziti-cli-functions.sh)
i used wget originally because it was 'more available' than curl. I don't remember what OS didn't have curl installed. i just found this very fresh reddit thread that covers this topic too that seems to say ubuntu doesn't come with curl out of the gate...
https://www.reddit.com/r/linux/comments/wll8yq/which_is_more_common_out_of_the_box_curl_or_wget/
I don't care - I just want to make it as easy as possible... :)
That's a good enough reason to use wget
.
source <(wget -qO- https://openziti.github.io/ziti-cli-functions.sh)
I looked through this repo for references to /quickstart/docker/image/ziti-cli-functions.sh
and found quite a few. The way it's used by the Docker quickstarts leads me to think it needs to continue living inside the Docker context, and that the best way to make the functions script available with a shorter URL is improving the docs build to download the latest from the release branch "main".
i specifically didn't use main because it requires a release and that very much slows adoption/fix rate. if we move it to 'the doc site' - that will something to consider
stale and no longer applicable
/quickstart/ziti-cli-functions.sh
is a symbolic link:I'm wondering if anything uses that symlink because I noticed that GitHub's "raw" downloads don't work for symlinks, and so it seems to make sense to move the script up to the top level and update the quickstarts to use the shared location instead of the Docker location.
Currently, the local-no-docker and hosted-anywhere quickstarts link to https://raw.githubusercontent.com/openziti/ziti/release-next/quickstart/docker/image/ziti-cli-functions.sh, and so we may be able to shorten this to https://raw.githubusercontent.com/openziti/ziti/main/quickstart/ziti-cli-functions.sh if there's no reason for the symlink to exist.