isaacscript 2.0.14-dev.7 → 2.0.14
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/LICENSE +674 -0
- package/README.md +4 -6
- package/file-templates/dynamic/gitignore +3 -0
- package/file-templates/static/{.eslintrc.js → .eslintrc.js.template} +0 -0
- package/file-templates/static/.github/workflows/ci.yml +4 -3
- package/file-templates/static/.prettierignore +1 -1
- package/file-templates/static/check-orphaned-words.sh +3 -3
- package/file-templates/static/{.cspell.json.template → cspell.json.template} +1 -1
- package/file-templates/static-alt/.prettierignore-base +1 -1
- package/package.json +6 -2
- package/src/checkForWindowsTerminalBugs.js +75 -79
- package/src/checkForWindowsTerminalBugs.js.map +1 -1
- package/src/commands/copy/copy.js +32 -32
- package/src/commands/init/checkIfProjectPathExists.js +27 -29
- package/src/commands/init/checkIfProjectPathExists.js.map +1 -1
- package/src/commands/init/checkModSubdirectory.js +15 -15
- package/src/commands/init/checkModTargetDirectory.js +30 -32
- package/src/commands/init/checkModTargetDirectory.js.map +1 -1
- package/src/commands/init/createMod.js +142 -137
- package/src/commands/init/createMod.js.map +1 -1
- package/src/commands/init/getModsDir.js +55 -57
- package/src/commands/init/getModsDir.js.map +1 -1
- package/src/commands/init/getProjectPath.js +88 -92
- package/src/commands/init/getProjectPath.js.map +1 -1
- package/src/commands/init/git.js +150 -152
- package/src/commands/init/git.js.map +1 -1
- package/src/commands/init/init.js +65 -69
- package/src/commands/init/init.js.map +1 -1
- package/src/commands/init/installVSCodeExtensions.js +32 -32
- package/src/commands/init/promptSaveSlot.js +21 -24
- package/src/commands/init/promptSaveSlot.js.map +1 -1
- package/src/commands/init/promptVSCode.js +24 -26
- package/src/commands/init/promptVSCode.js.map +1 -1
- package/src/commands/monitor/constants.js +4 -4
- package/src/commands/monitor/copyWatcherMod.js +38 -38
- package/src/commands/monitor/modDirectorySyncer/modDirectorySyncer.js +49 -49
- package/src/commands/monitor/monitor.js +146 -146
- package/src/commands/monitor/notifyGame.js +57 -57
- package/src/commands/monitor/saveDatWriter/saveDatWriter.js +116 -116
- package/src/commands/monitor/saveDatWriter/types.js +2 -2
- package/src/commands/monitor/spawnSaveDatWriter.js +34 -34
- package/src/commands/monitor/touchWatcherSaveDatFiles.js +20 -20
- package/src/commands/publish/publish.js +220 -220
- package/src/configFile.js +63 -65
- package/src/configFile.js.map +1 -1
- package/src/constants.js +59 -59
- package/src/exec.js +95 -95
- package/src/file.js +193 -193
- package/src/main.js +117 -121
- package/src/main.js.map +1 -1
- package/src/parseArgs.js +106 -106
- package/src/prompt.js +86 -92
- package/src/prompt.js.map +1 -1
- package/src/types/Command.js +4 -4
- package/src/types/Config.js +12 -12
- package/src/types/GitHubCLIHostsYAML.js +2 -2
- package/src/utils.js +81 -81
- package/src/validateInIsaacScriptProject.js +26 -26
- package/src/validateNodeVersion.js +24 -24
- package/src/validateOS.js +16 -16
- package/file-templates/static/.gitattributes +0 -9
- package/file-templates/static/nuke.sh +0 -18
- package/file-templates/static/publish.sh +0 -10
- package/src/checkForWindowsTerminalBugs.d.ts +0 -5
- package/src/commands/copy/copy.d.ts +0 -3
- package/src/commands/init/checkIfProjectPathExists.d.ts +0 -1
- package/src/commands/init/checkModSubdirectory.d.ts +0 -1
- package/src/commands/init/checkModTargetDirectory.d.ts +0 -1
- package/src/commands/init/createMod.d.ts +0 -1
- package/src/commands/init/getModsDir.d.ts +0 -1
- package/src/commands/init/getProjectPath.d.ts +0 -1
- package/src/commands/init/git.d.ts +0 -4
- package/src/commands/init/init.d.ts +0 -1
- package/src/commands/init/installVSCodeExtensions.d.ts +0 -1
- package/src/commands/init/promptSaveSlot.d.ts +0 -1
- package/src/commands/init/promptVSCode.d.ts +0 -1
- package/src/commands/monitor/constants.d.ts +0 -1
- package/src/commands/monitor/copyWatcherMod.d.ts +0 -2
- package/src/commands/monitor/modDirectorySyncer/modDirectorySyncer.d.ts +0 -1
- package/src/commands/monitor/monitor.d.ts +0 -2
- package/src/commands/monitor/notifyGame.d.ts +0 -3
- package/src/commands/monitor/saveDatWriter/saveDatWriter.d.ts +0 -1
- package/src/commands/monitor/saveDatWriter/types.d.ts +0 -5
- package/src/commands/monitor/spawnSaveDatWriter.d.ts +0 -4
- package/src/commands/monitor/touchWatcherSaveDatFiles.d.ts +0 -2
- package/src/commands/publish/publish.d.ts +0 -2
- package/src/configFile.d.ts +0 -4
- package/src/constants.d.ts +0 -34
- package/src/exec.d.ts +0 -4
- package/src/file.d.ts +0 -12
- package/src/main.d.ts +0 -2
- package/src/parseArgs.d.ts +0 -1
- package/src/prompt.d.ts +0 -5
- package/src/types/Command.d.ts +0 -2
- package/src/types/Config.d.ts +0 -18
- package/src/types/GitHubCLIHostsYAML.d.ts +0 -7
- package/src/utils.d.ts +0 -13
- package/src/validateInIsaacScriptProject.d.ts +0 -1
- package/src/validateNodeVersion.d.ts +0 -5
- package/src/validateOS.d.ts +0 -1
|
@@ -1,93 +1,89 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getProjectPath = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
6
|
-
const path_1 = tslib_1.__importDefault(require("path"));
|
|
7
|
-
const constants_1 = require("../../constants");
|
|
8
|
-
const prompt_1 = require("../../prompt");
|
|
9
|
-
const utils_1 = require("../../utils");
|
|
10
|
-
// From: https://gist.github.com/doctaphred/d01d05291546186941e1b7ddc02034d3
|
|
11
|
-
const ILLEGAL_CHARACTERS_FOR_WINDOWS_FILENAMES = [
|
|
12
|
-
"<",
|
|
13
|
-
">",
|
|
14
|
-
":",
|
|
15
|
-
'"',
|
|
16
|
-
"/",
|
|
17
|
-
"\\",
|
|
18
|
-
"|",
|
|
19
|
-
"?",
|
|
20
|
-
"*",
|
|
21
|
-
];
|
|
22
|
-
function getProjectPath(argv, useCurrentDir, yes, forceName) {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
if (!(0, utils_1.isKebabCase)(projectName)) {
|
|
90
|
-
(0, utils_1.error)('Error: The project name is not in kebab-case. (Kebab-case is the style of using all lowercase letters, with words separated by hyphens.) Project names must use kebab-case to match GitHub repository standards. If necessary, you can override this check with the "--force-name" flag.');
|
|
91
|
-
}
|
|
92
|
-
}
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getProjectPath = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
6
|
+
const path_1 = tslib_1.__importDefault(require("path"));
|
|
7
|
+
const constants_1 = require("../../constants");
|
|
8
|
+
const prompt_1 = require("../../prompt");
|
|
9
|
+
const utils_1 = require("../../utils");
|
|
10
|
+
// From: https://gist.github.com/doctaphred/d01d05291546186941e1b7ddc02034d3
|
|
11
|
+
const ILLEGAL_CHARACTERS_FOR_WINDOWS_FILENAMES = [
|
|
12
|
+
"<",
|
|
13
|
+
">",
|
|
14
|
+
":",
|
|
15
|
+
'"',
|
|
16
|
+
"/",
|
|
17
|
+
"\\",
|
|
18
|
+
"|",
|
|
19
|
+
"?",
|
|
20
|
+
"*",
|
|
21
|
+
];
|
|
22
|
+
async function getProjectPath(argv, useCurrentDir, yes, forceName) {
|
|
23
|
+
let projectName = getProjectNameFromCommandLineArgument(argv);
|
|
24
|
+
let projectPath;
|
|
25
|
+
let createNewDir;
|
|
26
|
+
if (useCurrentDir) {
|
|
27
|
+
// The "--use-current-dir" command-line flag was specified, so there is no need to prompt the
|
|
28
|
+
// user.
|
|
29
|
+
projectName = constants_1.CURRENT_DIRECTORY_NAME;
|
|
30
|
+
projectPath = constants_1.CWD;
|
|
31
|
+
createNewDir = false;
|
|
32
|
+
}
|
|
33
|
+
else if (projectName !== undefined) {
|
|
34
|
+
// The project name was specified on the command-line.
|
|
35
|
+
projectPath = path_1.default.join(constants_1.CWD, projectName);
|
|
36
|
+
createNewDir = true;
|
|
37
|
+
}
|
|
38
|
+
else if (yes) {
|
|
39
|
+
// The "--yes" command-line flag was specified and the project name was not specified on the
|
|
40
|
+
// command-line, so default to using the current directory.
|
|
41
|
+
projectName = constants_1.CURRENT_DIRECTORY_NAME;
|
|
42
|
+
projectPath = constants_1.CWD;
|
|
43
|
+
createNewDir = false;
|
|
44
|
+
}
|
|
45
|
+
else {
|
|
46
|
+
// The project name was not specified on the command-line, so prompt the user for it.
|
|
47
|
+
[projectName, projectPath, createNewDir] = await getNewProjectName();
|
|
48
|
+
}
|
|
49
|
+
validateProjectName(projectName, forceName);
|
|
50
|
+
console.log(`Using a project name of: ${chalk_1.default.green(projectName)}`);
|
|
51
|
+
return [projectPath, createNewDir];
|
|
52
|
+
}
|
|
53
|
+
exports.getProjectPath = getProjectPath;
|
|
54
|
+
function getProjectNameFromCommandLineArgument(argv) {
|
|
55
|
+
const name = argv["name"];
|
|
56
|
+
return typeof name === "string" && name !== "" ? name : undefined;
|
|
57
|
+
}
|
|
58
|
+
async function getNewProjectName() {
|
|
59
|
+
console.log("You did not specify a project name as a command-line argument.");
|
|
60
|
+
const shouldUseCurrentDir = await (0, prompt_1.getInputYesNo)(`Would you like to create a new project using the current directory "${chalk_1.default.green(constants_1.CURRENT_DIRECTORY_NAME)}" as the root?`);
|
|
61
|
+
if (shouldUseCurrentDir) {
|
|
62
|
+
return [constants_1.CURRENT_DIRECTORY_NAME, constants_1.CWD, false];
|
|
63
|
+
}
|
|
64
|
+
const projectName = await (0, prompt_1.getInputString)("Enter the name of the project:");
|
|
65
|
+
const projectPath = path_1.default.join(constants_1.CWD, projectName);
|
|
66
|
+
return [projectName, projectPath, true];
|
|
67
|
+
}
|
|
68
|
+
function validateProjectName(projectName, forceName) {
|
|
69
|
+
if (projectName === "") {
|
|
70
|
+
(0, utils_1.error)("Error: You cannot have a blank project name.");
|
|
71
|
+
}
|
|
72
|
+
if (process.platform === "win32") {
|
|
73
|
+
for (const character of ILLEGAL_CHARACTERS_FOR_WINDOWS_FILENAMES) {
|
|
74
|
+
if (projectName.includes(character)) {
|
|
75
|
+
(0, utils_1.error)(`Error: The "${character}" character is not allowed in a Windows file name.`);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
if (forceName) {
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
if ((0, utils_1.hasWhiteSpace)(projectName)) {
|
|
83
|
+
(0, utils_1.error)('Error: The project name has whitespace in it, which is not allowed. Use kebab-case for your project name. (e.g. "green-candle")');
|
|
84
|
+
}
|
|
85
|
+
if (!(0, utils_1.isKebabCase)(projectName)) {
|
|
86
|
+
(0, utils_1.error)('Error: The project name is not in kebab-case. (Kebab-case is the style of using all lowercase letters, with words separated by hyphens.) Project names must use kebab-case to match GitHub repository standards. If necessary, you can override this check with the "--force-name" flag.');
|
|
87
|
+
}
|
|
88
|
+
}
|
|
93
89
|
//# sourceMappingURL=getProjectPath.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getProjectPath.js","sourceRoot":"","sources":["../../../../../../packages/isaacscript-cli/src/commands/init/getProjectPath.ts"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAC1B,wDAAwB;AACxB,+CAA8D;AAC9D,yCAA6D;AAC7D,uCAAgE;AAEhE,4EAA4E;AAC5E,MAAM,wCAAwC,GAAG;IAC/C,GAAG;IACH,GAAG;IACH,GAAG;IACH,GAAG;IACH,GAAG;IACH,IAAI;IACJ,GAAG;IACH,GAAG;IACH,GAAG;CACJ,CAAC;
|
|
1
|
+
{"version":3,"file":"getProjectPath.js","sourceRoot":"","sources":["../../../../../../packages/isaacscript-cli/src/commands/init/getProjectPath.ts"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAC1B,wDAAwB;AACxB,+CAA8D;AAC9D,yCAA6D;AAC7D,uCAAgE;AAEhE,4EAA4E;AAC5E,MAAM,wCAAwC,GAAG;IAC/C,GAAG;IACH,GAAG;IACH,GAAG;IACH,GAAG;IACH,GAAG;IACH,IAAI;IACJ,GAAG;IACH,GAAG;IACH,GAAG;CACJ,CAAC;AAEK,KAAK,UAAU,cAAc,CAClC,IAA6B,EAC7B,aAAsB,EACtB,GAAY,EACZ,SAAkB;IAElB,IAAI,WAAW,GAAG,qCAAqC,CAAC,IAAI,CAAC,CAAC;IAC9D,IAAI,WAAmB,CAAC;IACxB,IAAI,YAAqB,CAAC;IAC1B,IAAI,aAAa,EAAE;QACjB,6FAA6F;QAC7F,QAAQ;QACR,WAAW,GAAG,kCAAsB,CAAC;QACrC,WAAW,GAAG,eAAG,CAAC;QAClB,YAAY,GAAG,KAAK,CAAC;KACtB;SAAM,IAAI,WAAW,KAAK,SAAS,EAAE;Q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AAG,EAAE,WAAW,CAAC,CAAC;IAEhD,OAAO,CAAC,WAAW,EAAE,WAAW,EAAE,IAAI,CAAC,CAAC;AAC1C,CAAC;AAED,SAAS,mBAAmB,CAAC,WAAmB,EAAE,SAAkB;IAClE,IAAI,WAAW,KAAK,EAAE,EAAE;QACtB,IAAA,aAAK,EAAC,8CAA8C,CAAC,CAAC;KACvD;IAED,IAAI,OAAO,CAAC,QAAQ,KAAK,OAAO,EAAE;QAChC,KAAK,MAAM,SAAS,IAAI,wCAAwC,EAAE;YAChE,IAAI,WAAW,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE;gBACnC,IAAA,aAAK,EACH,eAAe,SAAS,oDAAoD,CAC7E,CAAC;aACH;SACF;KACF;IAED,IAAI,SAAS,EAAE;QACb,OAAO;KACR;IAED,IAAI,IAAA,qBAAa,EAAC,WAAW,CAAC,EAAE;QAC9B,IAAA,aAAK,EACH,iIAAiI,CAClI,CAAC;KACH;IAED,IAAI,CAAC,IAAA,mBAAW,EAAC,WAAW,CAAC,EAAE;QAC7B,IAAA,aAAK,EACH,0RAA0R,CAC3R,CAAC;KACH;AACH,CAAC"}
|
package/src/commands/init/git.js
CHANGED
|
@@ -1,158 +1,156 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.gitCommitIfChanges = exports.isGitDirty = exports.initGitRepository = exports.promptGitHubRepoOrGitRemoteURL = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
6
|
-
const command_exists_1 = tslib_1.__importDefault(require("command-exists"));
|
|
7
|
-
const path_1 = tslib_1.__importDefault(require("path"));
|
|
8
|
-
const yaml_1 = tslib_1.__importDefault(require("yaml"));
|
|
9
|
-
const constants_1 = require("../../constants");
|
|
10
|
-
const exec_1 = require("../../exec");
|
|
11
|
-
const file = tslib_1.__importStar(require("../../file"));
|
|
12
|
-
const prompt_1 = require("../../prompt");
|
|
13
|
-
const utils_1 = require("../../utils");
|
|
14
|
-
const REQUIRED_GIT_MAJOR_VERSION = 2;
|
|
15
|
-
const REQUIRED_GIT_MINOR_VERSION = 30;
|
|
16
|
-
function promptGitHubRepoOrGitRemoteURL(projectName, yes, verbose) {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
const gitRemoteURL = yield (0, prompt_1.getInputString)(`Paste in the remote Git URL for your project.
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.gitCommitIfChanges = exports.isGitDirty = exports.initGitRepository = exports.promptGitHubRepoOrGitRemoteURL = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
6
|
+
const command_exists_1 = tslib_1.__importDefault(require("command-exists"));
|
|
7
|
+
const path_1 = tslib_1.__importDefault(require("path"));
|
|
8
|
+
const yaml_1 = tslib_1.__importDefault(require("yaml"));
|
|
9
|
+
const constants_1 = require("../../constants");
|
|
10
|
+
const exec_1 = require("../../exec");
|
|
11
|
+
const file = tslib_1.__importStar(require("../../file"));
|
|
12
|
+
const prompt_1 = require("../../prompt");
|
|
13
|
+
const utils_1 = require("../../utils");
|
|
14
|
+
const REQUIRED_GIT_MAJOR_VERSION = 2;
|
|
15
|
+
const REQUIRED_GIT_MINOR_VERSION = 30;
|
|
16
|
+
async function promptGitHubRepoOrGitRemoteURL(projectName, yes, verbose) {
|
|
17
|
+
// We do not need to prompt the user if they do not have Git installed.
|
|
18
|
+
if (!command_exists_1.default.sync("git")) {
|
|
19
|
+
console.log('Git does not seem to be installed. (The "git" command is not in the path.) Skipping Git-related things.');
|
|
20
|
+
return undefined;
|
|
21
|
+
}
|
|
22
|
+
validateNewGitVersion(verbose);
|
|
23
|
+
const gitHubUsername = getGitHubUsername(verbose);
|
|
24
|
+
if (gitHubUsername !== undefined) {
|
|
25
|
+
const [exitStatus] = (0, exec_1.execShell)("gh", ["repo", "view", projectName], verbose, true);
|
|
26
|
+
const gitHubRepoExists = exitStatus === 0;
|
|
27
|
+
const url = `https://github.com/${gitHubUsername}/${projectName}`;
|
|
28
|
+
if (gitHubRepoExists) {
|
|
29
|
+
console.log(`Detected an existing GitHub repository at: ${chalk_1.default.green(url)}`);
|
|
30
|
+
const guessedRemoteURL = getGitRemoteURL(projectName, gitHubUsername);
|
|
31
|
+
if (yes) {
|
|
32
|
+
console.log(`Using a Git remote URL of: ${chalk_1.default.green(guessedRemoteURL)}`);
|
|
33
|
+
return guessedRemoteURL;
|
|
34
|
+
}
|
|
35
|
+
const shouldUseGuessedURL = await (0, prompt_1.getInputYesNo)(`Do you want to use a Git remote URL of: ${chalk_1.default.green(guessedRemoteURL)}`);
|
|
36
|
+
if (shouldUseGuessedURL) {
|
|
37
|
+
return guessedRemoteURL;
|
|
38
|
+
}
|
|
39
|
+
// Assume that since they do not want to connect this project to the existing GitHub
|
|
40
|
+
// repository, they do not want to initialize a remote Git URL at all.
|
|
41
|
+
return undefined;
|
|
42
|
+
}
|
|
43
|
+
if (yes) {
|
|
44
|
+
(0, exec_1.execShell)("gh", ["repo", "create", projectName, "--public"]);
|
|
45
|
+
console.log(`Created a new GitHub repository at: ${chalk_1.default.green(url)}`);
|
|
46
|
+
return getGitRemoteURL(projectName, gitHubUsername);
|
|
47
|
+
}
|
|
48
|
+
const createNewGitHubRepo = await (0, prompt_1.getInputYesNo)(`Would you like to create a new GitHub repository at: ${chalk_1.default.green(url)}`);
|
|
49
|
+
if (createNewGitHubRepo) {
|
|
50
|
+
(0, exec_1.execShell)("gh", ["repo", "create", projectName, "--public"]);
|
|
51
|
+
console.log("Successfully created a new GitHub repository.");
|
|
52
|
+
return getGitRemoteURL(projectName, gitHubUsername);
|
|
53
|
+
}
|
|
54
|
+
// Assume that since they do not want to create a new GitHub repository, they do not want to
|
|
55
|
+
// initialize a remote Git URL at all.
|
|
56
|
+
return undefined;
|
|
57
|
+
}
|
|
58
|
+
const gitRemoteURL = await (0, prompt_1.getInputString)(`Paste in the remote Git URL for your project.
|
|
60
59
|
For example, if you have an SSH key, it would be something like:
|
|
61
60
|
${chalk_1.default.green("git@github.com:Alice/green-candle.git")}
|
|
62
61
|
If you don't have an SSH key, it would be something like:
|
|
63
62
|
${chalk_1.default.green("https://github.com/Alice/green-candle.git")}
|
|
64
63
|
If you don't want to initialize a Git repository for this project, press enter to skip.
|
|
65
|
-
`);
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
const
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
const
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
}
|
|
82
|
-
console.error(
|
|
83
|
-
console.error(
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
const
|
|
101
|
-
const
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
(0, exec_1.execShell)("git", ["
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
(0, exec_1.execShell)("git", ["
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
const [
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
(0, exec_1.execShell)("git", ["
|
|
153
|
-
(0, exec_1.execShell)("git", ["
|
|
154
|
-
(
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
exports.gitCommitIfChanges = gitCommitIfChanges;
|
|
64
|
+
`);
|
|
65
|
+
return gitRemoteURL === "" ? undefined : gitRemoteURL;
|
|
66
|
+
}
|
|
67
|
+
exports.promptGitHubRepoOrGitRemoteURL = promptGitHubRepoOrGitRemoteURL;
|
|
68
|
+
function validateNewGitVersion(verbose) {
|
|
69
|
+
const [, stdout] = (0, exec_1.execShell)("git", ["--version"], verbose);
|
|
70
|
+
const outputPrefix = "git version ";
|
|
71
|
+
if (!stdout.startsWith(outputPrefix)) {
|
|
72
|
+
(0, utils_1.error)(`Failed to parse the output from the "git --version" command: ${stdout}`);
|
|
73
|
+
}
|
|
74
|
+
const gitVersionString = stdout.slice(outputPrefix.length);
|
|
75
|
+
const [majorVersion, minorVersion] = (0, utils_1.parseSemVer)(gitVersionString);
|
|
76
|
+
if (majorVersion >= REQUIRED_GIT_MAJOR_VERSION &&
|
|
77
|
+
minorVersion >= REQUIRED_GIT_MINOR_VERSION) {
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
console.error(`Your Git version is: ${chalk_1.default.red(gitVersionString)}`);
|
|
81
|
+
console.error(`${constants_1.PROJECT_NAME} requires a Git version of ${chalk_1.default.red(`${REQUIRED_GIT_MAJOR_VERSION}.${REQUIRED_GIT_MINOR_VERSION}.0`)} or greater.`);
|
|
82
|
+
console.error(`Please upgrade your version of Git before using ${constants_1.PROJECT_NAME}.`);
|
|
83
|
+
process.exit(1);
|
|
84
|
+
}
|
|
85
|
+
function getGitHubUsername(verbose) {
|
|
86
|
+
// If the GitHub CLI is installed, we can derive the user's GitHub username.
|
|
87
|
+
if (!command_exists_1.default.sync("gh")) {
|
|
88
|
+
return undefined;
|
|
89
|
+
}
|
|
90
|
+
const appData = process.env["APPDATA"];
|
|
91
|
+
if (appData === undefined || appData === "") {
|
|
92
|
+
return undefined;
|
|
93
|
+
}
|
|
94
|
+
const githubCLIHostsPath = path_1.default.join(appData, "GitHub CLI", "hosts.yml");
|
|
95
|
+
if (!file.exists(githubCLIHostsPath, verbose)) {
|
|
96
|
+
return undefined;
|
|
97
|
+
}
|
|
98
|
+
const configYAMLRaw = file.read(githubCLIHostsPath, verbose);
|
|
99
|
+
const configYAML = yaml_1.default.parse(configYAMLRaw);
|
|
100
|
+
const githubCom = configYAML["github.com"];
|
|
101
|
+
if (githubCom === undefined) {
|
|
102
|
+
return undefined;
|
|
103
|
+
}
|
|
104
|
+
const { user } = githubCom;
|
|
105
|
+
if (user === undefined || user === "") {
|
|
106
|
+
return undefined;
|
|
107
|
+
}
|
|
108
|
+
return user;
|
|
109
|
+
}
|
|
110
|
+
function getGitRemoteURL(projectName, gitHubUsername) {
|
|
111
|
+
return `git@github.com:${gitHubUsername}/${projectName}.git`;
|
|
112
|
+
}
|
|
113
|
+
function initGitRepository(projectPath, gitRemoteURL, verbose) {
|
|
114
|
+
if (!command_exists_1.default.sync("git")) {
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
if (gitRemoteURL === undefined) {
|
|
118
|
+
return;
|
|
119
|
+
}
|
|
120
|
+
(0, exec_1.execShell)("git", ["init"], verbose, false, projectPath);
|
|
121
|
+
(0, exec_1.execShell)("git", ["branch", "-M", "main"], verbose, false, projectPath);
|
|
122
|
+
if (isGitNameAndEmailConfigured(verbose)) {
|
|
123
|
+
(0, exec_1.execShell)("git", ["add", "--all"], verbose, false, projectPath);
|
|
124
|
+
(0, exec_1.execShell)("git", ["commit", "--message", `${constants_1.PROJECT_NAME} template`], verbose, false, projectPath);
|
|
125
|
+
}
|
|
126
|
+
if (gitRemoteURL !== undefined) {
|
|
127
|
+
(0, exec_1.execShell)("git", ["remote", "add", "origin", gitRemoteURL], verbose, false, projectPath);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
exports.initGitRepository = initGitRepository;
|
|
131
|
+
function isGitNameAndEmailConfigured(verbose) {
|
|
132
|
+
const [nameExitStatus] = (0, exec_1.execShell)("git", ["config", "--global", "user.name"], verbose, true);
|
|
133
|
+
const [emailExitStatus] = (0, exec_1.execShell)("git", ["config", "--global", "user.email"], verbose, true);
|
|
134
|
+
return nameExitStatus === 0 && emailExitStatus === 0;
|
|
135
|
+
}
|
|
136
|
+
function isGitDirty(verbose) {
|
|
137
|
+
// From: https://remarkablemark.org/blog/2017/10/12/check-git-dirty/
|
|
138
|
+
const [, stdout] = (0, exec_1.execShell)("git", ["status", "--porcelain"], verbose);
|
|
139
|
+
return stdout !== "";
|
|
140
|
+
}
|
|
141
|
+
exports.isGitDirty = isGitDirty;
|
|
142
|
+
function gitCommitIfChanges(version, verbose) {
|
|
143
|
+
// Throw an error if this is not a git repository.
|
|
144
|
+
(0, exec_1.execShell)("git", ["status"], verbose);
|
|
145
|
+
if (!isGitDirty(verbose)) {
|
|
146
|
+
console.log("There are no changes to commit.");
|
|
147
|
+
return;
|
|
148
|
+
}
|
|
149
|
+
const commitMessage = `v${version}`;
|
|
150
|
+
(0, exec_1.execShell)("git", ["add", "-A"], verbose);
|
|
151
|
+
(0, exec_1.execShell)("git", ["commit", "-m", commitMessage], verbose);
|
|
152
|
+
(0, exec_1.execShell)("git", ["push"], verbose);
|
|
153
|
+
console.log(`Committed and pushed to the git repository with a message of: ${commitMessage}`);
|
|
154
|
+
}
|
|
155
|
+
exports.gitCommitIfChanges = gitCommitIfChanges;
|
|
158
156
|
//# sourceMappingURL=git.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git.js","sourceRoot":"","sources":["../../../../../../packages/isaacscript-cli/src/commands/init/git.ts"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAC1B,4EAA2C;AAC3C,wDAAwB;AACxB,wDAAwB;AACxB,+CAA+C;AAC/C,qCAAuC;AACvC,yDAAmC;AACnC,yCAA6D;AAE7D,uCAAiD;AAEjD,MAAM,0BAA0B,GAAG,CAAC,CAAC;AACrC,MAAM,0BAA0B,GAAG,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"git.js","sourceRoot":"","sources":["../../../../../../packages/isaacscript-cli/src/commands/init/git.ts"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAC1B,4EAA2C;AAC3C,wDAAwB;AACxB,wDAAwB;AACxB,+CAA+C;AAC/C,qCAAuC;AACvC,yDAAmC;AACnC,yCAA6D;AAE7D,uCAAiD;AAEjD,MAAM,0BAA0B,GAAG,CAAC,CAAC;AACrC,MAAM,0BAA0B,GAAG,EAAE,CAAC;AAE/B,KAAK,UAAU,8BAA8B,CAClD,WAAmB,EACnB,GAAY,EACZ,OAAgB;IAEhB,uEAAuE;IACvE,IAAI,CAAC,wBAAa,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE;QAC9B,OAAO,CAAC,GAAG,CACT,yGAAyG,CAC1G,CAAC;QACF,OAAO,SAAS,CAA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