saucectl 0.174.0 → 0.175.1

Sign up to get free protection for your applications and to get access to all the features.
package/README.md CHANGED
@@ -5,18 +5,12 @@ Node.js wrapper for [saucectl](https://github.com/saucelabs/saucectl).
5
5
 
6
6
  ## Install
7
7
 
8
- To install `saucectl` using NPM just run:
8
+ To install `saucectl` via `npm`, simply run the following command:
9
9
 
10
10
  ```sh
11
11
  $ npm i -g saucectl
12
12
  ```
13
13
 
14
- In case you need to download `saucectl` from a known source or in case you use `npx saucectl` you can use environment variable:
15
-
16
- ```
17
- export SAUCECTL_INSTALL_BINARY=http://localhost:9000/saucectl_0.32.2_mac_64-bit.tar.gz
18
- ```
19
-
20
14
  The command should be globally available:
21
15
 
22
16
  ```sh
@@ -25,11 +19,21 @@ saucectl version 0.4.0
25
19
  (build 7468a24c788b4ca4d67d50372c839edf03e5df6a)
26
20
  ```
27
21
 
28
- __Note:__ if you run the command for the first time it will initially download the binary for you. This only happens once.
22
+ __Note:__ When you run the command for the first time, it will initially download the binary. This only happens once.
23
+
24
+ __Note:__ `saucectl` installation is disabled on Sauce Labs Cloud. If you wish to force the installation, set the `SAUCECTL_FORCE_INSTALL` environment variable to `true`.
25
+
26
+ ### Install Binary from a Specified Source
27
+
28
+ If you want the installer to download `saucectl` from a specific source, set the following environment variable:
29
+
30
+ ```
31
+ export SAUCECTL_INSTALL_BINARY=http://localhost:9000/saucectl_0.32.2_mac_64-bit.tar.gz
32
+ ```
29
33
 
30
- ### Install binary from Mirror
34
+ ### Install Binary from a Mirror Site
31
35
 
32
- Use the `SAUCECTL_INSTALL_BINARY_MIRROR` env to override the default download base site (https://github.com/saucelabs/saucectl/releases/download)
36
+ Override the default download site by setting the `SAUCECTL_INSTALL_BINARY_MIRROR` environment variable to a custom URL. The default site is [Sauce Labs saucectl releases](https://github.com/saucelabs/saucectl/releases/download).
33
37
 
34
38
  ```bash
35
39
  SAUCECTL_INSTALL_BINARY_MIRROR=https://your-mirror-download-site.com/foo/bar npm i -g saucectl
@@ -37,4 +41,4 @@ SAUCECTL_INSTALL_BINARY_MIRROR=https://your-mirror-download-site.com/foo/bar npm
37
41
 
38
42
  ---
39
43
 
40
- For more information to `saucectl`, visit its main repository: [saucelabs/saucectl](https://github.com/saucelabs/saucectl).
44
+ For more information about `saucectl`, visit its main repository: [saucelabs/saucectl](https://github.com/saucelabs/saucectl).
package/index.js CHANGED
@@ -4,7 +4,7 @@ const path = require('path');
4
4
  const { BinWrapper } = require('@saucelabs/bin-wrapper');
5
5
  const { Writable } = require('stream');
6
6
 
7
- const version = '0.174.0';
7
+ const version = '0.175.1';
8
8
  const defaultBinInstallBase =
9
9
  'https://github.com/saucelabs/saucectl/releases/download';
10
10
  const binWrapper = (binInstallURL = null, binInstallBase = null) => {
package/install.js CHANGED
@@ -17,6 +17,12 @@ function sanitizeURL(inputURL) {
17
17
  // So we are 100% sure that the saucectl binary will be available for the next
18
18
  // execution.
19
19
  async function install() {
20
+ if (process.env.SAUCE_VM) {
21
+ if (!process.env.SAUCECTL_FORCE_INSTALL) {
22
+ console.info('Skipping the installation of saucectl on Sauce Cloud.');
23
+ return;
24
+ }
25
+ }
20
26
  console.info('Fetching saucectl binary');
21
27
  const bw = binWrapper(
22
28
  process.env.SAUCECTL_INSTALL_BINARY,
@@ -27,7 +33,7 @@ async function install() {
27
33
  }
28
34
  bw.run(['--version'])
29
35
  .then(() => {
30
- console.info(`Installation succeed`);
36
+ console.info('Installation succeeded');
31
37
  process.exit(0);
32
38
  })
33
39
  .catch((e) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "saucectl",
3
- "version": "0.174.0",
3
+ "version": "0.175.1",
4
4
  "description": "Node.js wrapper for saucectl",
5
5
  "main": "index.js",
6
6
  "bin": "index.js",