Skip to content

Commit f43faf4

Browse files
committed
fix: npm
1 parent 2c027f1 commit f43faf4

File tree

5 files changed

+11205
-11
lines changed

5 files changed

+11205
-11
lines changed

.github/workflows/main.yml renamed to .github/workflows/build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ jobs:
3636
node-version: '20'
3737
cache: 'npm'
3838

39+
- name: Install dependencies
40+
run: npm ci --prefer-offline --no-audit --progress=false
41+
3942
- name: Build project
4043
run: make website
4144

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
out/
2+
node_modules/
23
super-linter.log

Makefile

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
SPEC_GENERATOR_VER=1.5.0
2-
31
.PHONY: install
42

53
all: website
@@ -8,20 +6,15 @@ clean:
86
rm -rf ./out
97

108
install:
11-
@INSTALLED_VERSION=$$(spec-generator --version); \
12-
if [ "$$INSTALLED_VERSION" != "$(SPEC_GENERATOR_VER)" ]; then \
13-
echo "Installed version ($$INSTALLED_VERSION) is different from the desired version ($(SPEC_GENERATOR_VER))."; \
14-
echo "Installing spec-generator@v$(SPEC_GENERATOR_VER)"; \
15-
npm install -g spec-generator@v$(SPEC_GENERATOR_VER); \
16-
else \
17-
echo "spec-generator is already installed at the desired version ($(SPEC_GENERATOR_VER))."; \
9+
@if [ ! -d "node_modules" ] || ! git diff --quiet package-lock.json; then \
10+
npm ci --prefer-offline --no-audit --no-fund --progress=false; \
1811
fi
1912

2013
website: clean install
21-
spec-generator -c .config.json
14+
npx spec-generator -c .config.json
2215

2316
watch: clean install
24-
spec-generator -c .config.json -w
17+
npx spec-generator -c .config.json -w
2518

2619
superlinter:
2720
docker run --rm -e VALIDATE_ALL_CODEBASE=false -e RUN_LOCAL=true -e VALIDATE_MARKDOWN=true -e MARKDOWN_CONFIG_FILE=".markdownlint.json" -e LINTER_RULES_PATH="." -e DEFAULT_BRANCH='main' -v $(shell pwd):/tmp/lint ghcr.io/super-linter/super-linter:slim-v7

0 commit comments

Comments
 (0)