Skip to content

Commit

Permalink
add changeset and github action (#1)
Browse files Browse the repository at this point in the history
* add changeset and github action

* add packageManager

* add changeset
  • Loading branch information
JinIgarashi authored Aug 25, 2024
1 parent 0325aad commit 21c2098
Show file tree
Hide file tree
Showing 7 changed files with 747 additions and 4 deletions.
8 changes: 8 additions & 0 deletions .changeset/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Changesets

Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
with multi-package repos, or single-package repos to help you version and publish your code. You can
find the full documentation for it [in our repository](https://github.com/changesets/changesets)

We have a quick list of common questions to get you started engaging with this project in
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)
11 changes: 11 additions & 0 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "public",
"baseBranch": "develop",
"updateInternalDependencies": "patch",
"ignore": []
}
5 changes: 5 additions & 0 deletions .changeset/large-baboons-joke.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@watergis/svelte-splitter': major
---

update to svelte4 and migrate demo/package monorepo into a sveltekit package project.
39 changes: 39 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: build

on:
push:
branches:
- develop
pull_request:

env:
CI: true
PNPM_CACHE_FOLDER: .pnpm-store

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: checkout code repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: pnpm/[email protected]
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
cache: pnpm

- name: install dependencies
run: pnpm install --frozen-lockfile
- name: lint packages & sites
run: pnpm lint
- name: format packages & sites
run: pnpm format
- name: build packages & sites
run: pnpm build
46 changes: 46 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Changesets
on:
push:
branches:
- develop

env:
CI: true
PNPM_CACHE_FOLDER: .pnpm-store

permissions: {}
jobs:
release:
# prevents this action from running on forks
if: github.repository == 'watergis/svelte-spritter'
permissions:
contents: write # to create release (changesets/action)
pull-requests: write # to create pull request (changesets/action)
name: Release
runs-on: ubuntu-latest
steps:
- name: checkout code repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: pnpm/[email protected]
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
cache: pnpm

- name: install dependencies
run: pnpm install --frozen-lockfile
- name: build packages
run: pnpm build

- name: Create Release Pull Request or Publish to npm
id: changesets
uses: changesets/action@v1
with:
# This expects you to have a script called release which does a build for your packages and calls changeset publish
publish: pnpm release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.npm_token }}
13 changes: 9 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"name": "@geoffcox/svelte-splitter",
"name": "@watergis/svelte-splitter",
"version": "1.0.1",
"description": "A splitter for Svelte that leverages CSS grid templates for simple and consistent resizing.",
"author": "Geoff Cox",
"license": "MIT",
"bugs": {
"url": "https://github.com/GeoffCox/svelte-splitter/issues"
"url": "https://github.com/@watergis/svelte-splitter/issues"
},
"homepage": "https://github.com/GeoffCox/svelte-splitter/blob/main/package/README.md",
"homepage": "https://github.com/@watergis/svelte-splitter/README.md",
"keywords": [
"split",
"splitter",
Expand Down Expand Up @@ -43,6 +43,7 @@
"svelte": "^4.0.0"
},
"devDependencies": {
"@changesets/cli": "^2.27.7",
"@sveltejs/adapter-auto": "^3.0.0",
"@sveltejs/kit": "^2.0.0",
"@sveltejs/package": "^2.0.0",
Expand All @@ -64,5 +65,9 @@
},
"svelte": "./dist/index.js",
"types": "./dist/index.d.ts",
"type": "module"
"type": "module",
"packageManager": "[email protected]",
"engines": {
"pnpm": "^9.0.0"
}
}
Loading

0 comments on commit 21c2098

Please sign in to comment.