Skip to content

Commit

Permalink
feat: add semantic release (#33)
Browse files Browse the repository at this point in the history
* feat: install semantic release

* chore: test branch

* chore: add fix

* add beta

* ci: use Github Actions

* chore: add test branch

* chore: fix syntax

* fix: token

* test: beta release

* chore(release): 0.1.0-beta.1 [skip ci]

# [0.1.0-beta.1](v0.0.4...v0.1.0-beta.1) (2021-09-03)

### Bug Fixes

* token ([2fe3280](2fe3280))

### Features

* install semantic release ([0d010d2](0d010d2))

* chore: docs

Co-authored-by: semantic-release-bot <[email protected]>
  • Loading branch information
ittus and semantic-release-bot committed Sep 3, 2021
1 parent 7dc7e67 commit 8453e00
Show file tree
Hide file tree
Showing 22 changed files with 15,373 additions and 8,243 deletions.
37 changes: 0 additions & 37 deletions .circleci/config.yml

This file was deleted.

64 changes: 64 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: Test and Release
on:
push:
workflow_dispatch:
jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14.17.6'
- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Install dependencies
run: npm install
- name: test
run: npm run lint && npm run test
release:
name: Release
runs-on: ubuntu-latest
needs: [test]
if: github.ref == 'refs/heads/master'
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14.17.6'
- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Install dependencies
run: npm install
- name: Build
run: npm run build
- name: Release
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: npx semantic-release
18 changes: 18 additions & 0 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"branches": ["master", {"name": "beta", "channel": "beta", "prerelease": "beta"}],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
[
"@semantic-release/npm"
],
["@semantic-release/git", {
"assets": ["dist/", "src/", "package.json","CHANGELOG.md"],
"message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"
}],
"@semantic-release/github"
],
"repositoryUrl": "https://github.com/ittus/vue-long-click"

}
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# [0.1.0-beta.1](https://github.com/ittus/vue-long-click/compare/v0.0.4...v0.1.0-beta.1) (2021-09-03)


### Bug Fixes

* token ([2fe3280](https://github.com/ittus/vue-long-click/commit/2fe3280c8bde3271bde44e222978294f18327d32))


### Features

* install semantic release ([0d010d2](https://github.com/ittus/vue-long-click/commit/0d010d204c579a262a72e6cacb6214d0c67d10eb))
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
> Vue long click (longpress) directive
[![npm version](https://badge.fury.io/js/vue-long-click.svg)](https://www.npmjs.com/package/vue-long-click)
[![CircleCI](https://circleci.com/gh/ittus/vue-long-click.svg?style=shield)](https://circleci.com/gh/ittus/vue-long-click)
[![Test and Release](https://github.com/ittus/vue-long-click/actions/workflows/release.yml/badge.svg)](https://github.com/ittus/vue-long-click/actions/workflows/release.yml)
![Size](https://badgen.net/bundlephobia/min/vue-long-click)

Checkout the demo at https://ittus.github.io/vue-long-click/
Expand Down
1 change: 1 addition & 0 deletions dist/docs/css/app.6625a00b.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added dist/docs/favicon.ico
Binary file not shown.
Binary file added dist/docs/img/logo.82b9c7a5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions dist/docs/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=/vue-long-click/favicon.ico><title>vue-long-click</title><link href=/vue-long-click/css/app.6625a00b.css rel=preload as=style><link href=/vue-long-click/js/app.5d752d92.js rel=preload as=script><link href=/vue-long-click/js/chunk-vendors.24901574.js rel=preload as=script><link href=/vue-long-click/css/app.6625a00b.css rel=stylesheet></head><body><noscript><strong>We're sorry but vue-long-click doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=/vue-long-click/js/chunk-vendors.24901574.js></script><script src=/vue-long-click/js/app.5d752d92.js></script></body></html>
2 changes: 2 additions & 0 deletions dist/docs/js/app.5d752d92.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions dist/docs/js/app.5d752d92.js.map

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions dist/docs/js/chunk-vendors.24901574.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/docs/js/chunk-vendors.24901574.js.map

Large diffs are not rendered by default.

10 changes: 10 additions & 0 deletions dist/libs/demo.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<meta charset="utf-8">
<title>vue-long-click demo</title>
<script src="./vue-long-click.umd.js"></script>

<link rel="stylesheet" href="./vue-long-click.css">


<script>
console.log(vue-long-click)
</script>
Loading

0 comments on commit 8453e00

Please sign in to comment.