mirror of
https://github.com/peaceiris/actions-hugo.git
synced 2025-06-18 10:05:28 +08:00
Compare commits
4 Commits
dd23b14e13
...
84b5946660
Author | SHA1 | Date | |
---|---|---|---|
![]() |
84b5946660 | ||
![]() |
966dfad385 | ||
![]() |
c57490a8b0 | ||
![]() |
f6d0e78500 |
1
.github/workflows/test-action.yml
vendored
1
.github/workflows/test-action.yml
vendored
@ -11,7 +11,6 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os:
|
os:
|
||||||
- 'ubuntu-22.04'
|
|
||||||
- 'ubuntu-20.04'
|
- 'ubuntu-20.04'
|
||||||
- 'ubuntu-latest'
|
- 'ubuntu-latest'
|
||||||
- 'macos-latest'
|
- 'macos-latest'
|
||||||
|
11
.github/workflows/test.yml
vendored
11
.github/workflows/test.yml
vendored
@ -14,6 +14,7 @@ jobs:
|
|||||||
test:
|
test:
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os:
|
os:
|
||||||
- 'ubuntu-22.04'
|
- 'ubuntu-22.04'
|
||||||
@ -24,14 +25,10 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Read .nvmrc
|
- uses: actions/setup-node@v4
|
||||||
run: echo "::set-output name=NVMRC::$(cat .nvmrc)"
|
|
||||||
id: nvm
|
|
||||||
|
|
||||||
- name: Setup Node
|
|
||||||
uses: actions/setup-node@v3.6.0
|
|
||||||
with:
|
with:
|
||||||
node-version: '${{ steps.nvm.outputs.NVMRC }}'
|
node-version-file: '.nvmrc'
|
||||||
|
cache: 'npm'
|
||||||
|
|
||||||
- run: npm ci
|
- run: npm ci
|
||||||
|
|
||||||
|
3
Makefile
3
Makefile
@ -2,14 +2,13 @@ cmd := "bash"
|
|||||||
msg := ""
|
msg := ""
|
||||||
IMAGE_NAME := actions_hugo_dev:latest
|
IMAGE_NAME := actions_hugo_dev:latest
|
||||||
NODE_VERSION := $(shell cat ./.nvmrc)
|
NODE_VERSION := $(shell cat ./.nvmrc)
|
||||||
DOCKER_BUILD := docker build . -t $(IMAGE_NAME) --build-arg NODE_VERSION=$(NODE_VERSION)
|
|
||||||
DOCKER_RUN := docker run --rm -i -t -v ${PWD}:/repo -v ~/.gitconfig:/root/.gitconfig $(IMAGE_NAME)
|
DOCKER_RUN := docker run --rm -i -t -v ${PWD}:/repo -v ~/.gitconfig:/root/.gitconfig $(IMAGE_NAME)
|
||||||
DOCKER_RUN_CI := docker run --rm -v ${PWD}:/repo $(IMAGE_NAME)
|
DOCKER_RUN_CI := docker run --rm -v ${PWD}:/repo $(IMAGE_NAME)
|
||||||
|
|
||||||
|
|
||||||
.PHONY: build
|
.PHONY: build
|
||||||
build:
|
build:
|
||||||
$(DOCKER_BUILD)
|
docker build . -t $(IMAGE_NAME) --build-arg NODE_VERSION=$(NODE_VERSION)
|
||||||
|
|
||||||
.PHONY: run
|
.PHONY: run
|
||||||
run:
|
run:
|
||||||
|
@ -261,10 +261,9 @@ jobs:
|
|||||||
hugo-version: '0.119.0'
|
hugo-version: '0.119.0'
|
||||||
extended: true
|
extended: true
|
||||||
|
|
||||||
- name: Setup Node
|
- uses: actions/setup-node@v4
|
||||||
uses: actions/setup-node@v3
|
|
||||||
with:
|
with:
|
||||||
node-version: '18'
|
node-version: '20'
|
||||||
cache: 'npm'
|
cache: 'npm'
|
||||||
# The action defaults to search for the dependency file (package-lock.json,
|
# The action defaults to search for the dependency file (package-lock.json,
|
||||||
# npm-shrinkwrap.json or yarn.lock) in the repository root, and uses its
|
# npm-shrinkwrap.json or yarn.lock) in the repository root, and uses its
|
||||||
|
@ -11,7 +11,7 @@ inputs:
|
|||||||
required: false
|
required: false
|
||||||
default: 'false'
|
default: 'false'
|
||||||
runs:
|
runs:
|
||||||
using: 'node16'
|
using: 'node20'
|
||||||
main: 'lib/index.js'
|
main: 'lib/index.js'
|
||||||
branding:
|
branding:
|
||||||
icon: 'package'
|
icon: 'package'
|
||||||
|
16
docker-compose.yml
Normal file
16
docker-compose.yml
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
version: '3.2'
|
||||||
|
|
||||||
|
services:
|
||||||
|
dev:
|
||||||
|
image: 'docker.pkg.github.com/peaceiris/actions-hugo/dev:latest'
|
||||||
|
build:
|
||||||
|
context: .
|
||||||
|
# cache_from:
|
||||||
|
# - 'docker.pkg.github.com/peaceiris/actions-hugo/dev:latest'
|
||||||
|
container_name: peaceiris_actions_hugo_dev_latest
|
||||||
|
volumes:
|
||||||
|
- ${PWD}:/repo
|
||||||
|
stdin_open: true
|
||||||
|
tty: true
|
||||||
|
command:
|
||||||
|
- bash
|
2025
package-lock.json
generated
2025
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
10
package.json
10
package.json
@ -1,11 +1,11 @@
|
|||||||
{
|
{
|
||||||
"name": "actions-hugo",
|
"name": "actions-hugo",
|
||||||
"version": "2.6.0",
|
"version": "3.0.0",
|
||||||
"description": "GitHub Actions for Hugo",
|
"description": "GitHub Actions for Hugo",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=16.18.0",
|
"node": ">=20.10.0",
|
||||||
"npm": ">=8.19.0"
|
"npm": ">=10.2.3"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"all": "npm run format:check && npm run lint && npm test",
|
"all": "npm run format:check && npm run lint && npm test",
|
||||||
@ -55,11 +55,11 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/jest": "^26.0.20",
|
"@types/jest": "^26.0.20",
|
||||||
"@types/node": "~12",
|
"@types/node": "~20",
|
||||||
"@types/node-fetch": "^2.5.8",
|
"@types/node-fetch": "^2.5.8",
|
||||||
"@typescript-eslint/eslint-plugin": "^4.16.1",
|
"@typescript-eslint/eslint-plugin": "^4.16.1",
|
||||||
"@typescript-eslint/parser": "^4.16.1",
|
"@typescript-eslint/parser": "^4.16.1",
|
||||||
"@vercel/ncc": "^0.27.0",
|
"@vercel/ncc": "^0.38.1",
|
||||||
"eslint": "^7.21.0",
|
"eslint": "^7.21.0",
|
||||||
"eslint-plugin-jest": "^24.1.5",
|
"eslint-plugin-jest": "^24.1.5",
|
||||||
"husky": "^5.1.3",
|
"husky": "^5.1.3",
|
||||||
|
Loading…
Reference in New Issue
Block a user