Skip to content

Commit 477360f

Browse files
committed
fix: rename the executable to setup-cpp.js
BREAKING CHANGE the executable is now `setup-cpp.js`
1 parent 60b884b commit 477360f

25 files changed

+74
-64
lines changed

.github/workflows/CI.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,8 @@ jobs:
106106
./exe/setup_cpp_windows.exe
107107
./exe/setup_cpp_linux
108108
./exe/setup_cpp_mac
109-
./dist/node12/setup_cpp.js
110-
./dist/node12/setup_cpp.js.map
109+
./dist/node12/setup-cpp.js
110+
./dist/node12/setup-cpp.js.map
111111
./dist/node12/
112112
./dist/node16/
113113
@@ -161,4 +161,4 @@ jobs:
161161
- name: Build
162162
id: docker_build
163163
run: |
164-
docker build -f ./dev/docker/${{ matrix.container }} -t setup_cpp .
164+
docker build -f ./dev/docker/${{ matrix.container }} -t setup-cpp .

README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -74,25 +74,25 @@ NOTE: On Unix systems, you will not need `sudo` if you are already a root user (
7474

7575
#### With Nodejs
7676

77-
Download the `setup_cpp.js` file form [here](https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup_cpp.js), and run it with the available options.
77+
Download the `setup-cpp.js` file form [here](https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup-cpp.js), and run it with the available options.
7878

7979
On Windows:
8080

8181
Open the shell as admin, download via `curl`, then install
8282

8383
```ps1
8484
# open shell as admin
85-
curl.exe -LJO "https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup_cpp.js"
86-
node ./setup_cpp.js --compiler llvm --cmake true --ninja true --ccache true --vcpkg true
85+
curl.exe -LJO "https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup-cpp.js"
86+
node ./setup-cpp.js --compiler llvm --cmake true --ninja true --ccache true --vcpkg true
8787
8888
RefreshEnv.cmd # activate cpp environment variables
8989
```
9090

9191
On Linux or Mac:
9292

9393
```ps1
94-
wget "https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup_cpp.js"
95-
sudo node ./setup_cpp.js --compiler llvm --cmake true --ninja true --ccache true --vcpkg true
94+
wget "https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup-cpp.js"
95+
sudo node ./setup-cpp.js --compiler llvm --cmake true --ninja true --ccache true --vcpkg true
9696
9797
source ~/.cpprc # activate cpp environment variables
9898
```
@@ -160,13 +160,13 @@ jobs:
160160

161161
### Inside Docker
162162

163-
Here is an example for using setup_cpp to make a builder image that has the Cpp tools you need.
163+
Here is an example for using setup-cpp to make a builder image that has the Cpp tools you need.
164164

165165
```dockerfile
166166
#### Base Image
167167
FROM ubuntu:22.04 AS base
168168

169-
# add setup_cpp
169+
# add setup-cpp
170170
WORKDIR "/"
171171
RUN apt-get update -qq
172172
RUN apt-get install -y --no-install-recommends wget
@@ -202,15 +202,15 @@ If you want to build the ones included, then run:
202202
```ps1
203203
git clone --recurse-submodules https://github.com/aminya/setup-cpp
204204
cd ./setup-cpp
205-
docker build -f ./dev/docker/ubuntu.dockerfile -t setup_cpp .
205+
docker build -f ./dev/docker/ubuntu.dockerfile -t setup-cpp .
206206
```
207207

208208
Where you should use the path to the dockerfile after `-f`.
209209

210210
After build, run the following to start an interactive shell in your container
211211

212212
```ps1
213-
docker run -it setup_cpp
213+
docker run -it setup-cpp
214214
```
215215

216216
### Inside Docker inside GitHub Actions
@@ -230,7 +230,7 @@ jobs:
230230
- name: Build
231231
id: docker_build
232232
run: |
233-
docker build -f ./dev/docker/debian.dockerfile -t setup_cpp .
233+
docker build -f ./dev/docker/debian.dockerfile -t setup-cpp .
234234
```
235235
236236
### Inside GitLab pipelines
@@ -261,7 +261,7 @@ stages:
261261
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5
262262
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 1E9377A2BA9EF27F
263263

264-
.setup_cpp: &setup_cpp |
264+
.setup-cpp: &setup-cpp |
265265
curl -LJO "https://github.com/aminya/setup-cpp/releases/download/v0.25.1/setup_cpp_linux"
266266
chmod +x setup_cpp_linux
267267
./setup_cpp_linux --compiler $compiler --cmake true --ninja true --ccache true --vcpkg true
@@ -277,7 +277,7 @@ test_linux_llvm:
277277
compiler: llvm
278278
script:
279279
- *setup_linux
280-
- *setup_cpp
280+
- *setup-cpp
281281
- *test
282282

283283
test_linux_gcc:
@@ -286,7 +286,7 @@ test_linux_gcc:
286286
compiler: gcc
287287
script:
288288
- *setup_linux
289-
- *setup_cpp
289+
- *setup-cpp
290290
- *test
291291
```
292292

action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ inputs:
8484

8585
runs:
8686
using: "node16"
87-
main: "dist/node16/setup_cpp.js"
87+
main: "dist/node16/setup-cpp.js"
8888

8989
branding:
9090
icon: "award"

dev/docker/arch_node.dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ RUN pacman -S --noconfirm --needed nodejs
1010
# curl for downloading setup-cpp
1111
RUN pacman -S --noconfirm --needed curl
1212

13-
# add setup_cpp.js
13+
# add setup-cpp.js
1414
COPY "./dist/node12" "/"
1515
WORKDIR "/"
1616

1717
# run installation
18-
RUN node ./setup_cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true
18+
RUN node ./setup-cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true
1919

2020
# clean up
2121
RUN pacman -Scc --noconfirm

dev/docker/fedora_node.dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@ RUN dnf -y install nodejs
77
# curl for downloading setup-cpp
88
RUN dnf -y install curl
99

10-
# add setup_cpp.js
10+
# add setup-cpp.js
1111
COPY "./dist/node12" "/"
1212
WORKDIR "/"
1313

1414
# run installation
15-
RUN node ./setup_cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true --powershell true
15+
RUN node ./setup-cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true --powershell true
1616

1717
# clean up
1818
RUN rm -rf /tmp/*

dev/docker/ubuntu.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#### Base Image
22
FROM ubuntu:22.04 AS base
33

4-
# add setup_cpp
4+
# add setup-cpp
55
WORKDIR "/"
66
RUN apt-get update -qq
77
RUN apt-get install -y --no-install-recommends wget

dev/docker/ubuntu_20.04_node.dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ RUN apt-get install -y --no-install-recommends curl gnupg ca-certificates
1111
RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -
1212
RUN apt-get install -y --no-install-recommends nodejs
1313

14-
# add setup_cpp.js
14+
# add setup-cpp.js
1515
COPY "./dist/node12" "/"
1616
WORKDIR "/"
1717

1818
# run installation
19-
RUN node ./setup_cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true
19+
RUN node ./setup-cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true
2020

2121
CMD source ~/.cpprc
2222
ENTRYPOINT [ "/bin/bash" ]

dev/docker/ubuntu_node.dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ FROM ubuntu:22.04 AS base
33
RUN apt-get update -qq
44
RUN apt-get install -y --no-install-recommends nodejs
55

6-
# add setup_cpp.js
6+
# add setup-cpp.js
77
COPY "./dist/node12" "/"
88
WORKDIR "/"
99

1010
# run installation
11-
RUN node ./setup_cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true --powershell true
11+
RUN node ./setup-cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true --powershell true
1212

1313
# clean up
1414
RUN apt-get clean && rm -rf /var/lib/apt/lists/*

dev/scripts/debug_remove.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const { join, dirname } = require("path")
55

66
async function main() {
77
console.log("Disabling debug messages inside @actions/core")
8-
const file = join(dirname(__dirname), "dist", "setup_cpp.js")
8+
const file = join(dirname(__dirname), "dist", "setup-cpp.js")
99
const { code, map } = await minify(readFileSync(file, "utf8"), { sourceMap: true, ...require("../.terserrc.js") })
1010

1111
writeFileSync(file, code)

dev/scripts/pack-exe.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ function main() {
3434
`./exe/setup_cpp_${getPlatformName()}${exe}`,
3535
"--",
3636
`{{caxa}}/node_modules/.bin/node${exe}`,
37-
`{{caxa}}/setup_cpp.js`,
37+
`{{caxa}}/setup-cpp.js`,
3838
])
3939
)
4040
)

0 commit comments

Comments
 (0)