Skip to content

Commit 8fec0a3

Browse files
authored
Merge pull request #17 from component-driven/monorepo
Switch to a monorepo setup and changesets
2 parents 6bff254 + 959bee7 commit 8fec0a3

File tree

24 files changed

+8913
-13230
lines changed

24 files changed

+8913
-13230
lines changed

.babelrc

Lines changed: 0 additions & 17 deletions
This file was deleted.

.changeset/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Changesets
2+
3+
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)
4+
5+
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/master/docs/common-questions.md)

.changeset/config.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/config@1.0.3/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"linked": [],
6+
"access": "public",
7+
"baseBranch": "master"
8+
}

.changeset/loud-dots-study.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
'@component-driven/mixins': major
3+
'@component-driven/react-focus-within': major
4+
'@component-driven/with-selector': major
5+
---
6+
7+
Switch to a monorepo setup and use [Changesets](https://github.com/atlassian/changesets).
8+
9+
Each package is a separate npm package.

.github/workflows/release.yml

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,35 @@
11
name: Release
22

3-
on: [push]
3+
on:
4+
push:
5+
branches:
6+
- master
47

58
jobs:
69
release:
710
name: Release
811
runs-on: ubuntu-latest
912
steps:
10-
- name: Checkout
11-
uses: actions/checkout@v1
12-
- name: Setup Node.js
13-
uses: actions/setup-node@v1
13+
- name: Checkout Repo
14+
uses: actions/checkout@master
1415
with:
15-
node-version: 12
16-
- name: Install dependencies
17-
run: npm ci
18-
- name: Release
19-
uses: codfish/semantic-release-action@v1
16+
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
17+
fetch-depth: 0
18+
19+
- name: Setup Node.js 12.x
20+
uses: actions/setup-node@master
21+
with:
22+
node-version: 12.x
23+
24+
- name: Install Dependencies
25+
run: yarn
26+
27+
- name: Create Release Pull Request or Publish to npm
28+
id: changesets
29+
uses: changesets/action@master
30+
with:
31+
# This expects you to have a script called release which does a build for your packages and calls changeset publish
32+
publish: yarn release
2033
env:
2134
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2235
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

babel.config.js

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
module.exports = {
2+
presets: [
3+
[
4+
'@babel/preset-env',
5+
{
6+
targets: {
7+
browsers: ['ie >= 11']
8+
},
9+
exclude: ['transform-async-to-generator', 'transform-regenerator'],
10+
modules: false,
11+
loose: true
12+
}
13+
],
14+
'@babel/react'
15+
],
16+
plugins: ['@babel/plugin-proposal-class-properties']
17+
}

0 commit comments

Comments
 (0)