gitshift 1.0.3 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gitshift",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "GitHub Account Switcher CLI",
5
5
  "main": "server.js",
6
6
  "bin": {
@@ -8,7 +8,8 @@
8
8
  },
9
9
  "scripts": {
10
10
  "test": "echo \"Error: no test specified\" && exit 1",
11
- "start": "node src/server.js"
11
+ "start": "node src/server.js",
12
+ "doctor": "node src/server.js doctor"
12
13
  },
13
14
  "keywords": [],
14
15
  "author": "",
@@ -34,11 +34,19 @@ export async function doctorCommand() {
34
34
  "-V",
35
35
  ]);
36
36
 
37
- await check(
37
+ const ghInstalled = await check(
38
38
  "GitHub CLI",
39
39
  "gh",
40
40
  ["--version"]
41
41
  );
42
42
 
43
+ if (!ghInstalled) {
44
+ console.log();
45
+ console.log(
46
+ "Hint: Install GitHub CLI (macOS): `brew install gh`"
47
+ );
48
+ console.log("Then authenticate with: `gh auth login`");
49
+ }
50
+
43
51
  console.log();
44
52
  }
@@ -1,7 +1,7 @@
1
1
  import Conf from "conf";
2
2
 
3
3
  const config = new Conf({
4
- projectName: "ghswitch",
4
+ projectName: "gitshift",
5
5
  });
6
6
 
7
7
  export function getProfiles() {
@@ -24,7 +24,7 @@ export async function generateSSHKey(
24
24
  const keyPath = path.join(
25
25
  os.homedir(),
26
26
  ".ssh",
27
- `ghswitch-${safeProfileName}`
27
+ `gitshift-${safeProfileName}`
28
28
  );
29
29
 
30
30
  const exists = await fs.pathExists(