vtasks-automate-cli 0.4.4 → 0.4.6

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/init.js +12 -4
  2. package/package.json +1 -1
package/init.js CHANGED
@@ -130,9 +130,17 @@ const main = async () => {
130
130
  }
131
131
  console.log(LOG_COLORS.GREEN, `User email checked: ${userEmail} ✓`);
132
132
 
133
- console.log(LOG_COLORS.BLUE, "Enter the EXACT name of the project:");
133
+ console.log(
134
+ LOG_COLORS.BLUE,
135
+ "Enter the EXACT name of the project (Venturing-Fullstack-Boilerplate) or the github repository link(https://github.com/venturing/Venturing-Fullstack-Boilerplate):"
136
+ );
134
137
  projectName = await readLine();
135
138
  try {
139
+ if (projectName.includes("https://")) {
140
+ projectName = projectName.trim();
141
+ const items = projectName.split("/");
142
+ projectName = items[items.length - 1];
143
+ }
136
144
  await ApiHelpers.checkProjectName(projectName);
137
145
  console.log(LOG_COLORS.GREEN, `Project name checked: ${projectName} ✓`);
138
146
  } catch (error) {
@@ -157,9 +165,9 @@ const main = async () => {
157
165
  const gitIgnoreFile = path.join(process.cwd(), ".gitignore");
158
166
 
159
167
  //Replace start cmd
160
- const reactPath = path.join(__dirname, MAIN_FOLDERS.REACT);
161
- const nextPath = path.join(__dirname, MAIN_FOLDERS.NEXT);
162
- const serverPath = path.join(__dirname, MAIN_FOLDERS.SERVER);
168
+ const reactPath = path.join(process.cwd(), MAIN_FOLDERS.REACT);
169
+ const nextPath = path.join(process.cwd(), MAIN_FOLDERS.NEXT);
170
+ const serverPath = path.join(process.cwd(), MAIN_FOLDERS.SERVER);
163
171
 
164
172
  if (fs.existsSync(carpetaDestino)) {
165
173
  console.error(LOG_COLORS.RED, "Error: vTasks directory already exist");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vtasks-automate-cli",
3
- "version": "0.4.4",
3
+ "version": "0.4.6",
4
4
  "description": "Automate your vTasks workflow with ease — move tasks between states without opening the app",
5
5
  "bin": {
6
6
  "vtasks-automate": "init.js"