Skip to content

Commit

Permalink
#18 - Bump github-badge-action
Browse files Browse the repository at this point in the history
  • Loading branch information
emibcn committed Dec 9, 2022
1 parent 3697e61 commit 5404f23
Show file tree
Hide file tree
Showing 11 changed files with 3,311 additions and 1,212 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/test.yml
Expand Up @@ -13,18 +13,18 @@ jobs:
# Get current banch name to use it as dest directory
- name: Extract branch name
shell: bash
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
run: echo "branch=${GITHUB_REF#refs/heads/}" >> "${GITHUB_OUTPUT}"
id: extract_branch

- name: Prepare environment
id: coverage
run: |
# Generates a GitHub Workflow output named `lines` with a coverage value
echo "##[set-output name=lines;]${COVERAGE}"
echo "lines=${COVERAGE}" >> "${GITHUB_OUTPUT}"
# Output values to be used by other steps
echo "##[set-output name=path;]${BADGE_PATH}"
echo "##[set-output name=branch;]${BRANCH}"
echo "path=${BADGE_PATH}" >> "${GITHUB_OUTPUT}"
echo "branch=${BRANCH}" >> "${GITHUB_OUTPUT}"
env:
COVERAGE: 53.5%
BADGE_PATH: ${{ steps.extract_branch.outputs.branch }}/test-badge.svg
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Expand Up @@ -13,6 +13,5 @@ npm-debug.log*
yarn-debug.log*
yarn-error.log*


# Packaged file
*.tgz
2 changes: 2 additions & 0 deletions .npmignore
Expand Up @@ -2,3 +2,5 @@
Dockerfile
docker-compose.yml
*.tgz
.deepsource.toml
badge-action.modern.mjs.map
3 changes: 2 additions & 1 deletion Dockerfile
Expand Up @@ -7,6 +7,7 @@ USER root
RUN \
apt-get update && \
apt-get install -y python3 gcc && \
apt-get clean
apt-get clean && \
rm -Rf /var/lib/apt/lists/

USER node
2 changes: 1 addition & 1 deletion action.yml
Expand Up @@ -43,4 +43,4 @@ outputs:
description: 'The badge SVG contents'
runs:
using: 'node16'
main: 'dist/index.js'
main: 'dist/badge-action.modern.mjs'
2 changes: 2 additions & 0 deletions dist/badge-action.modern.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/badge-action.modern.js.map

Large diffs are not rendered by default.

1,174 changes: 0 additions & 1,174 deletions dist/index.js

This file was deleted.

4 changes: 1 addition & 3 deletions index.js
@@ -1,5 +1,3 @@
'use strict'

const { createBadgeFromInputs } = require('github-badge-action')
import { createBadgeFromInputs } from 'github-badge-action'

createBadgeFromInputs()
15 changes: 8 additions & 7 deletions package.json
Expand Up @@ -2,19 +2,20 @@
"name": "badge-action",
"version": "1.2.4",
"description": "Create a badge using GitHub Actions and GitHub Workflow CPU time (no 3rd parties servers)",
"main": "index.js",
"source": "index.js",
"main": "dist/badge-action.modern.mjs",
"repository": "https://github.com/emibcn/badge-action",
"author": "github.com/emibcn",
"license": "GPL-3.0-or-later",
"private": false,
"type": "module",
"scripts": {
"build": "ncc build index.js -m",
"deploy": "yarn build && yarn pack"
},
"dependencies": {
"github-badge-action": "^1.0.2"
"build": "microbundle --external none index.js -o dist --target node --compress --format modern",
"deploy": "yarn build && yarn pack",
"clean": "rm *.tgz dist/*"
},
"devDependencies": {
"@zeit/ncc": "^0.22.3"
"github-badge-action": "^2.0.0",
"microbundle": "^0.15.1"
}
}
3,311 changes: 3,290 additions & 21 deletions yarn.lock

Large diffs are not rendered by default.

0 comments on commit 5404f23

Please sign in to comment.