Closed nathanoehlman closed 8 years ago
@nathanoehlman I'm not opposed to this, though I would rather that we use a non node-specific solution for detecting browsers. While most projects using this are node based, I'm not certain that this will always be the case...
I'm quite open to splitting djo-shell
out into something different and more independent from my identity (definitely didn't expect for webrtc/adapter to end up with an implicit dependency on that), but I think using pure BASH for doing the browser detection was definitely the right call.
The bin/travis-sync
tool is pretty much a convenience rather than a requirement (thanks to feedback from @fippo and @alvestrand) so the only real dependency that this tool has is djo-shell
to operate. Maybe it's worth removing the dependencies altogether from this repo and just moving the browser-version.sh
here to make it more obvious what is happening, and make it possible to use without npm if someone wanted to?
Is there something that has changed beyond what @KaptenJansson addressed in DamonOehlman/djo-shell#4 that is causing problems? Admittedly, I'm not keeping as close an eye on this as I used to...
I do not see why browser-sleuth has to be used either, what are the benefits?
Also, latest and nightly works fine but not beta nor esr.
According to https://archive.mozilla.org/pub/firefox/releases/latest-beta/README.txt the URL should be beta-latest
and esr-latest
rather than latest-beta
and latest-esr
E.g. https://download.mozilla.org/?product=firefox-latest-esr&os=linux64&lang=en-US https://download.mozilla.org/?product=firefox-latest-beta&os=linux64&lang=en-US
Since the new URL's now only provides one version, there is no need to use tail anymore.
OK - to make this all a bit simpler, I'm going to break the browser-version.sh
file into it's own small repo (as per what you did with browser-sleuth
, Nathan). I'm kinda under the pump right now with a few things, but the goal would be to have tests there as well that would ensure things are a-ok. Will provide an update on this soon.
Have done the bare minimum to break it out and have it as a standalone repo / package here:
https://github.com/DamonOehlman/browser-version.sh
@KaptenJansson I've already made you a collaborator so if you'd like to make some improvements to the shell script go for it. I think once it's at a stage of offering something of value in the version in djo-shell
we should move travis-multirunner
across to it :)
Main reason behind browser-sleuth
was to resolve the underlying versions for the Firefox releases now that they're hidden away behind the https://download.mozilla.org/ URL, so you need to follow the redirects to actually determine the version information.
It could have been done with cURL, but I decided to go for a node module because I'm horribly unproductive in bash (coupled with the fact that the existing scripts are biased towards Linux, which makes my life hard here in OSX land with everything being just different enough to cause issues (aka sed -e
vs sed -R
)).
Any of the above suggestions sound good :)
Closed in favour of going with #12 - I will probably still refine the browser-version.sh
script a little, but I like the approach @nathanoehlman has taken. Will bump major version to allow people to opt into the change.
Primarily to get the new Firefox download versions. Also standardises things a little.