Skip to content

Commit

Permalink
chore: add sponsor badge.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Nov 27, 2023
1 parent 9bb1745 commit cbc36e5
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 38 deletions.
9 changes: 9 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# These are supported funding model platforms

# github: [jaywcjlove]
# patreon: # Replace with a single Patreon username
# open_collective: # Replace with a single Open Collective username
# ko_fi: # Replace with a single Ko-fi username
# tidelift: npm/colors-cli
# community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
custom: https://jaywcjlove.github.io/#/sponsor
84 changes: 46 additions & 38 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,32 @@ on:
jobs:
build-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
registry-url: 'https://registry.npmjs.org'

- run: npm install
- run: npm run build
- run: npm run type-check
- run: npm run coverage

- name: Converts Markdown to HTML
uses: jaywcjlove/markdown-to-html-cli@main
with:
output: coverage/index.html
github-corners: https://github.com/jaywcjlove/hsl-matcher
favicon: data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>🎨</text></svg>
- name: Create idoc config.
run: |
cat > idoc.yml << EOF
site: "HSL(a) Matcher {{version}}"
menus:
Home: index.html
Sponsor: https://jaywcjlove.github.io/#/sponsor
EOF
- run: npm install idoc@1.27.2 -g
- run: idoc --output="coverage"

- name: Create Coverage Badges
uses: jaywcjlove/coverage-badges-cli@main
Expand Down Expand Up @@ -83,39 +91,39 @@ jobs:
${{ steps.changelog.outputs.changelog }}
- run: npm publish
- run: npm publish --access public --provenance
name: 📦 hsl-matcher publish to NPM
continue-on-error: true
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

outputs:
successful: ${{steps.create_tag.outputs.successful }}

github-package:
runs-on: ubuntu-latest
needs: build-deploy
if: needs.build-deploy.outputs.successful
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
registry-url: https://npm.pkg.github.com
scope: '@jaywcjlove'

- run: npm install
- run: npm run build

- name: "Modify hsl-matcher => @jaywcjlove/hsl-matcher"
uses: jaywcjlove/github-action-package@main
with:
path: package.json
data: |
{ "name": "@jaywcjlove/hsl-matcher" }
- run: npm publish
name: 📦 @jaywcjlove/hsl-matcher publish to NPM
continue-on-error: true
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
# outputs:
# successful: ${{steps.create_tag.outputs.successful }}

# github-package:
# runs-on: ubuntu-latest
# needs: build-deploy
# if: needs.build-deploy.outputs.successful
# steps:
# - uses: actions/checkout@v3
# - uses: actions/setup-node@v3
# with:
# node-version: 16
# registry-url: https://npm.pkg.github.com
# scope: '@jaywcjlove'

# - run: npm install
# - run: npm run build

# - name: "Modify hsl-matcher => @jaywcjlove/hsl-matcher"
# uses: jaywcjlove/github-action-package@main
# with:
# path: package.json
# data: |
# { "name": "@jaywcjlove/hsl-matcher" }

# - run: npm publish
# name: 📦 @jaywcjlove/hsl-matcher publish to NPM
# continue-on-error: true
# env:
# NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
HSL(a) Matcher
===

[![Buy me a coffee](https://img.shields.io/badge/Buy%20me%20a%20coffee-048754?logo=buymeacoffee)](https://jaywcjlove.github.io/#/sponsor)
[![Build & Deploy](https://github.com/jaywcjlove/hsl-matcher/actions/workflows/ci.yml/badge.svg)](https://github.com/jaywcjlove/hsl-matcher/actions/workflows/ci.yml)
[![Open in unpkg](https://img.shields.io/badge/Open%20in-unpkg-blue)](https://uiwjs.github.io/npm-unpkg/#/pkg/hsl-matcher/file/README.md)
[![npm version](https://img.shields.io/npm/v/hsl-matcher.svg)](https://www.npmjs.com/package/hsl-matcher)
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"description": "A module to find HSL(a) color syntax substrings in a string with their offsets and their color instance.",
"author": "jaywcjlove",
"homepage": "https://jaywcjlove.github.io/hsl-matcher/",
"funding": "https://jaywcjlove.github.io/#/sponsor",
"license": "MIT",
"type": "module",
"types": "./lib/index.d.ts",
Expand Down

0 comments on commit cbc36e5

Please sign in to comment.