Skip to content

Commit eff6ac4

Browse files
committed
initial commit
Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
1 parent b488799 commit eff6ac4

27 files changed

+46355
-0
lines changed

.env

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# dotenv-linter:off IncorrectDelimiter
2+
3+
# Do not commit your actual .env file to Git! This may contain secrets or other
4+
# private information.
5+
6+
# Enable/disable step debug logging (default: `false`). For local debugging, it
7+
# may be useful to set it to `true`.
8+
ACTIONS_STEP_DEBUG=true
9+
10+
# GitHub Actions inputs should follow `INPUT_<name>` format (case-sensitive).
11+
# Hyphens should not be converted to underscores!
12+
INPUT_MILLISECONDS=2400
13+
14+
# GitHub Actions default environment variables. These are set for every run of a
15+
# workflow and can be used in your actions. Setting the value here will override
16+
# any value set by the local-action tool.
17+
# https://docs.github.com/en/actions/learn-github-actions/variables#default-environment-variables
18+
19+
# CI="true"
20+
# GITHUB_ACTION=""
21+
# GITHUB_ACTION_PATH=""
22+
# GITHUB_ACTION_REPOSITORY=""
23+
# GITHUB_ACTIONS=""
24+
# GITHUB_ACTOR=""
25+
# GITHUB_ACTOR_ID=""
26+
# GITHUB_API_URL=""
27+
# GITHUB_BASE_REF=""
28+
# GITHUB_ENV=""
29+
# GITHUB_EVENT_NAME=""
30+
# GITHUB_EVENT_PATH=""
31+
# GITHUB_GRAPHQL_URL=""
32+
# GITHUB_HEAD_REF=""
33+
# GITHUB_JOB=""
34+
# GITHUB_OUTPUT=""
35+
# GITHUB_PATH=""
36+
# GITHUB_REF=""
37+
# GITHUB_REF_NAME=""
38+
# GITHUB_REF_PROTECTED=""
39+
# GITHUB_REF_TYPE=""
40+
# GITHUB_REPOSITORY=""
41+
# GITHUB_REPOSITORY_ID=""
42+
# GITHUB_REPOSITORY_OWNER=""
43+
# GITHUB_REPOSITORY_OWNER_ID=""
44+
# GITHUB_RETENTION_DAYS=""
45+
# GITHUB_RUN_ATTEMPT=""
46+
# GITHUB_RUN_ID=""
47+
# GITHUB_RUN_NUMBER=""
48+
# GITHUB_SERVER_URL=""
49+
# GITHUB_SHA=""
50+
# GITHUB_STEP_SUMMARY=""
51+
# GITHUB_TRIGGERING_ACTOR=""
52+
# GITHUB_WORKFLOW=""
53+
# GITHUB_WORKFLOW_REF=""
54+
# GITHUB_WORKFLOW_SHA=""
55+
# GITHUB_WORKSPACE=""
56+
# RUNNER_ARCH=""
57+
# RUNNER_DEBUG=""
58+
# RUNNER_NAME=""
59+
# RUNNER_OS=""
60+
RUNNER_TEMP=".local/tmp"
61+
RUNNER_TOOL_CACHE=".local/cache"

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
github: jkroepke

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#### What this PR does / why we need it
2+
3+
#### Which issue this PR fixes
4+
5+
*(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #
6+
7+
- fixes #
8+
9+
#### Special notes for your reviewer
10+
11+
#### Particularly user-facing changes
12+
13+
#### Checklist
14+
15+
Complete these before marking the PR as `ready to review`:
16+
17+
<!-- [Place an '[x]' (no spaces) in all applicable fields.] -->
18+
19+
- [ ] [DCO](https://github.com/prometheus-community/helm-charts/blob/main/CONTRIBUTING.md#sign-off-your-work) signed
20+
- [ ] The PR title has a summary of the changes
21+
- [ ] The PR body has a summary to reflect any significant (and particularly user-facing) changes introduced by this PR

.github/release.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
changelog:
2+
exclude:
3+
labels:
4+
- chore
5+
categories:
6+
- title: 💥 Breaking Changes
7+
labels:
8+
- 💥 breaking-change
9+
- title: ✨ Exciting New Features
10+
labels:
11+
- ✨ enhancement
12+
- title: 🐞 Bug Fixes
13+
labels:
14+
- 🐞 bug
15+
- title: 🛠️ Dependencies
16+
labels:
17+
- 🛠️ dependencies
18+
- title: 📖 Documentation
19+
labels:
20+
- 📖 docs
21+
- title: Other Changes
22+
labels:
23+
- "*"

.github/workflows/test.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
env:
2+
RUNNER_DEBUG: 1
3+
4+
name: 'build-test'
5+
on: # rebuild any PRs and main branch changes
6+
pull_request:
7+
push:
8+
branches:
9+
- main
10+
- 'releases/*'
11+
12+
jobs:
13+
build: # make sure build/ci work properly
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
17+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
18+
with:
19+
node-version: '22'
20+
- run: |
21+
npm install
22+
npm run all
23+
- run: |
24+
git diff --exit-code ':!dist/index.js.map' ':!badges/coverage.svg'
25+
test: # make sure the action works on a clean machine without building
26+
runs-on: ${{ matrix.os }}
27+
strategy:
28+
matrix:
29+
os: [ubuntu-latest, macos-latest, windows-latest]
30+
steps:
31+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
32+
- uses: ./
33+
- name: Get the version
34+
run: stackit --version
35+
- uses: ./
36+
with:
37+
version: v0.30.0
38+
- name: Get the version
39+
run: stackit --version |& grep 0.30.0
40+
- uses: ./
41+
with:
42+
version: 0.28.0
43+
- name: Get the version
44+
run: stackit --version |& grep 0.28.0
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Update Major Tag
2+
on:
3+
workflow_dispatch:
4+
push:
5+
tags:
6+
- 'v[0-9]+.[0-9]+.[0-9]+'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
set-tag:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
16+
- run: |
17+
TAG=${{ github.ref_name }}
18+
TAG=${TAG%%.*}
19+
git tag -f ${TAG}
20+
git push --tags --force

.gitignore

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
# Dependency directory
2+
node_modules
3+
4+
# Rest pulled from https://github.com/github/gitignore/blob/master/Node.gitignore
5+
# Logs
6+
logs
7+
*.log
8+
npm-debug.log*
9+
yarn-debug.log*
10+
yarn-error.log*
11+
lerna-debug.log*
12+
13+
# Diagnostic reports (https://nodejs.org/api/report.html)
14+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
15+
16+
# Runtime data
17+
pids
18+
*.pid
19+
*.seed
20+
*.pid.lock
21+
22+
# Directory for instrumented libs generated by jscoverage/JSCover
23+
lib-cov
24+
25+
# Coverage directory used by tools like istanbul
26+
coverage
27+
*.lcov
28+
29+
# nyc test coverage
30+
.nyc_output
31+
32+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
33+
.grunt
34+
35+
# Bower dependency directory (https://bower.io/)
36+
bower_components
37+
38+
# node-waf configuration
39+
.lock-wscript
40+
41+
# Compiled binary addons (https://nodejs.org/api/addons.html)
42+
build/Release
43+
44+
# Dependency directories
45+
jspm_packages/
46+
47+
# TypeScript v1 declaration files
48+
typings/
49+
50+
# TypeScript cache
51+
*.tsbuildinfo
52+
53+
# Optional npm cache directory
54+
.npm
55+
56+
# Optional eslint cache
57+
.eslintcache
58+
59+
# Optional REPL history
60+
.node_repl_history
61+
62+
# Output of 'npm pack'
63+
*.tgz
64+
65+
# Yarn Integrity file
66+
.yarn-integrity
67+
68+
# dotenv environment variables file
69+
.local
70+
71+
# parcel-bundler cache (https://parceljs.org/)
72+
.cache
73+
74+
# next.js build output
75+
.next
76+
77+
# nuxt.js build output
78+
.nuxt
79+
80+
# vuepress build output
81+
.vuepress/dist
82+
83+
# Serverless directories
84+
.serverless/
85+
86+
# FuseBox cache
87+
.fusebox/
88+
89+
# DynamoDB Local files
90+
.dynamodb/
91+
92+
# OS metadata
93+
.DS_Store
94+
Thumbs.db
95+
96+
# Ignore built ts files
97+
__tests__/runner/*
98+
99+
.idea

.prettierrc.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# See: https://prettier.io/docs/en/configuration
2+
3+
printWidth: 80
4+
tabWidth: 2
5+
useTabs: false
6+
semi: false
7+
singleQuote: true
8+
quoteProps: as-needed
9+
jsxSingleQuote: false
10+
trailingComma: none
11+
bracketSpacing: true
12+
bracketSameLine: true
13+
arrowParens: always
14+
proseWrap: always
15+
htmlWhitespaceSensitivity: css
16+
endOfLine: lf

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
![build-test](https://github.com/jkroepke/setup-vals/workflows/build-test/badge.svg)
2+
3+
## Setup stackit-cli
4+
5+
GitHub Action for installing
6+
[stackitcloud/stackit-cli](https://github.com/stackitcloud/stackit-cli)
7+
8+
Install a specific version of vals binary on the runner. Acceptable values are
9+
latest or any semantic version string like v2.16.7 Use this action in workflow
10+
to define which version of sops will be used.
11+
12+
```yaml
13+
- name: Stackit Binary Installer
14+
uses: jkroepke/setup-stackit-cli@v1
15+
with:
16+
version: '<version>' # default is latest stable
17+
id: install
18+
```
19+
20+
The cached vals binary path is prepended to the PATH environment variable as
21+
well as stored in the vals-path output variable. Refer to the action metadata
22+
file for details about all the inputs
23+
[here](https://github.com/jkroepke/setup-stackit-cli/blob/master/action.yml).

__fixtures__/core.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import type * as core from '@actions/core'
2+
import { jest } from '@jest/globals'
3+
4+
export const debug = jest.fn<typeof core.debug>()
5+
export const error = jest.fn<typeof core.error>()
6+
export const info = jest.fn<typeof core.info>()
7+
export const getInput = jest.fn<typeof core.getInput>()
8+
export const setOutput = jest.fn<typeof core.setOutput>()
9+
export const setFailed = jest.fn<typeof core.setFailed>()
10+
export const warning = jest.fn<typeof core.warning>()

0 commit comments

Comments
 (0)