xoaryaa 2.0.1 → 2.0.3

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.
Files changed (2) hide show
  1. package/cli.mjs +14 -172
  2. package/package.json +2 -2
package/cli.mjs CHANGED
@@ -1,147 +1,12 @@
1
- // #!/usr/bin/env node
1
+ 'use strict';
2
2
 
3
- // 'use strict'
3
+ import boxen from 'boxen';
4
+ import chalk from 'chalk';
5
+ import inquirer from 'inquirer';
6
+ import clear from 'clear';
7
+ import open from 'open';
4
8
 
5
- // const boxen = import("boxen");
6
- // const chalk = import("chalk");
7
- // const inquirer = import("inquirer");
8
- // const clear = import("clear");
9
- // const open = import("open");
10
- // const fs = import('fs');
11
- // const request = import('request');
12
- // const path = import('path');
13
- // const ora = import('ora');
14
- // const cliSpinners = import('cli-spinners');
15
- // clear();
16
-
17
- // const prompt = inquirer.createPromptModule();
18
-
19
- // const questions = [
20
- // {
21
- // type: "list",
22
- // name: "action",
23
- // message: "What you want to do?",
24
- // choices: [
25
- // {
26
- // name: `Send me an ${chalk.green.bold("email")}?`,
27
- // value: () => {
28
- // open("mailto:arya.tayshete72@gmail.com");
29
- // console.log("\nDone, see you soon at inbox.\n");
30
- // }
31
- // },
32
- // // {
33
- // // name: `Download my ${chalk.magentaBright.bold("Resume")}?`,
34
- // // value: () => {
35
- // // // cliSpinners.dots;
36
- // // const loader = ora({
37
- // // text: ' Downloading Resume',
38
- // // spinner: cliSpinners.material,
39
- // // }).start();
40
- // // let pipe = request('https://anmolsingh.me/api/resume').pipe(fs.createWriteStream('./anmol-resume.html'));
41
- // // pipe.on("finish", function () {
42
- // // let downloadPath = path.join(process.cwd(), 'anmol-resume.html')
43
- // // console.log(`\nResume Downloaded at ${downloadPath} \n`);
44
- // // open(downloadPath)
45
- // // loader.stop();
46
- // // });
47
- // // }
48
- // // },
49
- // // {
50
- // // name: `Schedule a ${chalk.redBright.bold("Meeting")}?`,
51
- // // value: () => {
52
- // // open('https://calendly.com/anmol098/30min');
53
- // // console.log("\n See you at the meeting \n");
54
- // // }
55
- // // },
56
- // {
57
- // name: "Just quit.",
58
- // value: () => {
59
- // console.log("Hasta la vista.\n");
60
- // }
61
- // }
62
- // ]
63
- // }
64
- // ];
65
-
66
- // const data = {
67
- // name: chalk.bold.green(" Arya Tayshete"),
68
- // handle: chalk.white("@xoaryaa"),
69
-
70
- // instagram: chalk.gray("https://instagram.com/") + chalk.cyan("aryataryatarya"),
71
- // github: chalk.gray("https://github.com/") + chalk.green("xoaryaa"),
72
- // linkedin: chalk.gray("https://linkedin.com/in/") + chalk.blue("arya-tayshete"),
73
- // npx: chalk.red("npx") + " " + chalk.white("xoaryaa"),
74
-
75
- // labelInstagram: chalk.white.bold(" Instagram:"),
76
- // labelGitHub: chalk.white.bold(" GitHub:"),
77
- // labelLinkedIn: chalk.white.bold(" LinkedIn:"),
78
- // labelCard: chalk.white.bold(" Card:")
79
- // };
80
-
81
- // const me = boxen(
82
- // [
83
- // `${data.name}`,
84
-
85
-
86
- // ``,
87
- // `${data.labelInstagram} ${data.instagram}`,
88
- // `${data.labelGitHub} ${data.github}`,
89
- // `${data.labelLinkedIn} ${data.linkedin}`,
90
-
91
- // ``,
92
- // `${data.labelCard} ${data.npx}`,
93
- // ``,
94
- // `${chalk.italic(
95
- // "I am currently looking for new opportunities,"
96
- // )}`,
97
- // `${chalk.italic("my inbox is always open. Whether you have a")}`,
98
- // `${chalk.italic(
99
- // "question or just want to say hi, I will try "
100
- // )}`,
101
- // `${chalk.italic(
102
- // "my best to get back to you!"
103
- // )}`
104
- // ].join("\n"),
105
- // {
106
- // margin: 1,
107
- // float: 'center',
108
- // padding: 1,
109
- // borderStyle: "single",
110
- // borderColor: "green"
111
- // }
112
- // );
113
-
114
- // console.log(me);
115
- // const tip = [
116
- // `Tip: Try ${chalk.cyanBright.bold(
117
- // "cmd/ctrl + click"
118
- // )} on the links above`,
119
- // '',
120
- // ].join("\n");
121
- // console.log(tip);
122
-
123
- // prompt(questions).then(answer => answer.action());
124
-
125
- #!/usr/bin / env node
126
-
127
- 'use strict'
128
-
129
- import { createRequire } from 'module';
130
- const require = createRequire(import.meta.url);
131
-
132
- // Importing modules dynamically
133
- const boxen = (await import('boxen')).default;
134
- const chalk = (await import('chalk')).default;
135
- const inquirer = (await import('inquirer')).default;
136
- const clear = (await import('clear')).default;
137
- const open = (await import('open')).default;
138
- const fs = (await import('fs')).default;
139
- const request = (await import('request')).default;
140
- const path = (await import('path')).default;
141
- const ora = (await import('ora')).default;
142
- const cliSpinners = (await import('cli-spinners')).default;
143
-
144
- clear(); // Clear the terminal screen
9
+ clear();
145
10
 
146
11
  const prompt = inquirer.createPromptModule();
147
12
 
@@ -158,30 +23,6 @@ const questions = [
158
23
  console.log("\nDone, see you soon at inbox.\n");
159
24
  }
160
25
  },
161
- // Uncomment if needed
162
- // {
163
- // name: `Download my ${chalk.magentaBright.bold("Resume")}?`,
164
- // value: () => {
165
- // const loader = ora({
166
- // text: 'Downloading Resume',
167
- // spinner: cliSpinners.material,
168
- // }).start();
169
- // let pipe = request('https://anmolsingh.me/api/resume').pipe(fs.createWriteStream('./anmol-resume.html'));
170
- // pipe.on("finish", function () {
171
- // let downloadPath = path.join(process.cwd(), 'anmol-resume.html')
172
- // console.log(`\nResume Downloaded at ${downloadPath}\n`);
173
- // open(downloadPath);
174
- // loader.stop();
175
- // });
176
- // }
177
- // },
178
- // {
179
- // name: `Schedule a ${chalk.redBright.bold("Meeting")}?`,
180
- // value: () => {
181
- // open('https://calendly.com/anmol098/30min');
182
- // console.log("\nSee you at the meeting\n");
183
- // }
184
- // },
185
26
  {
186
27
  name: "Just quit.",
187
28
  value: () => {
@@ -193,16 +34,16 @@ const questions = [
193
34
  ];
194
35
 
195
36
  const data = {
196
- name: chalk.bold.green(" Arya Tayshete"),
37
+ name: chalk.bold.green("Arya Tayshete"),
197
38
  handle: chalk.white("@xoaryaa"),
198
39
  instagram: chalk.gray("https://instagram.com/") + chalk.cyan("aryataryatarya"),
199
40
  github: chalk.gray("https://github.com/") + chalk.green("xoaryaa"),
200
41
  linkedin: chalk.gray("https://linkedin.com/in/") + chalk.blue("arya-tayshete"),
201
42
  npx: chalk.red("npx") + " " + chalk.white("xoaryaa"),
202
- labelInstagram: chalk.white.bold(" Instagram:"),
203
- labelGitHub: chalk.white.bold(" GitHub:"),
204
- labelLinkedIn: chalk.white.bold(" LinkedIn:"),
205
- labelCard: chalk.white.bold(" Card:")
43
+ labelInstagram: chalk.white.bold("Instagram:"),
44
+ labelGitHub: chalk.white.bold("GitHub:"),
45
+ labelLinkedIn: chalk.white.bold("LinkedIn:"),
46
+ labelCard: chalk.white.bold("Card:")
206
47
  };
207
48
 
208
49
  const me = boxen(
@@ -217,7 +58,7 @@ const me = boxen(
217
58
  ``,
218
59
  `${chalk.italic("I am currently looking for new opportunities,")}`,
219
60
  `${chalk.italic("my inbox is always open. Whether you have a")}`,
220
- `${chalk.italic("question or just want to say hi, I will try")}`,
61
+ `${chalk.italic("question or just want to say hi, I will try ")}`,
221
62
  `${chalk.italic("my best to get back to you!")}`
222
63
  ].join("\n"),
223
64
  {
@@ -235,6 +76,7 @@ const tip = [
235
76
  `Tip: Try ${chalk.cyanBright.bold("cmd/ctrl + click")} on the links above`,
236
77
  '',
237
78
  ].join("\n");
79
+
238
80
  console.log(tip);
239
81
 
240
82
  prompt(questions).then(answer => answer.action());
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "xoaryaa",
3
- "version": "2.0.1",
3
+ "version": "2.0.3",
4
4
  "main": "index.js",
5
5
  "bin": {
6
6
  "xoaryaa": "./cli.mjs"
7
7
  },
8
8
  "scripts": {
9
9
  "test": "node cli.mjs",
10
- "pub": "npm version major & npm publish"
10
+ "pub": "npm version major && npm publish"
11
11
  },
12
12
  "keywords": [
13
13
  "card",