mirror of
https://github.com/extractions/setup-just
synced 2026-09-07 20:04:00 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4a174aa148 | ||
|
|
53165ef7e7 | ||
|
|
3ed9febd41 | ||
|
|
cf2bee9c93 | ||
|
|
c26183993c | ||
|
|
f8a3cce218 | ||
|
|
e1fdbd94e1 | ||
|
|
2674ac3f92 | ||
|
|
e33e0265a0 | ||
|
|
e8fa8d355d | ||
|
|
6e1de3cc40 | ||
|
|
d91bfae12f |
@@ -1,24 +0,0 @@
|
||||
{
|
||||
"env": {
|
||||
"browser": true,
|
||||
"es6": true
|
||||
},
|
||||
"extends": [
|
||||
"eslint:recommended",
|
||||
"plugin:@typescript-eslint/eslint-recommended"
|
||||
],
|
||||
"globals": {
|
||||
"Atomics": "readonly",
|
||||
"SharedArrayBuffer": "readonly"
|
||||
},
|
||||
"parser": "@typescript-eslint/parser",
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 2018,
|
||||
"sourceType": "module"
|
||||
},
|
||||
"plugins": [
|
||||
"@typescript-eslint"
|
||||
],
|
||||
"rules": {
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
# Keep GitHub Actions up to date with GitHub's Dependabot...
|
||||
# https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot
|
||||
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#package-ecosystem
|
||||
version: 2
|
||||
updates:
|
||||
- package-ecosystem: github-actions
|
||||
directory: /
|
||||
groups:
|
||||
github-actions:
|
||||
patterns:
|
||||
- "*" # Group all Actions updates into a single larger pull request
|
||||
schedule:
|
||||
interval: weekly
|
||||
@@ -6,24 +6,13 @@ on:
|
||||
- cron: 0 12 1 * *
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20.x'
|
||||
- run: npm ci
|
||||
- run: npm run lint
|
||||
- run: npm run build
|
||||
|
||||
test-latest:
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v7
|
||||
- name: Setup just
|
||||
uses: ./
|
||||
env:
|
||||
@@ -37,10 +26,10 @@ jobs:
|
||||
needs: test-latest
|
||||
strategy:
|
||||
matrix: # https://github.com/casey/just/releases
|
||||
just-version: [0.5.11, 0.6.1, 0.7.3, 0.8.7, 0.9.9, 0.10.7, 0.11.2, 1.5.0, 1.23.0]
|
||||
just-version: [0.5.11, 0.6.1, 0.7.3, 0.8.7, 0.9.9, 0.10.7, 0.11.2, 1.5.0, 1.23.0, 1.40.0]
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v7
|
||||
- name: Run self
|
||||
uses: ./
|
||||
with:
|
||||
|
||||
-112
@@ -1,113 +1 @@
|
||||
/runner
|
||||
|
||||
# Created by https://www.gitignore.io/api/node
|
||||
# Edit at https://www.gitignore.io/?templates=node
|
||||
|
||||
### Node ###
|
||||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
lerna-debug.log*
|
||||
|
||||
# Diagnostic reports (https://nodejs.org/api/report.html)
|
||||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
|
||||
|
||||
# Runtime data
|
||||
pids
|
||||
*.pid
|
||||
*.seed
|
||||
*.pid.lock
|
||||
|
||||
# Directory for instrumented libs generated by jscoverage/JSCover
|
||||
lib-cov
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
*.lcov
|
||||
|
||||
# nyc test coverage
|
||||
.nyc_output
|
||||
|
||||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
|
||||
.grunt
|
||||
|
||||
# Bower dependency directory (https://bower.io/)
|
||||
bower_components
|
||||
|
||||
# node-waf configuration
|
||||
.lock-wscript
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
jspm_packages/
|
||||
|
||||
# TypeScript v1 declaration files
|
||||
typings/
|
||||
|
||||
# TypeScript cache
|
||||
*.tsbuildinfo
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Optional REPL history
|
||||
.node_repl_history
|
||||
|
||||
# Output of 'npm pack'
|
||||
*.tgz
|
||||
|
||||
# Yarn Integrity file
|
||||
.yarn-integrity
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
.env.test
|
||||
|
||||
# parcel-bundler cache (https://parceljs.org/)
|
||||
.cache
|
||||
|
||||
# next.js build output
|
||||
.next
|
||||
|
||||
# nuxt.js build output
|
||||
.nuxt
|
||||
|
||||
# rollup.js default build output
|
||||
dist/*
|
||||
!dist/index.js
|
||||
|
||||
# Uncomment the public line if your project uses Gatsby
|
||||
# https://nextjs.org/blog/next-9-1#public-directory-support
|
||||
# https://create-react-app.dev/docs/using-the-public-folder/#docsNav
|
||||
# public
|
||||
|
||||
# Storybook build outputs
|
||||
.out
|
||||
.storybook-out
|
||||
|
||||
# vuepress build output
|
||||
.vuepress/dist
|
||||
|
||||
# Serverless directories
|
||||
.serverless/
|
||||
|
||||
# FuseBox cache
|
||||
.fusebox/
|
||||
|
||||
# DynamoDB Local files
|
||||
.dynamodb/
|
||||
|
||||
# Temporary folders
|
||||
tmp/
|
||||
temp/
|
||||
|
||||
# End of https://www.gitignore.io/api/node
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# 🤖 `setup-just` action
|
||||
|
||||
[](https://github.com/extractions/setup-just/actions/workflows/build.yaml)
|
||||
[](https://github.com/extractions/setup-just/actions/workflows/build.yaml)
|
||||
|
||||
This GitHub Action will install a release of the
|
||||
[just](https://github.com/casey/just) command runner for you.
|
||||
@@ -12,32 +12,24 @@ This GitHub Action will install a release of the
|
||||
In most cases all you will need is the following in your workflow.
|
||||
|
||||
```yaml
|
||||
- uses: extractions/setup-just@v1
|
||||
- uses: extractions/setup-just@v4
|
||||
```
|
||||
|
||||
If you want a specific version of `just` you can specify this by passing the
|
||||
`just-version` input.
|
||||
|
||||
```yaml
|
||||
- uses: extractions/setup-just@v1
|
||||
- uses: extractions/setup-just@v4
|
||||
with:
|
||||
just-version: '1.4.0'
|
||||
just-version: '1.46.0'
|
||||
```
|
||||
|
||||
To avoid rate-limiting, the default Github token available to all actions, is
|
||||
automatically used to authenticate calls to Github. To override it, set the
|
||||
environment variable `GITHUB_TOKEN` or pass the input `github-token`.
|
||||
To avoid rate-limiting, the default Github token (available to all actions) is
|
||||
automatically used to authenticate calls to Github. To override it, pass the
|
||||
input `github-token`.
|
||||
|
||||
```yaml
|
||||
- uses: extractions/setup-just@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
```
|
||||
|
||||
or
|
||||
|
||||
```yaml
|
||||
- uses: extractions/setup-just@v1
|
||||
- uses: extractions/setup-just@v4
|
||||
with:
|
||||
github-token: ${{ secrets.MY_GITHUB_TOKEN }}
|
||||
```
|
||||
@@ -54,38 +46,17 @@ package](https://www.npmjs.com/package/semver). This GitHub Action will install
|
||||
the latest matching release. Examples include
|
||||
|
||||
- `just-version: '*'` latest version (default).
|
||||
- `just-version: '0.10'` equivalent to `>=0.10.0 <0.11.0`.
|
||||
- `just-version: '0.10.x'` equivalent to `>=0.10.0 <0.11.0`.
|
||||
- `just-version: '0.10.0'` equivalent to `=0.10.0`.
|
||||
- `just-version: '^0.10.0'` equivalent to `>=0.10.0 <0.11.0`.
|
||||
- `just-version: '1'` equivalent to `>=1.0.0 <2.0.0`.
|
||||
- `just-version: '1.2'` equivalent to `>=1.2.0 <2.0.0`.
|
||||
- `just-version: '1.2.3'` equivalent to `=1.2.3`.
|
||||
- `just-version: '^1.2.3'` equivalent to `>=1.2.3 <2.0.0`.
|
||||
|
||||
## Development
|
||||
|
||||
Most of the installation logic is done in a shared library located at
|
||||
This action is a composite action and the installation logic is done in a shared
|
||||
library located at
|
||||
[@extractions/setup-crate](https://github.com/extractions/setup-crate).
|
||||
|
||||
The following commands are useful for development.
|
||||
|
||||
- `npm i`
|
||||
|
||||
Install all dependencies.
|
||||
|
||||
- `npm run fmt`
|
||||
|
||||
Format the source code.
|
||||
|
||||
- `npm run lint`
|
||||
|
||||
Run all lints.
|
||||
|
||||
- `npm run run`
|
||||
|
||||
Test the action by running it.
|
||||
|
||||
- `npm run build`
|
||||
|
||||
Build the action and update `dist/`.
|
||||
|
||||
## License
|
||||
|
||||
Licensed under either of
|
||||
|
||||
+7
-2
@@ -12,5 +12,10 @@ inputs:
|
||||
required: false
|
||||
default: ${{ github.token }}
|
||||
runs:
|
||||
using: 'node20'
|
||||
main: 'dist/index.js'
|
||||
using: composite
|
||||
steps:
|
||||
- uses: extractions/setup-crate@7577c1bdf2d95e6d65d532788f35ed79d4b1dda2 # v2.0.1
|
||||
with:
|
||||
repo: casey/just
|
||||
version: ${{ inputs.just-version }}
|
||||
github-token: ${{ inputs.github-token }}
|
||||
|
||||
Vendored
-9
File diff suppressed because one or more lines are too long
Generated
-2021
File diff suppressed because it is too large
Load Diff
@@ -1,36 +0,0 @@
|
||||
{
|
||||
"name": "setup-just",
|
||||
"version": "2.0.0",
|
||||
"description": "Install the just command runner",
|
||||
"main": "dist/index.js",
|
||||
"scripts": {
|
||||
"fmt": "prettier --write **/*.ts",
|
||||
"lint": "eslint **/*.ts",
|
||||
"build": "rm -rf dist/ && ncc build src/index.ts --minify",
|
||||
"run": "npm run build && RUNNER_TOOL_CACHE=./runner/cache RUNNER_TEMP=./runner/temp node dist/index.js"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/extractions/setup-just.git"
|
||||
},
|
||||
"author": "Ross MacArthur <ross@macarthur.io>",
|
||||
"license": "MIT OR Apache-2.0",
|
||||
"bugs": {
|
||||
"url": "https://github.com/extractions/setup-just/issues"
|
||||
},
|
||||
"homepage": "https://github.com/extractions/setup-just#readme",
|
||||
"dependencies": {
|
||||
"@actions/core": "^1.10.1",
|
||||
"@extractions/setup-crate": "^0.4.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/semver": "^7.5.8",
|
||||
"@typescript-eslint/eslint-plugin": "^7.1.0",
|
||||
"@typescript-eslint/parser": "^7.1.0",
|
||||
"@vercel/ncc": "^0.38.1",
|
||||
"eslint": "^8.57.0",
|
||||
"prettier": "^3.2.5",
|
||||
"typescript": "^5.3.3"
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
import * as core from "@actions/core";
|
||||
import * as setup from "@extractions/setup-crate";
|
||||
|
||||
async function main() {
|
||||
try {
|
||||
const githubToken =
|
||||
process.env.GITHUB_TOKEN || core.getInput("github-token");
|
||||
|
||||
const versionSpec = core.getInput("just-version");
|
||||
const tool = await setup.checkOrInstallTool(
|
||||
{
|
||||
owner: "casey",
|
||||
name: "just",
|
||||
versionSpec,
|
||||
},
|
||||
{ auth: githubToken }
|
||||
);
|
||||
core.addPath(tool.dir);
|
||||
core.info(`Successfully setup ${tool.name} v${tool.version}`);
|
||||
} catch (err) {
|
||||
if (err instanceof Error) {
|
||||
core.setFailed(err.message);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
main();
|
||||
@@ -1,66 +0,0 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
/* Basic Options */
|
||||
// "incremental": true, /* Enable incremental compilation */
|
||||
"target": "es6", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */
|
||||
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */
|
||||
// "lib": [], /* Specify library files to be included in the compilation. */
|
||||
// "allowJs": true, /* Allow javascript files to be compiled. */
|
||||
// "checkJs": true, /* Report errors in .js files. */
|
||||
// "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */
|
||||
// "declaration": true, /* Generates corresponding '.d.ts' file. */
|
||||
// "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */
|
||||
"sourceMap": true, /* Generates corresponding '.map' file. */
|
||||
// "outFile": "./", /* Concatenate and emit output to single file. */
|
||||
"outDir": "./lib", /* Redirect output structure to the directory. */
|
||||
"rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
|
||||
// "composite": true, /* Enable project compilation */
|
||||
// "tsBuildInfoFile": "./", /* Specify file to store incremental compilation information */
|
||||
// "removeComments": true, /* Do not emit comments to output. */
|
||||
// "noEmit": true, /* Do not emit outputs. */
|
||||
// "importHelpers": true, /* Import emit helpers from 'tslib'. */
|
||||
// "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */
|
||||
// "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */
|
||||
|
||||
/* Strict Type-Checking Options */
|
||||
"strict": true, /* Enable all strict type-checking options. */
|
||||
// "noImplicitAny": true, /* Raise error on expressions and declarations with an implied 'any' type. */
|
||||
// "strictNullChecks": true, /* Enable strict null checks. */
|
||||
// "strictFunctionTypes": true, /* Enable strict checking of function types. */
|
||||
// "strictBindCallApply": true, /* Enable strict 'bind', 'call', and 'apply' methods on functions. */
|
||||
// "strictPropertyInitialization": true, /* Enable strict checking of property initialization in classes. */
|
||||
// "noImplicitThis": true, /* Raise error on 'this' expressions with an implied 'any' type. */
|
||||
// "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */
|
||||
|
||||
/* Additional Checks */
|
||||
// "noUnusedLocals": true, /* Report errors on unused locals. */
|
||||
// "noUnusedParameters": true, /* Report errors on unused parameters. */
|
||||
// "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */
|
||||
// "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */
|
||||
|
||||
/* Module Resolution Options */
|
||||
"moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */
|
||||
// "baseUrl": "./", /* Base directory to resolve non-absolute module names. */
|
||||
// "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */
|
||||
// "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */
|
||||
// "typeRoots": [], /* List of folders to include type definitions from. */
|
||||
// "types": [], /* Type declaration files to be included in compilation. */
|
||||
// "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */
|
||||
"esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
|
||||
// "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */
|
||||
// "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
|
||||
|
||||
/* Source Map Options */
|
||||
// "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */
|
||||
// "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
|
||||
// "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */
|
||||
// "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */
|
||||
|
||||
/* Experimental Options */
|
||||
// "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */
|
||||
// "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */
|
||||
|
||||
/* Advanced Options */
|
||||
"forceConsistentCasingInFileNames": true /* Disallow inconsistently-cased references to the same file. */
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user