Skip to content

Commit 8a23537

Browse files
committed
fix: rename the executable
1 parent 3ea0053 commit 8a23537

File tree

7 files changed

+14
-10
lines changed

7 files changed

+14
-10
lines changed

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ temp-*
1212

1313
# Build directories
1414
./dist/
15-
!./dist/main.js
16-
!./dist/main.js.map
15+
!./dist/setup_cpp.js
16+
!./dist/setup_cpp.js.map
1717
.parcel-cache
1818
exe

building/pack-exe.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function main() {
2727
return Promise.all(
2828
exes.map((exe) =>
2929
exec(
30-
`./node_modules/.bin/caxa --input ./dist --output ./exe/setup_cpp_${getPlatformName()}${exe} -- "{{caxa}}/node_modules/.bin/node${exe}" "{{caxa}}/main.js"`
30+
`./node_modules/.bin/caxa --input ./dist --output ./exe/setup_cpp_${getPlatformName()}${exe} -- "{{caxa}}/node_modules/.bin/node${exe}" "{{caxa}}/setup_cpp.js"`
3131
)
3232
)
3333
)

dist/main.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

dist/main.js renamed to dist/setup_cpp.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/setup_cpp.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,11 @@
2222
"engines": {
2323
"node": ">=12.x"
2424
},
25-
"main": "./dist/main.js",
25+
"main": "./dist/setup_cpp.js",
26+
"bin": {
27+
"setup_cpp": "./dist/setup_cpp.js",
28+
"setup-cpp": "./dist/setup_cpp.js"
29+
},
2630
"source": "./src/main.ts",
2731
"targets": {
2832
"main": {

src/main.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ export async function main(args: string[]): Promise<number> {
174174
successMessages.forEach((tool) => core.info(tool))
175175
errorMessages.forEach((tool) => core.error(tool))
176176

177-
core.info("setup-cpp finished")
177+
core.info("setup_cpp finished")
178178
return errorMessages.length === 0 ? 0 : 1 // exit with non-zero if any error message
179179
}
180180
// Run main
@@ -190,8 +190,8 @@ main(process.argv)
190190

191191
function printHelp() {
192192
core.info(`
193-
setup-cpp [options]
194-
setup-cpp --compiler llvm --cmake true --ninja true --ccache true --conan "1.40.1"
193+
setup_cpp [options]
194+
setup_cpp --compiler llvm --cmake true --ninja true --ccache true --conan "1.40.1"
195195
196196
Install all the tools required for building and testing C++/C projects.
197197

0 commit comments

Comments
 (0)