This commit is contained in:
Kirill Chernyshov 2020-08-20 12:49:53 +02:00
parent 53ab3a1214
commit f1ce919adb
No known key found for this signature in database
GPG Key ID: 425B3AB78FBCFBDB
5 changed files with 58 additions and 69 deletions

View File

@ -4,30 +4,30 @@ on: [push]
jobs:
# test-tools-deps:
test-tools-deps:
# strategy:
# matrix:
# operating-system: [ubuntu-latest, macOS-latest, windows-latest]
strategy:
matrix:
operating-system: [ubuntu-latest, macOS-latest]
# runs-on: ${{ matrix.operating-system }}
runs-on: ${{ matrix.operating-system }}
# steps:
# - name: Checkout
# uses: actions/checkout@v2
steps:
- name: Checkout
uses: actions/checkout@v2
# - name: Prepare java
# uses: actions/setup-java@v1
# with:
# java-version: 1.8
- name: Prepare java
uses: actions/setup-java@v1
with:
java-version: 1.8
# - name: Install clojure tools-deps
# uses: ./
# with:
# tools-deps: 1.10.1.469
- name: Install clojure tools-deps
uses: ./
with:
tools-deps: 1.10.1.469
# - name: Execute clojure code
# run: clojure -e "(+ 1 1)"
- name: Execute clojure code
run: clojure -e "(+ 1 1)"
test-leiningen:
@ -54,57 +54,27 @@ jobs:
- name: Check leiningen version
run: lein version
# test-boot:
test-boot:
# strategy:
# matrix:
# operating-system: [ubuntu-latest, macOS-latest, windows-latest]
strategy:
matrix:
operating-system: [ubuntu-latest, macOS-latest]
# runs-on: ${{ matrix.operating-system }}
runs-on: ${{ matrix.operating-system }}
# steps:
# - name: Checkout
# uses: actions/checkout@v2
steps:
- name: Checkout
uses: actions/checkout@v2
# - name: Prepare java
# uses: actions/setup-java@v1
# with:
# java-version: 1.8
- name: Prepare java
uses: actions/setup-java@v1
with:
java-version: 1.8
# - name: Install boot
# uses: ./
# with:
# boot: 2.8.3
- name: Install boot
uses: ./
with:
boot: 2.8.3
# - name: Check boot version
# run: boot -V
# test-all-together-with-latest-versions:
# strategy:
# matrix:
# operating-system: [ubuntu-latest, macOS-latest, windows-latest]
# runs-on: ${{ matrix.operating-system }}
# steps:
# - name: Checkout
# uses: actions/checkout@v2
# - name: Prepare java
# uses: actions/setup-java@v1
# with:
# java-version: 1.8
# - name: Install all the tools together
# uses: ./
# with:
# tools-deps: latest
# lein: latest
# boot: latest
# - name: Run checks
# run: |
# clojure -e "(+ 1 1)"
# lein -v
# boot -V
- name: Check boot version
run: boot -V

View File

@ -6,7 +6,7 @@ jobs:
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ubuntu-latest, macOS-latest, windows-latest]
operating-system: [ubuntu-latest, macOS-latest]
steps:
- name: Checkout
uses: actions/checkout@master

12
dist/index.js vendored
View File

@ -3298,7 +3298,9 @@ function installLeiningen(binScript, destinationFolder) {
if (!IS_WINDOWS) {
fs.chmodSync(path.join(binDir, `lein`), '0755');
}
const version_cmd = IS_WINDOWS ? 'powershell .\\lein.ps1 self-install' : './lein version';
const version_cmd = IS_WINDOWS
? 'powershell .\\lein.ps1 self-install'
: './lein version';
yield exec.exec(version_cmd, [], {
cwd: path.join(destinationFolder, 'leiningen', 'bin'),
env: {
@ -3354,6 +3356,8 @@ const core = __importStar(__webpack_require__(470));
const lein = __importStar(__webpack_require__(451));
const boot = __importStar(__webpack_require__(160));
const tdeps = __importStar(__webpack_require__(530));
const utils = __importStar(__webpack_require__(611));
const IS_WINDOWS = utils.isWindows();
function run() {
return __awaiter(this, void 0, void 0, function* () {
try {
@ -3364,9 +3368,15 @@ function run() {
lein.setup(Lein);
}
if (Boot) {
if (IS_WINDOWS) {
throw new Error('Boot on windows is not supported yet.');
}
boot.setup(Boot);
}
if (Tdeps) {
if (IS_WINDOWS) {
throw new Error('Clojure tools.deps on windows is not supported yet.');
}
tdeps.setup(Tdeps);
}
if (!Boot && !Lein && !Tdeps) {

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -2,6 +2,9 @@ import * as core from '@actions/core'
import * as lein from './leiningen'
import * as boot from './boot'
import * as tdeps from './tdeps'
import * as utils from './utils'
const IS_WINDOWS = utils.isWindows()
async function run(): Promise<void> {
try {
@ -14,10 +17,16 @@ async function run(): Promise<void> {
}
if (Boot) {
if (IS_WINDOWS) {
throw new Error('Boot on windows is not supported yet.')
}
boot.setup(Boot)
}
if (Tdeps) {
if (IS_WINDOWS) {
throw new Error('Clojure tools.deps on windows is not supported yet.')
}
tdeps.setup(Tdeps)
}