Skip to content

Commit

Permalink
fix: add debugging to test licensee and linguist not being detected
Browse files Browse the repository at this point in the history
  • Loading branch information
prototypicalpro committed Dec 10, 2020
1 parent 4c5a16b commit c4b6fcc
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 5 deletions.
2 changes: 0 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,7 @@ RUN npm install --production
COPY dist dist

# Test licensee
WORKDIR /
ENV BUNDLE_GEMFILE=/app/Gemfile
RUN bundle exec licensee version

# Working directory will automagically be set to github workspace when the container is executed
ENTRYPOINT ["bundle", "exec", "node /app/dist/index.js"]
1 change: 0 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ runs:
INPUT_OUTPUT_NAME: ${{ inputs.output_name }}
INPUT_LABEL_NAME: ${{ inputs.label_name }}
INPUT_LABEL_COLOR: ${{ inputs.label_color }}
BUNDLE_GEMFILE: /app/Gemfile
branding:
color: green
icon: refresh-cw
2 changes: 1 addition & 1 deletion dist/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

13 changes: 13 additions & 0 deletions src/entry.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
import * as core from '@actions/core'
import {spawnSync} from 'child_process'
import run from './main'


/**
* @fileoverview This file serves as the "entry"
* you can check out main.ts for the actual
* "main" function.
*/

// debugging
core.debug(JSON.stringify(process.env))
const output = spawnSync('licensee', ['version'])
core.debug(JSON.stringify(output.stdout?.toString?.()))
core.debug(JSON.stringify(output.stderr?.toString?.()))
const output2 = spawnSync('github-linguist', ['--help'])
core.debug(JSON.stringify(output2.stdout?.toString?.()))
core.debug(JSON.stringify(output2.stderr?.toString?.()))


run()

0 comments on commit c4b6fcc

Please sign in to comment.